blob: b0a637f5181cd981fd3a5cdf794ff926004b3edc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
server {
listen 80;
server_name librenms.example.com;
root /usr/share/webapps/librenms/html;
index index.php;
access_log /usr/share/webapps/librenms/logs/access_log;
error_log /usr/share/webapps/librenms/logs/error_log;
location / {
try_files $uri $uri/ @librenms;
}
location ~ \.php {
fastcgi_param PATH_INFO $fastcgi_path_info;
include fastcgi.conf;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
}
location ~ /\.ht {
deny all;
}
location @librenms {
rewrite api/v0(.*)$ /api_v0.php/$1 last;
rewrite ^(.+)$ /index.php/$1 last;
}
}
|