Skip to content

Instantly share code, notes, and snippets.

@nkgokul
Created January 29, 2019 06:28
Show Gist options
  • Save nkgokul/0cc2966fca1960476bd4eb6474f32f02 to your computer and use it in GitHub Desktop.
Save nkgokul/0cc2966fca1960476bd4eb6474f32f02 to your computer and use it in GitHub Desktop.
Nginx Settings for Zabbix server
server {
root /usr/share/zabbix;
server_name my-monitoring.example.com;
location / {
index index.html index.htm index.php;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
auth_basic "Restricted Access";
auth_basic_user_file /etc/nginx/.kibana-user;
location ~ \.php$ {
fastcgi_index index.php;
include fastcgi.conf;
#include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php7.2-fpm.sock; #This might depend on php-fpm version you are running
fastcgi_param SCRIPT_FILENAME /usr/share/zabbix/$fastcgi_script_name; #Use the file provided by Zabbix
#include fastcgi_params;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment