Skip to content

Instantly share code, notes, and snippets.

@osule
Last active October 3, 2017 12:24
Show Gist options
  • Save osule/29145019b77b81c7a1be0ebbc74dd896 to your computer and use it in GitHub Desktop.
Save osule/29145019b77b81c7a1be0ebbc74dd896 to your computer and use it in GitHub Desktop.
nginx/canvas
upstream web-app {
server canvas-web:9000;
}
server {
listen 80 default_server;
server_name _;
root /var/www/html/canvas/public;
index index.php index.html index.htm index.nginx-debian.html;
server_name canvas;
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass web-app;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment