mirror of
https://github.com/FOSSBilling/FOSSBilling.git
synced 2026-11-30 12:18:43 +09:00
57 lines
1.2 KiB
Plaintext
57 lines
1.2 KiB
Plaintext
worker_processes 1;
|
|
|
|
events { worker_connections 1024; }
|
|
|
|
http {
|
|
|
|
server {
|
|
|
|
set $root_path '/var/www/html/src';
|
|
listen 80;
|
|
|
|
server_name localhost;
|
|
|
|
index index.php index.html index.htm;
|
|
root $root_path;
|
|
try_files $uri $uri/ @rewrite;
|
|
|
|
sendfile off;
|
|
|
|
include /etc/nginx/mime.types;
|
|
|
|
location @rewrite {
|
|
rewrite ^/(.*)$ /index.php?_url=/$1;
|
|
}
|
|
|
|
location ~ \.php {
|
|
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
|
|
|
#pass to upstream configured in global nginx.conf
|
|
fastcgi_pass php:9000;
|
|
|
|
fastcgi_param PATH_INFO $fastcgi_path_info;
|
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
|
fastcgi_intercept_errors on;
|
|
|
|
include fastcgi_params;
|
|
}
|
|
|
|
# Disable PHP execution in bb-uploads and bb-data
|
|
location ^~ /bb-uploads/ { }
|
|
location ^~ /bb-data/ {
|
|
deny all;
|
|
}
|
|
|
|
location ~* ^/(css|img|js|flv|swf|download)/(.+)$ {
|
|
root $root_path;
|
|
expires off;
|
|
proxy_no_cache 1;
|
|
proxy_cache_bypass 1;
|
|
}
|
|
|
|
location ~ /\.ht {
|
|
deny all;
|
|
}
|
|
|
|
}
|
|
} |