Skip to content

Commit 4da43d7

Browse files
authored
Merge pull request #878 from dof-dss/development
Merge dev to main for release
2 parents 8743463 + aab586e commit 4da43d7

26 files changed

+1338
-1017
lines changed

.circleci/config.yml

+20-6
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ commands:
4949
- run:
5050
name: Switch dof-dss packages to HEAD on develelopment branch
5151
command: |
52-
composer require dof-dss/nidirect-site-modules:dev-development dof-dss/nidirect-migrations:dev-development \
52+
composer require dof-dss/nidirect-site-modules:dev-development \
5353
dof-dss/nidirect-d8-test-install-profile:dev-development dof-dss/nicsdru_origins_theme:dev-development \
5454
dof-dss/nicsdru_origins_modules:dev-development dof-dss/nicsdru_nidirect_theme:dev-development
5555
install_php_os_extensions:
@@ -80,6 +80,7 @@ commands:
8080
- run:
8181
name: Add platform cli tool to $PATH
8282
command: echo 'export PATH="$HOME/"'.platformsh/bin':"$PATH"' >> $BASH_ENV
83+
8384
jobs:
8485
# Tests the integrity of the build, stores the results in a workspace for re-use in later jobs.
8586
build:
@@ -130,7 +131,6 @@ jobs:
130131
cd $PROJECT_ROOT
131132
CHECK_DIRS="${PROJECT_ROOT}/web/modules/custom"
132133
CHECK_DIRS="$CHECK_DIRS ${PROJECT_ROOT}/web/modules/origins"
133-
CHECK_DIRS="$CHECK_DIRS ${PROJECT_ROOT}/web/modules/migrate"
134134
CHECK_DIRS="$CHECK_DIRS ${PROJECT_ROOT}/web/themes/custom"
135135
vendor/bin/drupal-check $CHECK_DIRS
136136
@@ -172,7 +172,7 @@ jobs:
172172
sed -i -e "s|\(^DRUPAL_NIGHTWATCH_OUTPUT\)=reports/nightwatch|\1=/home/circleci/nightwatch-reports|g" ~/project/web/core/.env
173173
174174
# Install npm packages for the projects/repos we know need them.
175-
for dir in core modules/custom modules/migrate/nidirect-migrations/migrate_nidirect_node; do
175+
for dir in core modules/custom; do
176176
cd ~/project/web/$dir
177177
npm install
178178
done
@@ -235,23 +235,34 @@ jobs:
235235
name: Trigger a data sync from production environment to an edge build.
236236
command: |
237237
platform sync data -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH -y
238+
- run:
239+
name: Backup data sync if the previous attempt failed.
240+
command: |
241+
# Pause for the blocking activity to finish.
242+
sleep 90s
243+
platform sync data -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH -y
244+
when: on_fail
238245
- run:
239246
name: Turn off fastly module to allow for cleaner config import
240247
command: |
241248
platform environment:drush pmu fastly -y -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
249+
when: always
242250
- run:
243251
name: Refresh configuration as our db will contain active prod config after sync operation
244252
command: |
245253
platform environment:drush cim -y -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
254+
when: always
246255
- run:
247256
name: Rebuild Taxonomy Entity Index
248257
command: |
249258
platform environment:drush tei-rebuild -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
259+
when: always
250260
- run:
251261
name: Set GAC state variable
252262
command: |
253263
platform environment:drush "sset google_analytics_counter.access_token ${GAC_ACCESS_TOKEN}" \
254264
-p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
265+
when: always
255266
- run:
256267
name: Enable test user accounts
257268
command: |
@@ -260,18 +271,21 @@ jobs:
260271
platform environment:drush user:unblock $username -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
261272
platform environment:drush user:password $username $TEST_PASS -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
262273
done
274+
when: always
263275
- run:
264276
name: Force purge of Solr index
265277
command: |
266278
platform ssh -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH \
267279
"curl http://${PLATFORM_SOLR_HOST}/solr/default/update --data '<delete><query>*:*</query></delete>' -H 'Content-type:text/xml; charset=utf-8' && curl http://${PLATFORM_SOLR_HOST}/solr/default/update --data '<commit/>' -H 'Content-type:text/xml; charset=utf-8'"
280+
when: always
268281
- run:
269282
name: Rebuild the Solr index
270283
command: |
271284
platform environment:drush sapi-rt -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
272285
platform environment:drush sapi-c -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
273286
platform environment:drush sapi-r -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
274287
platform environment:drush sapi-i -p $PLATFORM_PROJECT_ID -e $EDGE_BUILD_BRANCH
288+
when: always
275289

276290
# Create new release marker in New Relic
277291
mark_release:
@@ -302,9 +316,9 @@ workflows:
302316
- coding_standards:
303317
requires:
304318
- build
305-
- deprecated_code:
306-
requires:
307-
- build
319+
# - deprecated_code:
320+
# requires:
321+
# - build
308322

309323
# Workflow that instructs New Relic about new release tags in the repo.
310324
release-marker:

.platform.app.yaml

