Smokeping on nginx

编写于

nginx: include next config:

# smokping nginx configuare
# system os: debian 7.0

location /smokeping {
access_log /var/log/nginx/server.smokeping.access.log;
error_log /var/log/nginx/server.smokeping.error.log;

root /var/www;
index smokeping.cgi;

auth_basic “Restricted”;
auth_basic_user_file /var/www/users.htpasswd;

location ~ .cgi$ {
root /var/www;
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:/var/run/fcgiwrap.socket;
fastcgi_index smokeping.cgi;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}


new folder:
mkdir /var/www/smokeping

link file to /var/www/smokeping:
ln -s /usr/share/smokeping/www/* /var/www/smokeping/

create htpasswd file
htpasswod /var/www/users.htpasswd

reload the sevice configure
service nginx reload