44 lines
1.0 KiB
Plaintext
44 lines
1.0 KiB
Plaintext
upstream netdata {
|
|
server 127.0.0.1:19999;
|
|
keepalive 64;
|
|
}
|
|
|
|
server {
|
|
listen 80;
|
|
root /var/www/backend/html;
|
|
index index.php index.html;
|
|
server_name DOMAINname;
|
|
|
|
|
|
location = /backend/netdata {
|
|
return 301 /netdata/;
|
|
}
|
|
|
|
location ~ /backend/netdata/(?<ndpath>.*) {
|
|
proxy_redirect off;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Forwarded-Host $host;
|
|
proxy_set_header X-Forwarded-Server $host;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_http_version 1.1;
|
|
proxy_pass_request_headers on;
|
|
proxy_set_header Connection "keep-alive";
|
|
proxy_store off;
|
|
proxy_pass http://netdata/$ndpath$is_args$args;
|
|
}
|
|
|
|
location /backend/database {
|
|
root /usr/share/phpmyadmin;
|
|
try_files $uri $uri/ /index.php$is_args$args;
|
|
}
|
|
|
|
location ~ \.php$ {
|
|
include snippets/fastcgi-php.conf;
|
|
fastcgi_pass unix:/var/run/php/phpPHPver-fpm.sock;
|
|
}
|
|
|
|
location ~ /\.ht {
|
|
deny all;
|
|
}
|
|
|
|
} |