Skip to content

Instantly share code, notes, and snippets.

@Ziaunys
Created April 22, 2015 23:41
Show Gist options
  • Save Ziaunys/cc364aa3bed01385c110 to your computer and use it in GitHub Desktop.
Save Ziaunys/cc364aa3bed01385c110 to your computer and use it in GitHub Desktop.
icingaweb2 nginx config example
server {
listen *:80;
root /usr/share/icingaweb2/public;
access_log /var/log/nginx/ssl-icingaweb2_app.access.log;
error_log /var/log/nginx/ssl-icingaweb2_app.error.log;
location ~ ^/icingaweb2(.+)? {
alias /usr/share/icingaweb2/public;
index index.php
try_files $1 $uri $uri/ /icingaweb2/index.php$is_args$args;
}
location ~ ^/icingaweb2/index\.php(.*)$ {
fastcgi_index index.php;
include /etc/nginx/fastcgi_params;
fastcgi_pass unix:/var/run/php5-fpm-icingaweb2.sock;
fastcgi_param SCRIPT_FILENAME /usr/share/icingaweb2/public/index.php;
fastcgi_param ICINGAWEB_CONFIGDIR /etc/icingaweb2;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment