mirror of
https://github.com/hoellen/dockerfiles.git
synced 2025-07-02 23:25:41 +00:00
piwik: migrate underlying image to nginx-php
This commit is contained in:
46
piwik/rootfs/nginx/sites-enabled/nginx.conf
Normal file
46
piwik/rootfs/nginx/sites-enabled/nginx.conf
Normal file
@ -0,0 +1,46 @@
|
||||
server {
|
||||
listen 8888;
|
||||
root /piwik;
|
||||
index index.php index.html;
|
||||
|
||||
location ~* \.(?:bat|git|ini|sh|svn[^.]*|txt|tpl|xml)$ {
|
||||
return 404;
|
||||
}
|
||||
|
||||
location ~* \.(jpg|jpeg|gif|css|png|js|map|woff|woff2|ttf|svg|eot)$ {
|
||||
expires 30d;
|
||||
access_log off;
|
||||
}
|
||||
|
||||
location = /favicon.ico {
|
||||
try_files /favicon.ico =204;
|
||||
}
|
||||
|
||||
location ~* ^/(?:README|LICENSE[^.]*|LEGALNOTICE)(?:\.txt)*$ {
|
||||
return 404;
|
||||
}
|
||||
|
||||
location ~ ^/(vendor|config|tmp|libs|misc) {
|
||||
deny all;
|
||||
return 404;
|
||||
}
|
||||
|
||||
location ~* /(.*)\.(?:markdown|md|twig|yaml|yml|ht|htaccess|ini)$ {
|
||||
deny all;
|
||||
}
|
||||
|
||||
location ~ /\. {
|
||||
deny all;
|
||||
}
|
||||
|
||||
location / {
|
||||
try_files $uri /index.php;
|
||||
}
|
||||
|
||||
location ~ \.php$ {
|
||||
fastcgi_index index.php;
|
||||
fastcgi_pass unix:/php/run/php-fpm.sock;
|
||||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
||||
include /nginx/conf/fastcgi_params;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user