From 64b49356312e9ce759bbb2229b63bc92f3a4ac51 Mon Sep 17 00:00:00 2001 From: Basil Bruhn Date: Tue, 25 Nov 2025 09:47:38 +0100 Subject: [PATCH] srem Signed-off-by: Basil Bruhn --- apache/conf/srem.conf | 22 ++++++++++++++++++++++ conf.d/srem-test.conf | 30 ++++++++++++++++++++++++++++++ docker-compose.yaml | 2 ++ 3 files changed, 54 insertions(+) create mode 100644 apache/conf/srem.conf create mode 100644 conf.d/srem-test.conf diff --git a/apache/conf/srem.conf b/apache/conf/srem.conf new file mode 100644 index 0000000..1cbfad4 --- /dev/null +++ b/apache/conf/srem.conf @@ -0,0 +1,22 @@ + + ServerName srem-test.psi.ch + DocumentRoot /var/www/srem + + # Allow CGI everywhere if needed + Options +ExecCGI + AddHandler cgi-script .pl .cgi + + + Options +ExecCGI + AllowOverride None + Require all granted + + + # Explicit CGI directories + ScriptAlias /cgibin/ /var/www/srem/cgibin/ + + Options +ExecCGI + Require all granted + + + diff --git a/conf.d/srem-test.conf b/conf.d/srem-test.conf new file mode 100644 index 0000000..8a3f17d --- /dev/null +++ b/conf.d/srem-test.conf @@ -0,0 +1,30 @@ +server { + listen 80; + server_name srem-test.psi.ch; + + return 301 https://$host$request_uri; +} + +server { + listen 443 ssl; + server_name srem-test.psi.ch; + + ssl_certificate /etc/nginx/certs/srem-test.psi.ch.crt; + ssl_certificate_key /etc/nginx/private/srem-test.psi.ch.key; + + access_log /var/log/nginx/srem-test.access.log; + error_log /var/log/nginx/srem-test.error.log; + + # Proxy EVERYTHING to the Apache container + location / { + proxy_pass http://apache_app:80; + + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + + # Important for CGI apps + proxy_buffering off; + } +} + diff --git a/docker-compose.yaml b/docker-compose.yaml index 8494244..9fa2e0c 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -31,9 +31,11 @@ services: restart: always volumes: - /opt/webcontent/rfmwtools:/var/www/rfmwtools:ro + - /opt/webcontent/srem/new_srem_webpage:/var/www/srem:ro - /opt/webcontent/gfa-status:/var/www/gfa-status:rw - /opt/webcontent/fluid-eos:/var/www/fluid-eos:rw - ./apache/conf/rfmwtools.conf:/etc/apache2/sites-enabled/rfmwtools.conf:ro + - ./apache/conf/srem.conf:/etc/apache2/sites-enabled/srem.conf:ro - ./apache/conf/gfa-status.conf:/etc/apache2/sites-enabled/gfa-status.conf:ro - ./apache/conf/fluid-eos.conf:/etc/apache2/sites-enabled/fluid-eos.conf:ro networks: