Created
February 15, 2012 15:12
-
-
Save fdelbos/1836544 to your computer and use it in GitHub Desktop.
Freebsd Nginx config for Django
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user www; | |
worker_processes 1; | |
error_log /var/log/nginx-error.log; | |
events { | |
worker_connections 256; | |
use kqueue; | |
} | |
http { | |
include mime.types; | |
default_type application/octet-stream; | |
access_log /var/log/nginx-access.log; | |
sendfile on; | |
tcp_nopush on; | |
keepalive_timeout 60; | |
server_tokens off; | |
gzip on; | |
gzip_min_length 1000; | |
gzip_proxied any; | |
server { | |
listen 80; | |
server_name example.com www.example.com; | |
client_max_body_size 10M; | |
location / { | |
uwsgi_pass 127.0.0.1:3031; | |
include uwsgi_params; | |
} | |
location /static/ { | |
autoindex off; | |
root /path/to/django/project/; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment