diff options
Diffstat (limited to 'install/nginx.conf.template')
-rw-r--r-- | install/nginx.conf.template | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/install/nginx.conf.template b/install/nginx.conf.template new file mode 100644 index 000000000..0a68be712 --- /dev/null +++ b/install/nginx.conf.template @@ -0,0 +1,34 @@ +server { + listen #NGINX_PORT#; + server_name #URL#; + root /srv/#DB_NAME#/ishtar/; + access_log /var/log/django/#SHORT_NAME#-access.log; + error_log /var/log/django/#SHORT_NAME#-error.log; + client_max_body_size 20M; + + location /static-#DATE#/ { # STATIC_URL + alias /srv/#DB_NAME#/ishtar/#SHORT_NAME#/static/; # STATIC_ROOT + expires 30d; + } + + location /media/ { # MEDIA_URL + alias /srv/#DB_NAME#/ishtar/#SHORT_NAME#/media/; # MEDIA_ROOT + expires 30d; + } + + location /tinymce/ { + alias /usr/share/tinymce/www/; + expires 30d; + } + + location /javascript/ { + alias /usr/share/javascript/; + expires 30d; + } + + location / { + include uwsgi_params; + uwsgi_pass 127.0.0.1:#UWSGI_PORT#; + } +} + |