26 lines
916 B
ApacheConf
26 lines
916 B
ApacheConf
<IfModule mod_rewrite.c>
|
|
RewriteEngine On
|
|
|
|
# Module API routing
|
|
RewriteRule ^api/license/v1(?:/(.*))?$ public/api/license/v1/index.php [L,QSA]
|
|
RewriteRule ^api/watchdog/v1(?:/(.*))?$ public/api/watchdog/v1/index.php [L,QSA]
|
|
RewriteRule ^api/updateservice/v1(?:/(.*))?$ public/api/updateservice/v1/index.php [L,QSA]
|
|
|
|
# Fallback for static assets in /api/
|
|
RewriteRule ^api/(.*)$ public/api/$1 [L,QSA]
|
|
|
|
# Route /install_db.php
|
|
RewriteRule ^install_db\.php$ public/install_db.php [L,QSA]
|
|
|
|
# Route /login.php & /logout.php
|
|
RewriteRule ^login\.php$ public/login.php [L,QSA]
|
|
RewriteRule ^logout\.php$ public/logout.php [L,QSA]
|
|
|
|
# Route root requests to public/index.php
|
|
RewriteRule ^$ public/index.php [L]
|
|
RewriteRule ^index\.php$ public/index.php [L]
|
|
|
|
# Block direct access to sensitive folders
|
|
RewriteRule ^(config|src|sql|scripts)/ - [F,L]
|
|
</IfModule>
|