# Laravel front-controller routing + PHP-FPM handoff via mod_proxy_fcgi.
# Appended to the base httpd.conf (see docker/apache/Dockerfile).

<Directory "/var/www/html/public">
    Options Indexes FollowSymLinks
    AllowOverride None
    Require all granted

    RewriteEngine On
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^ index.php [L]
</Directory>

<FilesMatch \.php$>
    SetHandler "proxy:fcgi://app:9000"
</FilesMatch>

<FilesMatch "^\.">
    Require all denied
</FilesMatch>
