Because links to images generates with /smokeping/, all configs use this path for static files and images.
Very simple, but main page not in /smokeping/, main page is http://smokeping.example.com/cgi-bin/smokeping.cgi
Partialy used content of /etc/nginx/fastcgi_params
, except of SCRIPT_FILENAME
.
Like big.conf
, but with redirect from wrong URLs to main page.
Note: apache2-
argument is using here to force APT to not install apache2
package, which is in recommends list of smokeping
package. It is also possible to use --no-install-recommends
, but then other useful packages will not be installed automatically.
Replace here "smokeping.example.net" by your DNS name:
export MYSITENAME="smokeping.example.net"
sudo apt-get -V install smokeping apache2-
sudo apt-get -V install fcgiwrap nginx
wget 'https://gitlab.com/vazhnov/smokeping_nginx/-/raw/main/best.conf'
sed -i -- s/smokeping\.example\.com/${MYSITENAME}/g best.conf
sudo chown -v root:root best.conf
sudo mv -v best.conf /etc/nginx/sites-available/${MYSITENAME}.conf
sudo ln -v -s "../sites-available/${MYSITENAME}.conf" "/etc/nginx/sites-enabled/${MYSITENAME}.conf"
sudo nginx -t
sudo service nginx reload
Then open an URL http://smokeping.example.net/smokeping/smokeping.cgi in a web-browser.
- Nginx configurations for most popular CMS/CMF/Frameworks based on PHP
- recipes from nginx-wiki
- examples from nginx-wiki
Distributed under MIT license.