# Community Directory: Apache (2.4+) access rules.
DirectoryIndex index.php
Options -Indexes

# Include-only PHP files, the config, and the command-line job are never served.
<FilesMatch "^(config|lib|mailer|form|header|footer|cron)\.php$">
    Require all denied
</FilesMatch>

# Example config, docs, databases, backups, logs and dotfiles.
<FilesMatch "(\.example|\.md|\.sqlite.*|\.db|\.bak.*|\.log|\.conf)$|^\.">
    Require all denied
</FilesMatch>

# Block the data directory and the git metadata even if the rules above change.
RedirectMatch 404 (?i)/(data|docs|\.git)(/|$)
