make apache config modular

Signed-off-by: Basil Bruhn <basil.bruhn@psi.ch>
This commit is contained in:
2025-11-11 12:42:02 +01:00
parent fe99b08bdd
commit 2280fb03ad
3 changed files with 17 additions and 33 deletions
-30
View File
@@ -1,30 +0,0 @@
# Enable modules
LoadModule cgi_module modules/mod_cgi.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule php_module modules/libphp.so # already in php:8.2-apache
# Disable default doc root
<Directory "/var/www/html">
Require all denied
</Directory>
# RFMTools
DocumentRoot "/var/www/rfmwtools"
<Directory "/var/www/rfmwtools">
Options +ExecCGI +FollowSymLinks
AddHandler cgi-script .sh .cgi
Require all granted
</Directory>
# Optional: PHP apps under /phpapps (not enabled yet)
<Directory "/var/www/phpapps">
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
# Aliases for PHP apps (commented until ready)
#Alias /phpapp1/ /var/www/phpapps/app1/
#Alias /phpapp2/ /var/www/phpapps/app2/
+15
View File
@@ -0,0 +1,15 @@
<VirtualHost *:80>
ServerName rfmwtools-test.psi.ch
DocumentRoot /var/www/rfmwtools
<Directory "/var/www/rfmwtools">
Options +ExecCGI +FollowSymLinks
AddHandler cgi-script .sh .cgi
Require all granted
</Directory>
ErrorLog /proc/self/fd/2
CustomLog /proc/self/fd/1 combined
</VirtualHost>
+2 -3
View File
@@ -30,9 +30,8 @@ services:
restart: always
volumes:
- /opt/webcontent/rfmwtools:/var/www/rfmwtools:ro
# Apache config is prepared to have php apps inside /var/www/phpapps
# - ./phpapps:/var/www/phpapps:ro
- ./apache/conf/httpd.conf:/usr/local/etc/apache2/httpd.conf:ro
- ./apache/conf/rfmwtools.conf:/etc/apache2/sites-enabled/rfmwtools.conf:ro
networks:
- backend