-6
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ relationships:
3030
redis: "redis:redis"
3131
# For MariaDB, the endpoint does not change whether you used the mysql or mariadb service type.
3232
database: 'db:admin'
33-
drupal7db: 'drupal7db:admin'
3433

3534
# The size of the persistent disk of the application (in MB).
3635
disk: 30720
@@ -151,8 +150,3 @@ web:
151150
# Provide a longer TTL (2 weeks) for aggregated CSS and JS files.
152151
'^/sites/default/files/(css|js)':
153152
expires: 2w
154-
crons:
155-
# Once a day, prune/delete filelog entries older than 30 days.
156-
filelog:
157-
spec: '0 1 * * *'
158-
cmd: 'cd /app/private; find logs -mtime +30 -exec rm -rf {} \;'

.platform/services.yaml

-12
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,6 @@ db:
1717
privileges:
1818
main: admin
1919

20-
drupal7db:
21-
type: mariadb:10.4
22-
disk: 4096
23-
configuration:
24-
schemas:
25-
- main
26-
endpoints:
27-
admin:
28-
default_schema: main
29-
privileges:
30-
main: admin
31-
3220
# Fudging the service name forces a full rebuild with any new config.
3321
solr:
3422
type: solr:7.7

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
[![CircleCI](https://circleci.com/gh/dof-dss/nidirect-drupal.svg?style=svg)](https://circleci.com/gh/dof-dss/nidirect-drupal)
22

3-
# NI Direct Drupal 8
3+
# NI Direct Drupal
44

55
Drupal source code for the NIDirect website: https://www.nidirect.gov.uk.
66

7-
Drupal 8 project based on `drupal/recommended-project`. The project comprises of a number of repositories and the diagram below outlines the relationships between them.
7+
Drupal project based on `drupal/recommended-project`. The project comprises of a number of repositories and the diagram below outlines the relationships between them.
88

99
[Composer](https://getcomposer.org/) is used to define and build the project; see `composer.json` for details.
1010

11-
> This repository corresponds to the 'Drupal 8 project template' element in the diagram.
11+
> This repository corresponds to the 'Drupal project template' element in the diagram.
1212
1313
![NI Direct project components](https://mermaid.ink/img/eyJjb2RlIjoiZ3JhcGggTFJcbnN1YmdyYXBoIE5JIERpcmVjdCBEcnVwYWwgOFxubGFuZG9bXCJMb2NhbCBkZXYgZnJhbWV3b3JrIChMYW5kbylcIl1cbmQ4W0RydXBhbCA4IHByb2plY3QgdGVtcGxhdGVdXG5zdWJncmFwaCBDdXN0b20gY29kZVxuY3VzdG9tW05JRGlyZWN0IGN1c3RvbSBtb2R1bGVzXVxubWlncmF0ZVtOSURpcmVjdCBEOCBtaWdyYXRpb24gbW9kdWxlc11cbmVuZFxuc3ViZ3JhcGggRnJvbnRlbmRcbmJhc2V0aGVtZVtCYXNlIHRoZW1lOiBPcmlnaW5zXVxubmlkaXJlY3R0aGVtZVtOSURpcmVjdCB0aGVtZV1cbmVuZFxuc3ViZ3JhcGggRXh0ZXJuYWxcbmNvbnRyaWJbQ29udHJpYnV0ZWQgRHJ1cGFsIG1vZHVsZXNdXG4zcFtUaGlyZCBwYXJ0eSBsaWJyYXJpZXNdXG5lbmRcbmVuZFxubGFuZG8tLT5kOFxuZDgtLT5jdXN0b21cbmQ4LS0-bWlncmF0ZVxuZDgtLT5iYXNldGhlbWVcbmQ4LS0-bmlkaXJlY3R0aGVtZVxuZDgtLT5jb250cmliXG5kOC0tPjNwXG5cbmNsaWNrIGxhbmRvIFwiaHR0cHM6Ly9naXRodWIuY29tL2RvZi1kc3MvbGFuZG8tZDctdG8tZDgtbWlncmF0ZVwiIFwibGFuZG8tZDctdG8tZDgtbWlncmF0ZVwiXG5jbGljayBkOCBcImh0dHBzOi8vZ2l0aHViLmNvbS9kb2YtZHNzL25pZGlyZWN0LWRydXBhbFwiIFwibmlkaXJlY3QtZHJ1cGFsXCJcbmNsaWNrIGN1c3RvbSBcImh0dHBzOi8vZ2l0aHViLmNvbS9kb2YtZHNzL25pZGlyZWN0LXNpdGUtbW9kdWxlc1wiIFwibmlkaXJlY3Qtc2l0ZS1tb2R1bGVzXCJcbmNsaWNrIG1pZ3JhdGUgXCJodHRwczovL2dpdGh1Yi5jb20vZG9mLWRzcy9uaWRpcmVjdC1kOC1taWctbW9kc1wiIFwibmlkaXJlY3QtZDgtbWlnLW1vZHNcIlxuY2xpY2sgYmFzZXRoZW1lIFwiaHR0cHM6Ly9naXRodWIuY29tL2RvZi1kc3Mvbmljc2RydV9vcmlnaW5zX3RoZW1lXCIgXCJuaWNzZHJ1X29yaWdpbnNfdGhlbWVcIlxuY2xpY2sgbmlkaXJlY3R0aGVtZSBcImh0dHBzOi8vZ2l0aHViLmNvbS9kb2YtZHNzL25pY3NkcnVfbmlkaXJlY3RfdGhlbWVcIiBcIm5pY3NkcnVfbmlkaXJlY3RfdGhlbWVcIiIsIm1lcm1haWQiOnsidGhlbWUiOiJkZWZhdWx0In19 "NI Direct project components")
1414

composer.json

+8-9
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@
4646
"dof-dss/nicsdru_origins_modules": "^1.0",
4747
"dof-dss/nicsdru_origins_theme": "^0.4",
4848
"dof-dss/nidirect-d8-test-install-profile": "^1.0",
49-
"dof-dss/nidirect-migrations": "^1.0",
5049
"dof-dss/nidirect-site-modules": "^2.0",
5150
"drupal/address": "^1.7",
5251
"drupal/admin_toolbar": "^3.0",
@@ -66,9 +65,9 @@
6665
"drupal/config_update": "^1.6",
6766
"drupal/console": "^1.9",
6867
"drupal/cookie_content_blocker": "^1.7",
69-
"drupal/core-composer-scaffold": "^9",
70-
"drupal/core-project-message": "^9",
71-
"drupal/core-recommended": "^9",
68+
"drupal/core-composer-scaffold": "~9.2.0",
69+
"drupal/core-project-message": "~9.2.0",
70+
"drupal/core-recommended": "~9.2.0",
7271
"drupal/csp": "^1.15",
7372
"drupal/csv_serialization": "^2.0@beta",
7473
"drupal/ctools": "^3.7",
@@ -84,6 +83,7 @@
8483
"drupal/facets_pretty_paths": "^1.1",
8584
"drupal/fastly": "^3.9",
8685
"drupal/field_group": "^3.2",
86+
"drupal/file_delete_ui": "^1.0@alpha",
8787
"drupal/filelog": "^2.0",
8888
"drupal/flag": "4.x-dev",
8989
"drupal/geocoder": "^3.14",
@@ -97,6 +97,7 @@
9797
"drupal/layout_builder_modal": "^1.0@alpha",
9898
"drupal/layout_builder_restrictions": "^2.9",
9999
"drupal/linkit": "^6.0.0",
100+
"drupal/media_file_delete": "^1.1",
100101
"drupal/media_library_edit": "^2.0",
101102
"drupal/metatag": "^1.8",
102103
"drupal/migrate_absolute_links": "^2.1",
@@ -150,7 +151,7 @@
150151
"zaporylie/composer-drupal-optimizations": "^1.0"
151152
},
152153
"require-dev": {
153-
"drupal/core-dev": "^9",
154+
"drupal/core-dev": "~9.2.0",
154155
"drupal/devel": "^4.1",
155156
"drupal/devel_entity_updates": "^3.0",
156157
"drupal/easy_install": "^10.5",
@@ -195,7 +196,8 @@
195196
"Layout builder fails to assign inline block access dependencies for the overrides section storage on entities with pending revisions": "https://www.drupal.org/files/issues/2021-03-22/3047022-71.patch",
196197
"Support for AjaxResponse implementing CacheableResponseInterface": "https://gist.githubusercontent.com/omahm/cd990b5cdba637fe270ada0702717d9d/raw/60a05babb9747061df201ca9f74afb4b59166f14/cacheableAjaxResponse.patch",
197198
"Increase service priority for logger factory": "https://gist.githubusercontent.com/johangant/3023926f40867e14385bd3d87831adfc/raw/174cec09449636263b8dcd01679945677a0d607d/increase_logger_factory_service_priority.patch",
198-
"'Negate' form value for condition plugins should be cast to boolean in validation": "https://www.drupal.org/files/issues/2020-03-23/3114467-8.patch"
199+
"'Negate' form value for condition plugins should be cast to boolean in validation": "https://www.drupal.org/files/issues/2020-03-23/3114467-8.patch",
200+
"Remove invalid iframe attributes from oembed field formatter": "https://www.drupal.org/files/issues/2019-07-31/remove-iframe-attributes-3071446-4.patch"
199201
},
200202
"drupal/devel": {
201203
"Brings back the Available Methods & Properties tabs for Kint dumps — Issue #221": "https://raw.githubusercontent.com/politsin/snipets/master/patch/kint.patch"
@@ -206,9 +208,6 @@
206208
"drupal/entity_reference_unpublished": {
207209
"Plugin to cover taxonomy term entities": "https://www.drupal.org/files/issues/2021-03-25/3205634-reference-unpublished-taxonomy-terms.patch"
208210
},
209-
"drupal/filelog": {
210-
"Whole Log gets loaded into Memory when gzipping": "https://www.drupal.org/files/issues/2021-04-07/filelog-3157650-21.patch"
211-
},
212211
"drupal/inline_entity_form": {
213212
"Widget settings to control removing & deleting existing references": "https://www.drupal.org/files/issues/2021-04-15/ief_removed_references_2875716-103.patch"
214213
},

0 commit comments

Comments
 (0)