Skip to content

Instantly share code, notes, and snippets.

@srijan
Created March 4, 2015 20:32
Show Gist options
  • Save srijan/5f3ef70da9f5150d845e to your computer and use it in GitHub Desktop.
Save srijan/5f3ef70da9f5150d845e to your computer and use it in GitHub Desktop.
Nginx conf for uwsgi
upstream myapp {
least_conn;
server unix:///var/run/uwsgi_myapp0.sock;
server unix:///var/run/uwsgi_myapp1.sock;
server unix:///var/run/uwsgi_myapp2.sock;
server unix:///var/run/uwsgi_myapp3.sock;
server unix:///var/run/uwsgi_myapp4.sock;
}
server {
listen 80;
server_name myapp.example.com;
location /static {
alias /usr/local/www/myapp/static;
}
location / {
uwsgi_pass myapp;
include uwsgi_params;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment