File: //etc/nginx/sites-enabled/red40.hs.shared.masterhost.ru.conf
# MANAGED BY PUPPET
server {
listen 10.16.10.103:80 default_server;
listen 90.156.142.141:80 default_server;
server_name red40.hs.shared.masterhost.ru;
set $limit_req_key "$host$request_method$server_protocol$request_uri";
error_log /home/log/nginx/red40.hs.shared.masterhost.ru.error.log;
location /status/php83 {
proxy_pass http://127.0.0.1:8083/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php55 {
proxy_pass http://127.0.0.1:8055/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php55 {
proxy_pass http://127.0.0.1:8055;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php80 {
proxy_pass http://127.0.0.1:8080/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php82 {
proxy_pass http://127.0.0.1:8082/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php70 {
proxy_pass http://127.0.0.1:8070/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php72 {
proxy_pass http://127.0.0.1:8072;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php80 {
proxy_pass http://127.0.0.1:8080;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php74 {
proxy_pass http://127.0.0.1:8074/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php71 {
proxy_pass http://127.0.0.1:8071/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php52 {
proxy_pass http://127.0.0.1:8052/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php81 {
proxy_pass http://127.0.0.1:8081/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /nagios-check/ {
allow 10.93.2.0/24;
allow 90.156.133.32/27;
allow 90.156.170.0/27;
deny all;
ssi on;
root /home/beX/nagios/nginx;
index index.shtml;
}
location / {
root /home/beX;
try_files /index.shtml =503;
}
location /checks/php53 {
proxy_pass http://127.0.0.1:8053;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /robots.txt {
root /home/beX;
}
location /status/php72 {
proxy_pass http://127.0.0.1:8072/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php53 {
proxy_pass http://127.0.0.1:8053/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php56 {
proxy_pass http://127.0.0.1:8056;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php82 {
proxy_pass http://127.0.0.1:8082;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php71 {
proxy_pass http://127.0.0.1:8071;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php84 {
proxy_pass http://127.0.0.1:8084/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php81 {
proxy_pass http://127.0.0.1:8081;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php84 {
proxy_pass http://127.0.0.1:8084;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php56 {
proxy_pass http://127.0.0.1:8056/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php54 {
proxy_pass http://127.0.0.1:8054;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php70 {
proxy_pass http://127.0.0.1:8070;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status {
if ($http_referer ~ /checks/php52) {
rewrite (.*) /status/php52 last;
}
if ($http_referer ~ /checks/php53) {
rewrite (.*) /status/php53 last;
}
if ($http_referer ~ /checks/php54) {
rewrite (.*) /status/php54 last;
}
if ($http_referer ~ /checks/php55) {
rewrite (.*) /status/php55 last;
}
if ($http_referer ~ /checks/php56) {
rewrite (.*) /status/php56 last;
}
if ($http_referer ~ /checks/php70) {
rewrite (.*) /status/php70 last;
}
if ($http_referer ~ /checks/php71) {
rewrite (.*) /status/php71 last;
}
if ($http_referer ~ /checks/php72) {
rewrite (.*) /status/php72 last;
}
if ($http_referer ~ /checks/php73) {
rewrite (.*) /status/php73 last;
}
if ($http_referer ~ /checks/php74) {
rewrite (.*) /status/php74 last;
}
if ($http_referer ~ /checks/php80) {
rewrite (.*) /status/php80 last;
}
if ($http_referer ~ /checks/php81) {
rewrite (.*) /status/php81 last;
}
if ($http_referer ~ /checks/php82) {
rewrite (.*) /status/php82 last;
}
if ($http_referer ~ /checks/php83) {
rewrite (.*) /status/php83 last;
}
if ($http_referer ~ /checks/php84) {
rewrite (.*) /status/php84 last;
}
return 403;
}
location /status/php73 {
proxy_pass http://127.0.0.1:8073/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php52 {
proxy_pass http://127.0.0.1:8052;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php73 {
proxy_pass http://127.0.0.1:8073;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php83 {
proxy_pass http://127.0.0.1:8083;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /status/php54 {
proxy_pass http://127.0.0.1:8054/status;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/php74 {
proxy_pass http://127.0.0.1:8074;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
location /checks/ {
proxy_pass http://127.0.0.1:8070/checks/mphp.shtml;
proxy_read_timeout 10m;
proxy_connect_timeout 75s;
proxy_send_timeout 10m;
proxy_redirect off;
proxy_pass_header Server;
}
}