From 2bd36694db177fb976ef65fff582ea6ae4846d49 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Tue, 13 Apr 2021 16:39:02 -0300 Subject: [PATCH 01/25] Updating sandbox commit --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 1d1ba043..167e8e51 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=47c836a113bd5affeb40eff7896abd8860fc822c +ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 1f86ff83219f554e2b0d105fe620d96a20ae86af Mon Sep 17 00:00:00 2001 From: dannylamb Date: Thu, 15 Apr 2021 16:38:07 -0300 Subject: [PATCH 02/25] Trying to pull in the install profile --- demo/Dockerfile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/demo/Dockerfile b/demo/Dockerfile index 167e8e51..2fc02c00 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -4,6 +4,7 @@ ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 +ARG PROFILE_COMMIT=8d3ae73d1c43f76eaa59b8b0f846c12e8140cfe4 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ @@ -16,6 +17,11 @@ RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/ca --worktree /var/www/drupal && \ cd /var/www/drupal && \ composer install && \ + git-clone-cached.sh \ + --url https://github.com/islandora-devops/islandora_install_profile_demo.git \ + --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ + --commit "${PROFILE_COMMIT}" \ + --worktree /var/www/drupal/web/profiles/islandora_install_profile_demo && \ # Set up libraries mkdir -p /var/www/drupal/web/libraries && \ # PDF.js From 6b7f0ff285f1cc7b08ab695ba605613f0fb6a2dc Mon Sep 17 00:00:00 2001 From: dannylamb Date: Fri, 16 Apr 2021 17:05:35 -0300 Subject: [PATCH 03/25] Using install profile variable when installing Drupal with Drush --- demo/Dockerfile | 2 +- drupal/rootfs/etc/islandora/utilities.sh | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 2fc02c00..1f825796 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -4,7 +4,7 @@ ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 -ARG PROFILE_COMMIT=8d3ae73d1c43f76eaa59b8b0f846c12e8140cfe4 +ARG PROFILE_COMMIT=9db038fa77e08bbd6dd094da26b4d844f0cd247b # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 7f7b81a6..638ca74c 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -246,6 +246,23 @@ function install_site { chmod a=rwx "${site_directory}/settings.php" fi + echo "--driver ${driver}" + echo "--host ${host}" + echo "--port ${port}" + echo "--dbuser ${user}" + echo "--dbpassword ${password}" + echo "--dbname ${db_name}" + echo "PROFILE: ${profile}" + echo "--account-mail=${account_email}" + echo "--account-name=${account_name}" + echo "--account-pass=${account_password}" + echo "--site-mail=${site_email}" + echo "--locale=${site_locale}" + echo "--site-name=${site_name}" + echo "--sites-subdir=${subdir}" + echo "USE_EXISTIG_CONFIG: ${use_existing_config_arg}" + echo "EVERYTHING ELSE: ${@}" + /usr/local/bin/install-drupal-site.sh \ --driver "${driver}" \ --host "${host}" \ From 2fc70cfc2268b5305a3cdcdf2afd6805704cdeea Mon Sep 17 00:00:00 2001 From: dannylamb Date: Fri, 23 Apr 2021 17:26:33 -0300 Subject: [PATCH 04/25] Bumping sandbox commit --- demo/Dockerfile | 76 +++++++++---------- .../usr/local/bin/install-drupal-site.sh | 1 + 2 files changed, 36 insertions(+), 41 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 1f825796..e4baa133 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,8 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 -ARG PROFILE_COMMIT=9db038fa77e08bbd6dd094da26b4d844f0cd247b +ARG COMMIT=da2be9232842de5931ce9fc531c0472dd8f91c00 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ @@ -16,53 +15,48 @@ RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/ca --commit "${COMMIT}" \ --worktree /var/www/drupal && \ cd /var/www/drupal && \ - composer install && \ - git-clone-cached.sh \ - --url https://github.com/islandora-devops/islandora_install_profile_demo.git \ - --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ - --commit "${PROFILE_COMMIT}" \ - --worktree /var/www/drupal/web/profiles/islandora_install_profile_demo && \ + composer install # Set up libraries - mkdir -p /var/www/drupal/web/libraries && \ + #mkdir -p /var/www/drupal/web/libraries && \ # PDF.js - PDFJS_VERSION="2.0.943" && \ - PDFJS_FILE="pdfjs-${PDFJS_VERSION}-dist.zip" && \ - PDFJS_URL="https://github.com/mozilla/pdf.js/releases/download/v${PDFJS_VERSION}/${PDFJS_FILE}" && \ - PDFJS_SHA256="381683b05f494fe28e11185f98a238b34a663b1b41b5432aa769ca493e5cd087" && \ - download.sh --url "${PDFJS_URL}" --sha256 "${PDFJS_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/pdf.js && \ - unzip "${DOWNLOAD_CACHE_DIRECTORY}/${PDFJS_FILE}" -d /var/www/drupal/web/libraries/pdf.js && \ + #PDFJS_VERSION="2.0.943" && \ + #PDFJS_FILE="pdfjs-${PDFJS_VERSION}-dist.zip" && \ + #PDFJS_URL="https://github.com/mozilla/pdf.js/releases/download/v${PDFJS_VERSION}/${PDFJS_FILE}" && \ + #PDFJS_SHA256="381683b05f494fe28e11185f98a238b34a663b1b41b5432aa769ca493e5cd087" && \ + #download.sh --url "${PDFJS_URL}" --sha256 "${PDFJS_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/pdf.js && \ + #unzip "${DOWNLOAD_CACHE_DIRECTORY}/${PDFJS_FILE}" -d /var/www/drupal/web/libraries/pdf.js && \ # Views Slideshow Dependencies ## jquery.cycle - JQUERY_CYCLE_FILE="jquery.cycle.all.js" && \ - JQUERY_CYCLE_URL="https://malsup.github.io/${JQUERY_CYCLE_FILE}" && \ - JQUERY_CYCLE_SHA256="58b44d975e1e1f0664d0fb8ab5b2918d08e9497324a021aa93de5894cdb586d4" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.cycle && \ - download.sh --url "${JQUERY_CYCLE_URL}" --sha256 "${JQUERY_CYCLE_SHA256}" /var/www/drupal/web/libraries/jquery.cycle && \ + #JQUERY_CYCLE_FILE="jquery.cycle.all.js" && \ + #JQUERY_CYCLE_URL="https://malsup.github.io/${JQUERY_CYCLE_FILE}" && \ + #JQUERY_CYCLE_SHA256="58b44d975e1e1f0664d0fb8ab5b2918d08e9497324a021aa93de5894cdb586d4" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.cycle && \ + #download.sh --url "${JQUERY_CYCLE_URL}" --sha256 "${JQUERY_CYCLE_SHA256}" /var/www/drupal/web/libraries/jquery.cycle && \ ## jquery.hoverIntent - JQUERY_HOVER_INTENT_FILE="jquery.hoverIntent.js" && \ - JQUERY_HOVER_INTENT_URL="https://raw.githubusercontent.com/briancherne/jquery-hoverIntent/master/${JQUERY_HOVER_INTENT_FILE}" && \ - JQUERY_HOVER_INTENT_SHA256="65f5f7e1298fe71f10290f4068df30b38a5df0106d6feb63210ddabcc67c3e59" && \ - download.sh --url "${JQUERY_HOVER_INTENT_URL}" --sha256 "${JQUERY_HOVER_INTENT_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.hoverIntent && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_HOVER_INTENT_FILE}" /var/www/drupal/web/libraries/jquery.hoverIntent && \ + #JQUERY_HOVER_INTENT_FILE="jquery.hoverIntent.js" && \ + #JQUERY_HOVER_INTENT_URL="https://raw.githubusercontent.com/briancherne/jquery-hoverIntent/master/${JQUERY_HOVER_INTENT_FILE}" && \ + #JQUERY_HOVER_INTENT_SHA256="65f5f7e1298fe71f10290f4068df30b38a5df0106d6feb63210ddabcc67c3e59" && \ + #download.sh --url "${JQUERY_HOVER_INTENT_URL}" --sha256 "${JQUERY_HOVER_INTENT_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.hoverIntent && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_HOVER_INTENT_FILE}" /var/www/drupal/web/libraries/jquery.hoverIntent && \ ## jquery.pause - JQUERY_PAUSE_FILE="jquery.pause.js" && \ - JQUERY_PAUSE_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JQUERY_PAUSE_FILE}" && \ - JQUERY_PAUSE_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ - download.sh --url "${JQUERY_PAUSE_URL}" --sha256 "${JQUERY_PAUSE_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.pause && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_PAUSE_FILE}" /var/www/drupal/web/libraries/jquery.pause && \ + #JQUERY_PAUSE_FILE="jquery.pause.js" && \ + #JQUERY_PAUSE_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JQUERY_PAUSE_FILE}" && \ + #JQUERY_PAUSE_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ + #download.sh --url "${JQUERY_PAUSE_URL}" --sha256 "${JQUERY_PAUSE_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.pause && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_PAUSE_FILE}" /var/www/drupal/web/libraries/jquery.pause && \ ## json2 - JSON2_FILE="jquery.pause.js" && \ - JSON2_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JSON2_FILE}" && \ - JSON2_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ - download.sh --url "${JSON2_URL}" --sha256 "${JSON2_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/json2 && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JSON2_FILE}" /var/www/drupal/web/libraries/json2 && \ + #JSON2_FILE="jquery.pause.js" && \ + #JSON2_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JSON2_FILE}" && \ + #JSON2_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ + #download.sh --url "${JSON2_URL}" --sha256 "${JSON2_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/json2 && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JSON2_FILE}" /var/www/drupal/web/libraries/json2 && \ # Openseadragon - mkdir -p /var/www/drupal/web/sites/default/files/library-definitions && \ - cp /var/www/drupal/web/modules/contrib/openseadragon/openseadragon.json /var/www/drupal/web/sites/default/files/library-definitions + #mkdir -p /var/www/drupal/web/sites/default/files/library-definitions && \ + #cp /var/www/drupal/web/modules/contrib/openseadragon/openseadragon.json /var/www/drupal/web/sites/default/files/library-definitions FROM ${repository}/drupal:${tag} diff --git a/drupal/rootfs/usr/local/bin/install-drupal-site.sh b/drupal/rootfs/usr/local/bin/install-drupal-site.sh index f458d302..ef5ad579 100755 --- a/drupal/rootfs/usr/local/bin/install-drupal-site.sh +++ b/drupal/rootfs/usr/local/bin/install-drupal-site.sh @@ -164,6 +164,7 @@ function main { protocol=pgsql fi echo "Installing site." + echo "-n si ${DRUSH_ARGS} --db-url=${protocol}://${DB_USER}:${DB_PASSWORD}@${HOST}:${PORT}/${DB_NAME}" drush \ -n \ si ${DRUSH_ARGS} \ From 9313caaa85a8fed77f641f2e63530eaa18a8ee0c Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 26 Apr 2021 23:38:09 -0300 Subject: [PATCH 05/25] Setting content sync directory --- demo/Dockerfile | 2 +- drupal/rootfs/etc/islandora/utilities.sh | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index e4baa133..52cc103d 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=da2be9232842de5931ce9fc531c0472dd8f91c00 +ARG COMMIT=8a6594d44a53d0883a36802c011d924a320ee427 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 638ca74c..9ff90ca1 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -334,6 +334,11 @@ function update_settings_php { chmod a=rwx "${site_directory}/settings.php" fi + if ! grep -q 'global \$content_directories;' ${site_directory}/settings.php; then + echo 'global $content_directories;' >> ${site_directory}/settings.php + echo '$content_directories['sync'] = $app_root . "/../content/sync";' >> ${site_directory}/settings.php + fi + drush -l "${site_url}" islandora:settings:create-settings-if-missing drush -l "${site_url}" islandora:settings:set-hash-salt "${salt}" drush -l "${site_url}" islandora:settings:set-flystem-fedora-url "${fedora_url}" From bda0981a99b8b5c0a178268c7199ae5256a270bc Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 10:25:53 -0300 Subject: [PATCH 06/25] Fixing content_sync directories --- demo/Dockerfile | 2 +- drupal/rootfs/etc/islandora/utilities.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 52cc103d..16d6196d 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=8a6594d44a53d0883a36802c011d924a320ee427 +ARG COMMIT=26c072273747523c0af7305eececd47de1940c34 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 9ff90ca1..91d412ff 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -336,7 +336,7 @@ function update_settings_php { if ! grep -q 'global \$content_directories;' ${site_directory}/settings.php; then echo 'global $content_directories;' >> ${site_directory}/settings.php - echo '$content_directories['sync'] = $app_root . "/../content/sync";' >> ${site_directory}/settings.php + echo '$content_directories["sync"] = "/var/www/drupal/content/sync";' >> ${site_directory}/settings.php fi drush -l "${site_url}" islandora:settings:create-settings-if-missing From 69c9f9d856c21abb4965295f999b961d53d6c1cc Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 13:48:08 -0300 Subject: [PATCH 07/25] Bumping islandora-sandbox --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 16d6196d..30e1c380 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=26c072273747523c0af7305eececd47de1940c34 +ARG COMMIT=f89cfbb85b72e6d2c7330e72407fab84179cc27e # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 91f2b37fab22a2f44a76002cbfbc19f6ca7c53eb Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 13:58:34 -0300 Subject: [PATCH 08/25] Bumping sandbox again --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 30e1c380..b4f066b3 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=f89cfbb85b72e6d2c7330e72407fab84179cc27e +ARG COMMIT=a920f36ea87f24e0583c3d351bb7af0c89dad34c # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 21a732e9e5bc245cccd808a58388453edce7b38e Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 22 Nov 2021 17:01:18 -0400 Subject: [PATCH 09/25] Updating sandbox hash --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 2e416485..213b1640 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=a920f36ea87f24e0583c3d351bb7af0c89dad34c +ARG COMMIT=67b8e87ddd5c5b5a01522aaf3129ad4c661cb76d # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From aed5adc95784c1dd24589a0f77c3bbb063c92113 Mon Sep 17 00:00:00 2001 From: Rosie Le Faive Date: Tue, 14 Dec 2021 10:43:02 -0400 Subject: [PATCH 10/25] Update commit for islandora-sandbox and use official repo. --- demo/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 213b1640..0ae104d2 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,14 +3,14 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=67b8e87ddd5c5b5a01522aaf3129ad4c661cb76d +ARG COMMIT=4012e56a5c88b0a9a3686f1e51cd4f4da5ff13e4 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ --mount=type=cache,id=demo-downloads,sharing=locked,target=/opt/downloads \ # Get the Drupal codebase git-clone-cached.sh \ - --url https://github.com/dannylamb/islandora-sandbox.git \ + --url https://github.com/Islandora-Devops/islandora-sandbox.git \ --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ --commit "${COMMIT}" \ --worktree /var/www/drupal && \ From 871142d0c554a440b5a4df57b47fce77ae506608 Mon Sep 17 00:00:00 2001 From: Nigel Banks Date: Wed, 5 Jan 2022 19:08:22 +0000 Subject: [PATCH 11/25] Install profile review (#177) * Fix logging errors with cantaloupe due to find/replace bug (#165) * Adding max_input_vars to php.ini (#166) * Explain how Docker Hub factors in the workflow. (#171) * Updated the introduction to redirect users to better starting points in case they ended up at this repo by accident. (#164) * [issue-172] Use explicit commits in URLs such that (#176) Code can change when pulling from a master branch, which causes checksum checks to fail. This can changes master to instead refer to explicit commits hashes. The output docker images is byte for byte the same though. * Prevent passwords from being logged. Co-authored-by: dannylamb Co-authored-by: Rosie Le Faive --- README.md | 17 +++++++- cantaloupe/Dockerfile | 42 +++++++++---------- cantaloupe/README.md | 11 +++-- .../etc/cont-init.d/02-cantoloupe-install.sh | 9 ---- drupal/rootfs/etc/islandora/utilities.sh | 2 - .../usr/local/bin/install-drupal-site.sh | 1 - nginx/Dockerfile | 1 + nginx/rootfs/etc/confd/templates/php.ini.tmpl | 2 +- 8 files changed, 43 insertions(+), 42 deletions(-) delete mode 100755 cantaloupe/rootfs/etc/cont-init.d/02-cantoloupe-install.sh diff --git a/README.md b/README.md index 33b09b37..85bd44b9 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,19 @@ ## Introduction This repository provides a number of docker images which can be used to build an -Islandora 8 site. +Islandora 8 site. On commit, these images are automatically pushed to +[Docker Hub](https://hub.docker.com/u/islandora) via Github Actions. Which are +consumed by [isle-dc] and can be used by other Docker orchestration tools such +as Swarm / Kubernetes. + +It is **not** meant as a starting point for new users or those unfamiliar with +Docker, or basic server adminstration. + +If you are looking to use islandora please read the +[official documentation](https://islandora.github.io/documentation/) and use +either [isle-dc] to deploy via Docker or the +[islandora-playbook](https://github.com/Islandora-Devops/islandora-playbook) to +deploy via Ansible. ## Requirements @@ -140,7 +152,7 @@ redeployed with the latest changes while you develop automatically. ## Running There is no method for running the containers in `isle-buildkit`, instead please -refer to . +refer to [isle-dc]. ## Docker Images @@ -434,3 +446,4 @@ failed to solve with frontend dockerfile.v0: failed to solve with frontend gatew using the [Overlay2] filesystem with Docker. [Overlay2]: https://docs.docker.com/storage/storagedriver/overlayfs-driver#configure-docker-with-the-overlay-or-overlay2-storage-driver +[isle-dc]: https://github.com/Islandora-Devops/isle-dc diff --git a/cantaloupe/Dockerfile b/cantaloupe/Dockerfile index 0cd007dd..c57ea439 100644 --- a/cantaloupe/Dockerfile +++ b/cantaloupe/Dockerfile @@ -95,12 +95,12 @@ ENV \ CANTALOUPE_FFMPEGPROCESSOR_PATH_TO_BINARIES= \ CANTALOUPE_FILESYSTEMCACHE_DIR_DEPTH="3" \ CANTALOUPE_FILESYSTEMCACHE_DIR_NAME_LENGTH="2" \ - CANTALOUPE_FILESYSTEMCACHE_PATHNAME="_data" \ - CANTALOUPE_FILESYSTEMSOURCE_BASICLOOKUPSTRATEGY_PATH_PREFIX="_var_www_drupal_web_" \ + CANTALOUPE_FILESYSTEMCACHE_PATHNAME="/data" \ + CANTALOUPE_FILESYSTEMSOURCE_BASICLOOKUPSTRATEGY_PATH_PREFIX="/var/www/drupal/web/" \ CANTALOUPE_FILESYSTEMSOURCE_BASICLOOKUPSTRATEGY_PATH_SUFFIX= \ CANTALOUPE_FILESYSTEMSOURCE_LOOKUP_STRATEGY="BasicLookupStrategy" \ CANTALOUPE_HEAPCACHE_PERSIST="false" \ - CANTALOUPE_HEAPCACHE_PERSIST_FILESYSTEM_PATHNAME="_var_cache_cantaloupe_heap.cache" \ + CANTALOUPE_HEAPCACHE_PERSIST_FILESYSTEM_PATHNAME="/var/cache/cantaloupe/heap.cache" \ CANTALOUPE_HEAPCACHE_TARGET_SIZE="2G" \ CANTALOUPE_HTTP_ENABLED="true" \ CANTALOUPE_HTTP_HOST="0.0.0.0" \ @@ -109,7 +109,7 @@ ENV \ CANTALOUPE_HTTPS_HOST="0.0.0.0" \ CANTALOUPE_HTTPS_KEY_PASSWORD="password" \ CANTALOUPE_HTTPS_KEY_STORE_PASSWORD="password" \ - CANTALOUPE_HTTPS_KEY_STORE_PATH="_path_to_keystore.jks" \ + CANTALOUPE_HTTPS_KEY_STORE_PATH="/path/to/keystore.jks" \ CANTALOUPE_HTTPS_KEY_STORE_TYPE="JKS" \ CANTALOUPE_HTTPS_PORT="8183" \ CANTALOUPE_HTTPSOURCE_ALLOW_INSECURE="false" \ @@ -127,35 +127,35 @@ ENV \ CANTALOUPE_JDBCCACHE_DERIVATIVE_IMAGE_TABLE="derivative_cache" \ CANTALOUPE_JDBCCACHE_INFO_TABLE="info_cache" \ CANTALOUPE_JDBCCACHE_PASSWORD="password" \ - CANTALOUPE_JDBCCACHE_URL="jdbc:postgresql:__database:5432_cantaloupe" \ + CANTALOUPE_JDBCCACHE_URL="jdbc:postgresql://database:5432/cantaloupe" \ CANTALOUPE_JDBCCACHE_USER="admin" \ CANTALOUPE_JDBCSOURE_CONNECTION_TIMEOUT="10" \ CANTALOUPE_JDBCSOURE_PASSWORD="password" \ - CANTALOUPE_JDBCSOURE_URL="jdbc:postgresql:__database:5432_cantaloupe" \ + CANTALOUPE_JDBCSOURE_URL="jdbc:postgresql://database:5432/cantaloupe" \ CANTALOUPE_JDBCSOURE_USER="admin" \ - CANTALOUPE_LOG_ACCESS_CONSOLEAPPENDER_ENABLED="false" \ + CANTALOUPE_LOG_ACCESS_CONSOLEAPPENDER_ENABLED="true" \ CANTALOUPE_LOG_ACCESS_FILEAPPENDER_ENABLED="false" \ - CANTALOUPE_LOG_ACCESS_FILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.access.log" \ - CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_ENABLED="true" \ - CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.access.log" \ + CANTALOUPE_LOG_ACCESS_FILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.access.log" \ + CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_ENABLED="false" \ + CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.access.log" \ CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_POLICY="TimeBasedRollingPolicy" \ - CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="_opt_tomcat_logs_cantaloupe.access-%d{yyyy-MM-dd}.log" \ + CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="/opt/tomcat/logs/cantaloupe.access-%d{yyyy-MM-dd}.log" \ CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_MAX_HISTORY="30" \ CANTALOUPE_LOG_ACCESS_SYSLOGAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_ACCESS_SYSLOGAPPENDER_FACILITY="LOCAL0" \ CANTALOUPE_LOG_ACCESS_SYSLOGAPPENDER_HOST= \ CANTALOUPE_LOG_ACCESS_SYSLOGAPPENDER_PORT="514" \ - CANTALOUPE_LOG_APPLICATION_CONSOLEAPPENDER_ENABLED="false" \ + CANTALOUPE_LOG_APPLICATION_CONSOLEAPPENDER_ENABLED="true" \ CANTALOUPE_LOG_APPLICATION_CONSOLEAPPENDER_LOGSTASH_ENABLED="false" \ CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_LOGSTASH_ENABLED="false" \ - CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.application.log" \ + CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.application.log" \ CANTALOUPE_LOG_APPLICATION_LEVEL="debug" \ - CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_ENABLED="true" \ + CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_LOGSTASH_ENABLED="false" \ - CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.application.log" \ + CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.application.log" \ CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_POLICY="TimeBasedRollingPolicy" \ - CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="_opt_tomcat_logs_cantaloupe.application-%d{yyyy-MM-dd}.log" \ + CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="/opt/tomcat/logs/cantaloupe.application-%d{yyyy-MM-dd}.log" \ CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_MAX_HISTORY="30" \ CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_FACILITY="LOCAL0" \ @@ -163,18 +163,18 @@ ENV \ CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_PORT="514" \ CANTALOUPE_LOG_ERROR_FILEAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_ERROR_FILEAPPENDER_LOGSTASH_ENABLED="false" \ - CANTALOUPE_LOG_ERROR_FILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.error.log" \ - CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_ENABLED="true" \ + CANTALOUPE_LOG_ERROR_FILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.error.log" \ + CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_ENABLED="false" \ CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_LOGSTASH_ENABLED="false" \ - CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_PATHNAME="_opt_tomcat_logs_cantaloupe.error.log" \ + CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_PATHNAME="/opt/tomcat/logs/cantaloupe.error.log" \ CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_POLICY="TimeBasedRollingPolicy" \ - CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="_opt_tomcat_logs_cantaloupe.error-%d{yyyy-MM-dd}.log" \ + CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN="/opt/tomcat/logs/cantaloupe.error-%d{yyyy-MM-dd}.log" \ CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_MAX_HISTORY="30" \ CANTALOUPE_MAX_PIXELS="400000000" \ CANTALOUPE_METADATA_PRESERVE="false" \ CANTALOUPE_METADATA_RESPECT_ORIENTATION="false" \ CANTALOUPE_OPENJPEGPROCESSOR_PATH_TO_BINARIES= \ - CANTALOUPE_OVERLAYS_BASICSTRATEGY_IMAGE="_path_to_overlay.png" \ + CANTALOUPE_OVERLAYS_BASICSTRATEGY_IMAGE="/path/to/overlay.png" \ CANTALOUPE_OVERLAYS_BASICSTRATEGY_INSET="10" \ CANTALOUPE_OVERLAYS_BASICSTRATEGY_OUTPUT_HEIGHT_THRESHOLD="300" \ CANTALOUPE_OVERLAYS_BASICSTRATEGY_OUTPUT_WIDTH_THRESHOLD="400" \ diff --git a/cantaloupe/README.md b/cantaloupe/README.md index 83387662..fa53185b 100644 --- a/cantaloupe/README.md +++ b/cantaloupe/README.md @@ -167,10 +167,10 @@ additional settings, volumes, ports, etc. | CANTALOUPE_METADATA_PRESERVE | /cantaloupe/metadata/preserve | false | | CANTALOUPE_METADATA_RESPECT_ORIENTATION | /cantaloupe/metadata/respect/orientation | false | | CANTALOUPE_LOG_APPLICATION_LEVEL | /cantaloupe/log/application/level | debug | -| CANTALOUPE_LOG_APPLICATION_CONSOLEAPPENDER_ENABLED | /cantaloupe/log/application/consoleappender/enabled | false | +| CANTALOUPE_LOG_APPLICATION_CONSOLEAPPENDER_ENABLED | /cantaloupe/log/application/consoleappender/enabled | true | | CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_ENABLED | /cantaloupe/log/application/fileappender/enabled | false | | CANTALOUPE_LOG_APPLICATION_FILEAPPENDER_PATHNAME | /cantaloupe/log/application/fileappender/pathname | /opt/tomcat/logs/cantaloupe.application.log | -| CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/application/rollingfileappender/enabled | true | +| CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/application/rollingfileappender/enabled | false | | CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_PATHNAME | /cantaloupe/log/application/rollingfileappender/pathname | /opt/tomcat/logs/cantaloupe.application.log | | CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_POLICY | /cantaloupe/log/application/rollingfileappender/policy | TimeBasedRollingPolicy | | CANTALOUPE_LOG_APPLICATION_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN | /cantaloupe/log/application/rollingfileappender/timebasedrollingpolicy/filename/pattern | /opt/tomcat/logs/cantaloupe.application-%d{yyyy-MM-dd}.log | @@ -179,10 +179,9 @@ additional settings, volumes, ports, etc. | CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_HOST | /cantaloupe/log/application/syslogappender/host | | | CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_PORT | /cantaloupe/log/application/syslogappender/port | 514 | | CANTALOUPE_LOG_APPLICATION_SYSLOGAPPENDER_FACILITY | /cantaloupe/log/application/syslogappender/facility | LOCAL0 | -| CANTALOUPE_LOG_ERROR_CONSOLEAPPENDER_ENABLED | /cantaloupe/log/error/consoleappender/enabled | false | | CANTALOUPE_LOG_ERROR_FILEAPPENDER_ENABLED | /cantaloupe/log/error/fileappender/enabled | false | | CANTALOUPE_LOG_ERROR_FILEAPPENDER_PATHNAME | /cantaloupe/log/error/fileappender/pathname | /opt/tomcat/logs/cantaloupe.error.log | -| CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/error/rollingfileappender/enabled | true | +| CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/error/rollingfileappender/enabled | false | | CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_PATHNAME | /cantaloupe/log/error/rollingfileappender/pathname | /opt/tomcat/logs/cantaloupe.error.log | | CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_POLICY | /cantaloupe/log/error/rollingfileappender/policy | TimeBasedRollingPolicy | | CANTALOUPE_LOG_ERROR_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN | /cantaloupe/log/error/rollingfileappender/timebasedrollingpolicy/filename/pattern | /opt/tomcat/logs/cantaloupe.error-%d{yyyy-MM-dd}.log | @@ -191,10 +190,10 @@ additional settings, volumes, ports, etc. | CANTALOUPE_LOG_ERROR_SYSLOGAPPENDER_HOST | /cantaloupe/log/error/syslogappender/host | | | CANTALOUPE_LOG_ERROR_SYSLOGAPPENDER_PORT | /cantaloupe/log/error/syslogappender/port | 514 | | CANTALOUPE_LOG_ERROR_SYSLOGAPPENDER_FACILITY | /cantaloupe/log/error/syslogappender/facility | LOCAL0 | -| CANTALOUPE_LOG_ACCESS_CONSOLEAPPENDER_ENABLED | /cantaloupe/log/access/consoleappender/enabled | false | +| CANTALOUPE_LOG_ACCESS_CONSOLEAPPENDER_ENABLED | /cantaloupe/log/access/consoleappender/enabled | true | | CANTALOUPE_LOG_ACCESS_FILEAPPENDER_ENABLED | /cantaloupe/log/access/fileappender/enabled | false | | CANTALOUPE_LOG_ACCESS_FILEAPPENDER_PATHNAME | /cantaloupe/log/access/fileappender/pathname | /opt/tomcat/logs/cantaloupe.access.log | -| CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/access/rollingfileappender/enabled | true | +| CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_ENABLED | /cantaloupe/log/access/rollingfileappender/enabled | false | | CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_PATHNAME | /cantaloupe/log/access/rollingfileappender/pathname | /opt/tomcat/logs/cantaloupe.access.log | | CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_POLICY | /cantaloupe/log/access/rollingfileappender/policy | TimeBasedRollingPolicy | | CANTALOUPE_LOG_ACCESS_ROLLINGFILEAPPENDER_TIMEBASEDROLLINGPOLICY_FILENAME_PATTERN | /cantaloupe/log/access/rollingfileappender/timebasedrollingpolicy/filename/pattern | /opt/tomcat/logs/cantaloupe.access-%d{yyyy-MM-dd}.log | diff --git a/cantaloupe/rootfs/etc/cont-init.d/02-cantoloupe-install.sh b/cantaloupe/rootfs/etc/cont-init.d/02-cantoloupe-install.sh deleted file mode 100755 index 6a271751..00000000 --- a/cantaloupe/rootfs/etc/cont-init.d/02-cantoloupe-install.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env bash -set -e - -# Change log files to redirect to stdout/stderr -ln -sf /dev/stdout /opt/tomcat/logs/cantaloupe.access.log -chown tomcat:tomcat /opt/tomcat/logs/cantaloupe.access.log - -ln -sf /dev/stderr /opt/tomcat/logs/cantaloupe.error.log -chown tomcat:tomcat /opt/tomcat/logs/cantaloupe.error.log diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 91d412ff..5c66ed7a 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -250,12 +250,10 @@ function install_site { echo "--host ${host}" echo "--port ${port}" echo "--dbuser ${user}" - echo "--dbpassword ${password}" echo "--dbname ${db_name}" echo "PROFILE: ${profile}" echo "--account-mail=${account_email}" echo "--account-name=${account_name}" - echo "--account-pass=${account_password}" echo "--site-mail=${site_email}" echo "--locale=${site_locale}" echo "--site-name=${site_name}" diff --git a/drupal/rootfs/usr/local/bin/install-drupal-site.sh b/drupal/rootfs/usr/local/bin/install-drupal-site.sh index ef5ad579..f458d302 100755 --- a/drupal/rootfs/usr/local/bin/install-drupal-site.sh +++ b/drupal/rootfs/usr/local/bin/install-drupal-site.sh @@ -164,7 +164,6 @@ function main { protocol=pgsql fi echo "Installing site." - echo "-n si ${DRUSH_ARGS} --db-url=${protocol}://${DB_USER}:${DB_PASSWORD}@${HOST}:${PORT}/${DB_NAME}" drush \ -n \ si ${DRUSH_ARGS} \ diff --git a/nginx/Dockerfile b/nginx/Dockerfile index 14baed17..034bfdf5 100644 --- a/nginx/Dockerfile +++ b/nginx/Dockerfile @@ -49,6 +49,7 @@ ENV \ PHP_MAX_EXECUTION_TIME=30 \ PHP_MAX_FILE_UPLOADS=20 \ PHP_MAX_INPUT_TIME=60 \ + PHP_MAX_INPUT_VARS=3000 \ PHP_MEMORY_LIMIT=256M \ PHP_POST_MAX_SIZE=128M \ PHP_UPLOAD_MAX_FILESIZE=128M diff --git a/nginx/rootfs/etc/confd/templates/php.ini.tmpl b/nginx/rootfs/etc/confd/templates/php.ini.tmpl index cb4631d7..69acacac 100644 --- a/nginx/rootfs/etc/confd/templates/php.ini.tmpl +++ b/nginx/rootfs/etc/confd/templates/php.ini.tmpl @@ -403,7 +403,7 @@ max_input_time = {{ getenv "PHP_MAX_INPUT_TIME" }} ;max_input_nesting_level = 64 ; How many GET/POST/COOKIE input variables may be accepted -;max_input_vars = 1000 +max_input_vars = {{ getenv "PHP_MAX_INPUT_VARS" }} ; Maximum amount of memory a script may consume ; http://php.net/memory-limit From 78e234832557debb61a4ee3a89f02835b9fe97f5 Mon Sep 17 00:00:00 2001 From: Jason Hildebrand Date: Thu, 13 Jan 2022 17:07:34 -0600 Subject: [PATCH 12/25] Refactor how we set/restore ownership of drupal settings file to allow reuse... (#179) * Refactor how we set/restore ownership of drupal settings file to allow reuse in containers based on this one. * Clarify comment. * Adjustments. --- drupal/rootfs/etc/islandora/utilities.sh | 52 +++++++++++++++++++----- 1 file changed, 41 insertions(+), 11 deletions(-) diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 7f7b81a6..7a428cdd 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -284,6 +284,45 @@ function fedora_url { fi } + +# Allow modifications to settings.php by changing ownership and perms +function allow_settings_modifications { + local site="${1}"; shift + local drupal_root=$(drush drupal:directory) + local subdir=$(drupal_site_env "${site}" "SUBDIR") + local site_directory=$(realpath "${drupal_root}/sites/${subdir}") + + # send debug output to stderr because the caller typically captures output from this function. + #>&2 echo "adjusting ownership of ${site_directory}/settings.php" + if [ -f "${site_directory}/settings.php" ]; then + previous_owner_group=$(stat -c "%u:%g" "${site_directory}/settings.php") + chown 100:101 "${site_directory}/settings.php" + chmod a=rwx "${site_directory}/settings.php" + fi + if [ ! -z "${previous_owner_group}" ]; then + echo ${previous_owner_group} + fi +} + +# Restore ownership of settings.php so that it is readable/writable outside of docker +function restore_settings_ownership { + local site="${1}"; shift + local previous_owner_group="${1}"; shift + local drupal_root=$(drush drupal:directory) + local subdir=$(drupal_site_env "${site}" "SUBDIR") + local site_directory=$(realpath "${drupal_root}/sites/${subdir}") + + # Restore owner/group to previous value. + # When the codebase is bind-mounted, this ensures the file remains readable/writable by the host user. + if [ ! -z "${previous_owner_group}" ]; then + chown "${previous_owner_group}" "${site_directory}/settings.php" + fi + + # Restrict access to settings.php + chmod 444 "${site_directory}/settings.php" +} + + # Regenerate / Update settings.php function update_settings_php { local site="${1}"; shift @@ -311,11 +350,7 @@ function update_settings_php { fi # Allow modifications to settings.php - if [ -f "${site_directory}/settings.php" ]; then - previous_owner_group=$(stat -c "%u:%g" "${site_directory}/settings.php") - chown 100:101 "${site_directory}/settings.php" - chmod a=rwx "${site_directory}/settings.php" - fi + local previous_owner_group=$(allow_settings_modifications ${site}) drush -l "${site_url}" islandora:settings:create-settings-if-missing drush -l "${site_url}" islandora:settings:set-hash-salt "${salt}" @@ -336,12 +371,7 @@ function update_settings_php { fi # Restore owner/group to previous value - if [ ! -z "${previous_owner_group}" ]; then - chown "${previous_owner_group}" "${site_directory}/settings.php" - fi - - # Restrict access to settings.php - chmod 444 "${site_directory}/settings.php" + restore_settings_ownership ${site} ${previous_owner_group} } # Enable module and apply configuration. From 25edadbae83e45bafedeff39eebe0b16664334e4 Mon Sep 17 00:00:00 2001 From: Nigel Banks Date: Tue, 25 Jan 2022 07:42:53 +0000 Subject: [PATCH 13/25] Added LDAP extension to nginx/php image. (#181) --- nginx/Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nginx/Dockerfile b/nginx/Dockerfile index 034bfdf5..2044b70e 100644 --- a/nginx/Dockerfile +++ b/nginx/Dockerfile @@ -18,6 +18,7 @@ RUN --mount=type=cache,id=nginx-apk,sharing=locked,from=cache,target=/var/cache/ php7-iconv \ php7-intl \ php7-json \ + php7-ldap \ php7-mbstring \ php7-mysqli \ php7-opcache \ @@ -30,8 +31,8 @@ RUN --mount=type=cache,id=nginx-apk,sharing=locked,from=cache,target=/var/cache/ php7-simplexml \ php7-tokenizer \ php7-xml \ - php7-xmlwriter \ php7-xmlreader \ + php7-xmlwriter \ php7-xsl \ php7-zip \ && \ From a65eb4954dfcda9a4d230947e36f068c94b03384 Mon Sep 17 00:00:00 2001 From: Jason Hildebrand Date: Tue, 1 Feb 2022 10:18:05 -0600 Subject: [PATCH 14/25] If SOLR config.zip cannot be produced, show useful error message. (#182) --- drupal/rootfs/etc/islandora/utilities.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 7a428cdd..af8bdb49 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -456,7 +456,10 @@ function generate_solr_config { mkdir -p "/tmp/${core}" || true chmod a+rwx "/tmp/${core}" - drush -l "${site_url}" -y search-api-solr:get-server-config default_solr_server "/tmp/${core}/solr_config.zip" 7.1 + if ! drush -l "${site_url}" -y search-api-solr:get-server-config default_solr_server "/tmp/${core}/solr_config.zip" 7.1; then + echo -e "\n\nERROR: Could not generate SOLR config.zip!\nIn Drupal, check Configuration -> Search API -> SOLR Server, and use the\n"+ Get config.zip" option which should give you information into the actual error.\n\n" + return 1 + fi mkdir -p "${dest}/conf" || true mkdir -p "${dest}/data" || true unzip -o "/tmp/${core}/solr_config.zip" -d "${dest}/conf" @@ -486,7 +489,7 @@ function create_solr_core_with_default_config { fi local site="${1}"; shift - generate_solr_config "${site}" + generate_solr_config "${site}" || return 1 create_solr_core "${site}" } From b8de904352c809f3b9acef908ab0015b2e3ce7be Mon Sep 17 00:00:00 2001 From: dannylamb Date: Tue, 13 Apr 2021 16:39:02 -0300 Subject: [PATCH 15/25] Updating sandbox commit --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 1b66bbf5..a0925f3d 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=c4a7574e39ba07e1baa51a0d145da1328e7d9ed1 +ARG COMMIT=37797581ab57c0ef17493450db7f8703e3551a56 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 8afd7be6eb75f10f34babfcf4fcd648dae34e08f Mon Sep 17 00:00:00 2001 From: dannylamb Date: Thu, 15 Apr 2021 16:38:07 -0300 Subject: [PATCH 16/25] Trying to pull in the install profile --- demo/Dockerfile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/demo/Dockerfile b/demo/Dockerfile index a0925f3d..0d364f3f 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -4,6 +4,7 @@ ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer ARG COMMIT=37797581ab57c0ef17493450db7f8703e3551a56 +ARG PROFILE_COMMIT=8d3ae73d1c43f76eaa59b8b0f846c12e8140cfe4 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ @@ -16,6 +17,11 @@ RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/ca --worktree /var/www/drupal && \ cd /var/www/drupal && \ composer install && \ + git-clone-cached.sh \ + --url https://github.com/islandora-devops/islandora_install_profile_demo.git \ + --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ + --commit "${PROFILE_COMMIT}" \ + --worktree /var/www/drupal/web/profiles/islandora_install_profile_demo && \ # Set up libraries mkdir -p /var/www/drupal/web/libraries && \ # PDF.js From fac664861c6e506236b1ed7a8e0d18c814a38099 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Fri, 16 Apr 2021 17:05:35 -0300 Subject: [PATCH 17/25] Using install profile variable when installing Drupal with Drush --- demo/Dockerfile | 4 ++-- drupal/rootfs/etc/islandora/utilities.sh | 17 +++++++++++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 0d364f3f..890ba6ab 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,8 +3,8 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=37797581ab57c0ef17493450db7f8703e3551a56 -ARG PROFILE_COMMIT=8d3ae73d1c43f76eaa59b8b0f846c12e8140cfe4 +ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 +ARG PROFILE_COMMIT=9db038fa77e08bbd6dd094da26b4d844f0cd247b # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index af8bdb49..afc83d51 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -246,6 +246,23 @@ function install_site { chmod a=rwx "${site_directory}/settings.php" fi + echo "--driver ${driver}" + echo "--host ${host}" + echo "--port ${port}" + echo "--dbuser ${user}" + echo "--dbpassword ${password}" + echo "--dbname ${db_name}" + echo "PROFILE: ${profile}" + echo "--account-mail=${account_email}" + echo "--account-name=${account_name}" + echo "--account-pass=${account_password}" + echo "--site-mail=${site_email}" + echo "--locale=${site_locale}" + echo "--site-name=${site_name}" + echo "--sites-subdir=${subdir}" + echo "USE_EXISTIG_CONFIG: ${use_existing_config_arg}" + echo "EVERYTHING ELSE: ${@}" + /usr/local/bin/install-drupal-site.sh \ --driver "${driver}" \ --host "${host}" \ From 27fea4bae23985eeaa094e7c01ad36094a531098 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Fri, 23 Apr 2021 17:26:33 -0300 Subject: [PATCH 18/25] Bumping sandbox commit --- demo/Dockerfile | 76 +++++++++---------- .../usr/local/bin/install-drupal-site.sh | 1 + 2 files changed, 36 insertions(+), 41 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 890ba6ab..e4baa133 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,8 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=2c8088235365c3c5bfff850ee82a28bbefe4f368 -ARG PROFILE_COMMIT=9db038fa77e08bbd6dd094da26b4d844f0cd247b +ARG COMMIT=da2be9232842de5931ce9fc531c0472dd8f91c00 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ @@ -16,53 +15,48 @@ RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/ca --commit "${COMMIT}" \ --worktree /var/www/drupal && \ cd /var/www/drupal && \ - composer install && \ - git-clone-cached.sh \ - --url https://github.com/islandora-devops/islandora_install_profile_demo.git \ - --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ - --commit "${PROFILE_COMMIT}" \ - --worktree /var/www/drupal/web/profiles/islandora_install_profile_demo && \ + composer install # Set up libraries - mkdir -p /var/www/drupal/web/libraries && \ + #mkdir -p /var/www/drupal/web/libraries && \ # PDF.js - PDFJS_VERSION="2.0.943" && \ - PDFJS_FILE="pdfjs-${PDFJS_VERSION}-dist.zip" && \ - PDFJS_URL="https://github.com/mozilla/pdf.js/releases/download/v${PDFJS_VERSION}/${PDFJS_FILE}" && \ - PDFJS_SHA256="381683b05f494fe28e11185f98a238b34a663b1b41b5432aa769ca493e5cd087" && \ - download.sh --url "${PDFJS_URL}" --sha256 "${PDFJS_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/pdf.js && \ - unzip "${DOWNLOAD_CACHE_DIRECTORY}/${PDFJS_FILE}" -d /var/www/drupal/web/libraries/pdf.js && \ + #PDFJS_VERSION="2.0.943" && \ + #PDFJS_FILE="pdfjs-${PDFJS_VERSION}-dist.zip" && \ + #PDFJS_URL="https://github.com/mozilla/pdf.js/releases/download/v${PDFJS_VERSION}/${PDFJS_FILE}" && \ + #PDFJS_SHA256="381683b05f494fe28e11185f98a238b34a663b1b41b5432aa769ca493e5cd087" && \ + #download.sh --url "${PDFJS_URL}" --sha256 "${PDFJS_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/pdf.js && \ + #unzip "${DOWNLOAD_CACHE_DIRECTORY}/${PDFJS_FILE}" -d /var/www/drupal/web/libraries/pdf.js && \ # Views Slideshow Dependencies ## jquery.cycle - JQUERY_CYCLE_FILE="jquery.cycle.all.js" && \ - JQUERY_CYCLE_URL="https://raw.githubusercontent.com/malsup/cycle/db79722719a8a5a8b93fb5d5970d7296ff6bd8bc/${JQUERY_CYCLE_FILE}" && \ - JQUERY_CYCLE_SHA256="58b44d975e1e1f0664d0fb8ab5b2918d08e9497324a021aa93de5894cdb586d4" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.cycle && \ - download.sh --url "${JQUERY_CYCLE_URL}" --sha256 "${JQUERY_CYCLE_SHA256}" /var/www/drupal/web/libraries/jquery.cycle && \ + #JQUERY_CYCLE_FILE="jquery.cycle.all.js" && \ + #JQUERY_CYCLE_URL="https://malsup.github.io/${JQUERY_CYCLE_FILE}" && \ + #JQUERY_CYCLE_SHA256="58b44d975e1e1f0664d0fb8ab5b2918d08e9497324a021aa93de5894cdb586d4" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.cycle && \ + #download.sh --url "${JQUERY_CYCLE_URL}" --sha256 "${JQUERY_CYCLE_SHA256}" /var/www/drupal/web/libraries/jquery.cycle && \ ## jquery.hoverIntent - JQUERY_HOVER_INTENT_FILE="jquery.hoverIntent.js" && \ - JQUERY_HOVER_INTENT_URL="https://raw.githubusercontent.com/briancherne/jquery-hoverIntent/60f430c1391ceba429e6a856955a9dbab1d6036d/${JQUERY_HOVER_INTENT_FILE}" && \ - JQUERY_HOVER_INTENT_SHA256="65f5f7e1298fe71f10290f4068df30b38a5df0106d6feb63210ddabcc67c3e59" && \ - download.sh --url "${JQUERY_HOVER_INTENT_URL}" --sha256 "${JQUERY_HOVER_INTENT_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.hoverIntent && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_HOVER_INTENT_FILE}" /var/www/drupal/web/libraries/jquery.hoverIntent && \ + #JQUERY_HOVER_INTENT_FILE="jquery.hoverIntent.js" && \ + #JQUERY_HOVER_INTENT_URL="https://raw.githubusercontent.com/briancherne/jquery-hoverIntent/master/${JQUERY_HOVER_INTENT_FILE}" && \ + #JQUERY_HOVER_INTENT_SHA256="65f5f7e1298fe71f10290f4068df30b38a5df0106d6feb63210ddabcc67c3e59" && \ + #download.sh --url "${JQUERY_HOVER_INTENT_URL}" --sha256 "${JQUERY_HOVER_INTENT_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.hoverIntent && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_HOVER_INTENT_FILE}" /var/www/drupal/web/libraries/jquery.hoverIntent && \ ## jquery.pause - JQUERY_PAUSE_FILE="jquery.pause.js" && \ - JQUERY_PAUSE_URL="https://raw.githubusercontent.com/tobia/Pause/bd9c80f16695cbbd5eb9feec87adce19183aaa74/${JQUERY_PAUSE_FILE}" && \ - JQUERY_PAUSE_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ - download.sh --url "${JQUERY_PAUSE_URL}" --sha256 "${JQUERY_PAUSE_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/jquery.pause && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_PAUSE_FILE}" /var/www/drupal/web/libraries/jquery.pause && \ + #JQUERY_PAUSE_FILE="jquery.pause.js" && \ + #JQUERY_PAUSE_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JQUERY_PAUSE_FILE}" && \ + #JQUERY_PAUSE_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ + #download.sh --url "${JQUERY_PAUSE_URL}" --sha256 "${JQUERY_PAUSE_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/jquery.pause && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JQUERY_PAUSE_FILE}" /var/www/drupal/web/libraries/jquery.pause && \ ## json2 - JSON2_FILE="jquery.pause.js" && \ - JSON2_URL="https://raw.githubusercontent.com/tobia/Pause/bd9c80f16695cbbd5eb9feec87adce19183aaa74/${JSON2_FILE}" && \ - JSON2_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ - download.sh --url "${JSON2_URL}" --sha256 "${JSON2_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ - mkdir -p /var/www/drupal/web/libraries/json2 && \ - cp "${DOWNLOAD_CACHE_DIRECTORY}/${JSON2_FILE}" /var/www/drupal/web/libraries/json2 && \ + #JSON2_FILE="jquery.pause.js" && \ + #JSON2_URL="https://raw.githubusercontent.com/tobia/Pause/master/${JSON2_FILE}" && \ + #JSON2_SHA256="39505a2a9fe36fce5b987f6804723d323ac86d0ed7220a5c12094f1d698fce33" && \ + #download.sh --url "${JSON2_URL}" --sha256 "${JSON2_SHA256}" "${DOWNLOAD_CACHE_DIRECTORY}" && \ + #mkdir -p /var/www/drupal/web/libraries/json2 && \ + #cp "${DOWNLOAD_CACHE_DIRECTORY}/${JSON2_FILE}" /var/www/drupal/web/libraries/json2 && \ # Openseadragon - mkdir -p /var/www/drupal/web/sites/default/files/library-definitions && \ - cp /var/www/drupal/web/modules/contrib/openseadragon/openseadragon.json /var/www/drupal/web/sites/default/files/library-definitions + #mkdir -p /var/www/drupal/web/sites/default/files/library-definitions && \ + #cp /var/www/drupal/web/modules/contrib/openseadragon/openseadragon.json /var/www/drupal/web/sites/default/files/library-definitions FROM ${repository}/drupal:${tag} diff --git a/drupal/rootfs/usr/local/bin/install-drupal-site.sh b/drupal/rootfs/usr/local/bin/install-drupal-site.sh index f458d302..ef5ad579 100755 --- a/drupal/rootfs/usr/local/bin/install-drupal-site.sh +++ b/drupal/rootfs/usr/local/bin/install-drupal-site.sh @@ -164,6 +164,7 @@ function main { protocol=pgsql fi echo "Installing site." + echo "-n si ${DRUSH_ARGS} --db-url=${protocol}://${DB_USER}:${DB_PASSWORD}@${HOST}:${PORT}/${DB_NAME}" drush \ -n \ si ${DRUSH_ARGS} \ From 598e9aa4071527a011888a5a0316be616f3dcc8c Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 26 Apr 2021 23:38:09 -0300 Subject: [PATCH 19/25] Setting content sync directory --- demo/Dockerfile | 2 +- drupal/rootfs/etc/islandora/utilities.sh | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index e4baa133..52cc103d 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=da2be9232842de5931ce9fc531c0472dd8f91c00 +ARG COMMIT=8a6594d44a53d0883a36802c011d924a320ee427 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index afc83d51..91ae8386 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -369,6 +369,11 @@ function update_settings_php { # Allow modifications to settings.php local previous_owner_group=$(allow_settings_modifications ${site}) + if ! grep -q 'global \$content_directories;' ${site_directory}/settings.php; then + echo 'global $content_directories;' >> ${site_directory}/settings.php + echo '$content_directories['sync'] = $app_root . "/../content/sync";' >> ${site_directory}/settings.php + fi + drush -l "${site_url}" islandora:settings:create-settings-if-missing drush -l "${site_url}" islandora:settings:set-hash-salt "${salt}" drush -l "${site_url}" islandora:settings:set-flystem-fedora-url "${fedora_url}" From c55ad3ff754308f9878237e1f7ab2fa482fd67c7 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 10:25:53 -0300 Subject: [PATCH 20/25] Fixing content_sync directories --- demo/Dockerfile | 2 +- drupal/rootfs/etc/islandora/utilities.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 52cc103d..16d6196d 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=8a6594d44a53d0883a36802c011d924a320ee427 +ARG COMMIT=26c072273747523c0af7305eececd47de1940c34 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 91ae8386..66fe9b28 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -371,7 +371,7 @@ function update_settings_php { if ! grep -q 'global \$content_directories;' ${site_directory}/settings.php; then echo 'global $content_directories;' >> ${site_directory}/settings.php - echo '$content_directories['sync'] = $app_root . "/../content/sync";' >> ${site_directory}/settings.php + echo '$content_directories["sync"] = "/var/www/drupal/content/sync";' >> ${site_directory}/settings.php fi drush -l "${site_url}" islandora:settings:create-settings-if-missing From 7cf1172eab8ed1fe25a4ae34ecaa721df01b3461 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 13:48:08 -0300 Subject: [PATCH 21/25] Bumping islandora-sandbox --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 16d6196d..30e1c380 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=26c072273747523c0af7305eececd47de1940c34 +ARG COMMIT=f89cfbb85b72e6d2c7330e72407fab84179cc27e # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 4b52d5b549fdb3609f1cb3576ccf67d4f8990df3 Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 17 May 2021 13:58:34 -0300 Subject: [PATCH 22/25] Bumping sandbox again --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index 30e1c380..b4f066b3 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=f89cfbb85b72e6d2c7330e72407fab84179cc27e +ARG COMMIT=a920f36ea87f24e0583c3d351bb7af0c89dad34c # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 2b693822bbb2f50e40c84c7249b191d3ed9f630c Mon Sep 17 00:00:00 2001 From: dannylamb Date: Mon, 22 Nov 2021 17:01:18 -0400 Subject: [PATCH 23/25] Updating sandbox hash --- demo/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index b4f066b3..cff00463 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,7 +3,7 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=a920f36ea87f24e0583c3d351bb7af0c89dad34c +ARG COMMIT=67b8e87ddd5c5b5a01522aaf3129ad4c661cb76d # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ From 168d0309aee4942feee6ea640326693ab58f224f Mon Sep 17 00:00:00 2001 From: Rosie Le Faive Date: Tue, 14 Dec 2021 10:43:02 -0400 Subject: [PATCH 24/25] Update commit for islandora-sandbox and use official repo. --- demo/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/demo/Dockerfile b/demo/Dockerfile index cff00463..2919d247 100644 --- a/demo/Dockerfile +++ b/demo/Dockerfile @@ -3,14 +3,14 @@ ARG repository=local ARG tag=latest FROM --platform=$BUILDPLATFORM ${repository}/composer:${tag} AS composer -ARG COMMIT=67b8e87ddd5c5b5a01522aaf3129ad4c661cb76d +ARG COMMIT=4012e56a5c88b0a9a3686f1e51cd4f4da5ff13e4 # Islandora based Drupal install. RUN --mount=type=cache,id=demo-composer,sharing=locked,target=/root/.composer/cache \ --mount=type=cache,id=demo-downloads,sharing=locked,target=/opt/downloads \ # Get the Drupal codebase git-clone-cached.sh \ - --url https://github.com/dannylamb/islandora-sandbox.git \ + --url https://github.com/Islandora-Devops/islandora-sandbox.git \ --cache-dir "${DOWNLOAD_CACHE_DIRECTORY}" \ --commit "${COMMIT}" \ --worktree /var/www/drupal && \ From fa963514027cf6760c3823c25b86cd4e19798339 Mon Sep 17 00:00:00 2001 From: Nigel Banks Date: Wed, 5 Jan 2022 19:08:22 +0000 Subject: [PATCH 25/25] Install profile review (#177) * Fix logging errors with cantaloupe due to find/replace bug (#165) * Adding max_input_vars to php.ini (#166) * Explain how Docker Hub factors in the workflow. (#171) * Updated the introduction to redirect users to better starting points in case they ended up at this repo by accident. (#164) * [issue-172] Use explicit commits in URLs such that (#176) Code can change when pulling from a master branch, which causes checksum checks to fail. This can changes master to instead refer to explicit commits hashes. The output docker images is byte for byte the same though. * Prevent passwords from being logged. Co-authored-by: dannylamb Co-authored-by: Rosie Le Faive --- drupal/rootfs/etc/islandora/utilities.sh | 2 -- drupal/rootfs/usr/local/bin/install-drupal-site.sh | 1 - 2 files changed, 3 deletions(-) diff --git a/drupal/rootfs/etc/islandora/utilities.sh b/drupal/rootfs/etc/islandora/utilities.sh index 66fe9b28..58b3d053 100755 --- a/drupal/rootfs/etc/islandora/utilities.sh +++ b/drupal/rootfs/etc/islandora/utilities.sh @@ -250,12 +250,10 @@ function install_site { echo "--host ${host}" echo "--port ${port}" echo "--dbuser ${user}" - echo "--dbpassword ${password}" echo "--dbname ${db_name}" echo "PROFILE: ${profile}" echo "--account-mail=${account_email}" echo "--account-name=${account_name}" - echo "--account-pass=${account_password}" echo "--site-mail=${site_email}" echo "--locale=${site_locale}" echo "--site-name=${site_name}" diff --git a/drupal/rootfs/usr/local/bin/install-drupal-site.sh b/drupal/rootfs/usr/local/bin/install-drupal-site.sh index ef5ad579..f458d302 100755 --- a/drupal/rootfs/usr/local/bin/install-drupal-site.sh +++ b/drupal/rootfs/usr/local/bin/install-drupal-site.sh @@ -164,7 +164,6 @@ function main { protocol=pgsql fi echo "Installing site." - echo "-n si ${DRUSH_ARGS} --db-url=${protocol}://${DB_USER}:${DB_PASSWORD}@${HOST}:${PORT}/${DB_NAME}" drush \ -n \ si ${DRUSH_ARGS} \