Files

34 lines
1.0 KiB
Plaintext
Raw Permalink Normal View History

# casjaysdevdocker/ampache - Apache vhost for Ampache
#
# DocumentRoot is the upstream-blessed `public/` subfolder of the Ampache
# install (see https://ampache.org/docs/installation).
<VirtualHost *:80>
ServerName casjaysdev-ampache
DocumentRoot /usr/local/share/ampache/public
<Directory /usr/local/share/ampache/public>
Options FollowSymLinks
AllowOverride All
Require all granted
# Ampache's REST API needs the Authorization header passed through.
SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1
</Directory>
# Block .git and other dotfile dirs.
<DirectoryMatch "^/.*/\.(git|svn|hg)/">
Require all denied
</DirectoryMatch>
# Hand .php files to php-fpm over its unix socket.
<FilesMatch "\.php$">
SetHandler "proxy:unix:/run/php-fpm/php-fpm.sock|fcgi://localhost"
</FilesMatch>
DirectoryIndex index.php index.html
ErrorLog /data/logs/apache2/ampache_error.log
CustomLog /data/logs/apache2/ampache_access.log combined
</VirtualHost>