From a3fc3d9eacdc72fd399737410740690c490173ab Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Thu, 6 Nov 2025 13:16:08 +0100 Subject: [PATCH 1/7] Set reverse proxy settings via env. Keep default behaviour --- .env | 4 +- .../drupal/drupal.reverse-proxy-settings.php | 106 ++++++++++++++++++ config/drupal/settings.php | 73 +----------- docker-compose.yml | 4 + dockerfile | 1 + entrypoint.sh | 3 + 6 files changed, 121 insertions(+), 70 deletions(-) create mode 100644 config/drupal/drupal.reverse-proxy-settings.php diff --git a/.env b/.env index a5d954a..c343410 100644 --- a/.env +++ b/.env @@ -6,4 +6,6 @@ DB_PORT=5432 DRUPAL_ADMIN_USER=dipasadmin DRUPAL_ADMIN_PASS=adminpassword DRUPAL_SITE_NAME=DIPAS -DRUPAL_SITE_DOMAIN=mydomain.com \ No newline at end of file + +REVERSE_PROXY='true' +REVERSE_PROXY_ADDRESSES='127.0.0.1' \ No newline at end of file diff --git a/config/drupal/drupal.reverse-proxy-settings.php b/config/drupal/drupal.reverse-proxy-settings.php new file mode 100644 index 0000000..8ea2152 --- /dev/null +++ b/config/drupal/drupal.reverse-proxy-settings.php @@ -0,0 +1,106 @@ + Date: Thu, 6 Nov 2025 13:17:19 +0100 Subject: [PATCH 2/7] Fix [error] The following modules are required: locale --- entrypoint.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/entrypoint.sh b/entrypoint.sh index 17e09d7..1eff4ec 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -93,6 +93,9 @@ else --account-name=${DRUPAL_ADMIN_USER} --account-pass=${DRUPAL_ADMIN_PASS} \ --site-name='${DRUPAL_SITE_NAME}' --yes --existing-config" + # Enable locale module before importing translations + su www-data -s /bin/bash -c "vendor/bin/drush pm-enable locale -y" + # Import translation files su www-data -s /bin/bash -c "vendor/bin/drush locale:import de /var/www/html/dipas/config/de.po --type=not-customized" su www-data -s /bin/bash -c "vendor/bin/drush locale:import de /var/www/html/dipas/htdocs/drupal/modules/custom/dipas_stories/files/translations/dipas_stories.de.po --type=not-customized" From 40ac60f08af6aeab4302fb8c3eaee17d5fb6e4b9 Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Thu, 6 Nov 2025 13:17:56 +0100 Subject: [PATCH 3/7] Update dipas to version 4.0.10 --- dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerfile b/dockerfile index c521285..868537c 100644 --- a/dockerfile +++ b/dockerfile @@ -20,7 +20,7 @@ RUN echo "zend_extension=opcache.so" > /usr/local/etc/php/conf.d/docker-php-ext- && echo "opcache.enable_cli=1" >> /usr/local/etc/php/conf.d/docker-php-ext-opcache.ini # Copy and extract project files -RUN wget -O /var/www/html/dipas.zip https://bitbucket.org/geowerkstatt-hamburg/dipas/downloads/dipas-os-3.3.2.zip \ +RUN wget -O /var/www/html/dipas.zip https://bitbucket.org/geowerkstatt-hamburg/dipas/downloads/dipas-os-4.0.10.zip \ && unzip /var/www/html/dipas.zip -d /var/www/html/dipas/ \ && rm -rf /var/www/html/dipas.zip From df520e9ddabb6f2c575404b3abf411061cbe7186 Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Thu, 6 Nov 2025 13:20:13 +0100 Subject: [PATCH 4/7] Add DRUPAL_SITE_DOMAIN back to env --- .env | 1 + 1 file changed, 1 insertion(+) diff --git a/.env b/.env index c343410..e89f837 100644 --- a/.env +++ b/.env @@ -6,6 +6,7 @@ DB_PORT=5432 DRUPAL_ADMIN_USER=dipasadmin DRUPAL_ADMIN_PASS=adminpassword DRUPAL_SITE_NAME=DIPAS +DRUPAL_SITE_DOMAIN=mydomain.com REVERSE_PROXY='true' REVERSE_PROXY_ADDRESSES='127.0.0.1' \ No newline at end of file From 35c8e4fc49aaaf66b0d44ae46a2b20d7249ea263 Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Thu, 6 Nov 2025 13:22:00 +0100 Subject: [PATCH 5/7] Remove test proxy network from docker compose --- docker-compose.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index eb3bf0e..5f7779b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -53,6 +53,4 @@ volumes: networks: dipas-network: - traefik-network: - external: true From ebb0ccf592a868e5096c8a37e2396d02324a2143 Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Tue, 25 Nov 2025 13:04:32 +0100 Subject: [PATCH 6/7] Install Dipas 4.0.11 --- dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerfile b/dockerfile index 868537c..0120ca5 100644 --- a/dockerfile +++ b/dockerfile @@ -20,7 +20,7 @@ RUN echo "zend_extension=opcache.so" > /usr/local/etc/php/conf.d/docker-php-ext- && echo "opcache.enable_cli=1" >> /usr/local/etc/php/conf.d/docker-php-ext-opcache.ini # Copy and extract project files -RUN wget -O /var/www/html/dipas.zip https://bitbucket.org/geowerkstatt-hamburg/dipas/downloads/dipas-os-4.0.10.zip \ +RUN wget -O /var/www/html/dipas.zip https://bitbucket.org/geowerkstatt-hamburg/dipas/downloads/dipas-os-4.0.11.zip \ && unzip /var/www/html/dipas.zip -d /var/www/html/dipas/ \ && rm -rf /var/www/html/dipas.zip From c5c879e37938e7283ab77d254dc8693e367bd79f Mon Sep 17 00:00:00 2001 From: Janos Katein Date: Tue, 25 Nov 2025 13:05:02 +0100 Subject: [PATCH 7/7] Rename reverse proxy enabled field --- .env | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env b/.env index e89f837..e45f4df 100644 --- a/.env +++ b/.env @@ -8,5 +8,5 @@ DRUPAL_ADMIN_PASS=adminpassword DRUPAL_SITE_NAME=DIPAS DRUPAL_SITE_DOMAIN=mydomain.com -REVERSE_PROXY='true' +REVERSE_PROXY_ENABLED='true' REVERSE_PROXY_ADDRESSES='127.0.0.1' \ No newline at end of file