From 025c93ad2e76f6a8f684e8cf22583e934ce18ac1 Mon Sep 17 00:00:00 2001 From: Joe Corall Date: Wed, 22 May 2024 15:36:51 -0400 Subject: [PATCH] Clear cache after site install (#394) * Clear cache after site install * Have make production use same finalize as starter/starter-dev --------- Co-authored-by: Don Richards --- Makefile | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 54fe00cd0..212466da3 100644 --- a/Makefile +++ b/Makefile @@ -179,12 +179,7 @@ starter_dev: generate-secrets production: init $(MAKE) compose-up docker compose exec -T drupal with-contenv bash -lc 'composer install; chown -R nginx:nginx .' - $(MAKE) drupal-database update-settings-php - docker compose exec -T drupal with-contenv bash -lc "drush si -y --existing-config minimal --account-pass '$(shell cat secrets/live/DRUPAL_DEFAULT_ACCOUNT_PASSWORD)'" - docker compose exec -T drupal with-contenv bash -lc "drush -l $(SITE) user:role:add fedoraadmin admin" - MIGRATE_IMPORT_USER_OPTION=--userid=1 $(MAKE) hydrate - docker compose exec -T drupal with-contenv bash -lc 'drush -l $(SITE) migrate:import --userid=1 islandora_fits_tags' - $(MAKE) login + $(MAKE) starter-finalize ENVIRONMENT=starter ############################################# @@ -581,7 +576,10 @@ starter-finalize: docker compose exec -T drupal with-contenv bash -lc 'chown -R nginx:nginx . ; echo "Chown Complete"' $(MAKE) drupal-database update-settings-php docker compose exec -T drupal with-contenv bash -lc "drush si -y --existing-config minimal --account-pass '$(shell cat secrets/live/DRUPAL_DEFAULT_ACCOUNT_PASSWORD)'" + docker compose exec -T drupal with-contenv bash -lc "drush cr" docker compose exec -T drupal with-contenv bash -lc "drush -l $(SITE) user:role:add fedoraadmin admin" + @echo "Checking if Solr's healthy" + docker compose exec -T solr bash -c 'curl -s http://localhost:8983/solr/admin/info/system?wt=json' | jq -r .lucene || (echo "Solr is not healthy, waiting 10 seconds." && sleep 10) MIGRATE_IMPORT_USER_OPTION=--userid=1 $(MAKE) hydrate docker compose exec -T drupal with-contenv bash -lc 'drush -l $(SITE) migrate:import --userid=1 --tag=islandora' $(MAKE) login