mirror of
https://github.com/zonemaster/zonemaster-gui.git
synced 2025-11-22 16:31:04 +01:00
29 lines
965 B
Text
29 lines
965 B
Text
<VirtualHost *:80>
|
|
DocumentRoot /var/www/zonemaster/public
|
|
DirectoryIndex index.html
|
|
|
|
# Define base url for rewriting, needs a trailing slash.
|
|
Define BASE_URL "/"
|
|
|
|
<Directory /var/www/zonemaster/public>
|
|
Options Indexes FollowSymLinks
|
|
AllowOverride None
|
|
Require all granted
|
|
|
|
RewriteEngine On
|
|
|
|
# Rewrite /result/{anything} to /result/id/index.html
|
|
RewriteCond %{REQUEST_FILENAME} !-f
|
|
RewriteCond %{REQUEST_FILENAME} !-d
|
|
RewriteRule ^result/[^/]+/?$ /result/id/index.html [L]
|
|
|
|
# Rewrite /{lang}/result/{anything} to /{lang}/result/id/index.html
|
|
RewriteCond %{REQUEST_FILENAME} !-f
|
|
RewriteCond %{REQUEST_FILENAME} !-d
|
|
RewriteRule ^([^/]+)/result/[^/]+/?$ /$1/result/id/index.html [L]
|
|
</Directory>
|
|
|
|
ProxyPass ${BASE_URL}api http://localhost:5000/
|
|
ProxyPassReverse ${BASE_URL}api http://localhost:5000/
|
|
ProxyPreserveHost On
|
|
</VirtualHost>
|