'Initial checkin'
[webvac] / doc / nginx.example.conf
1 pid             /tmp/nginx.pid;
2 error_log       /tmp/nginx-error.log info;
3 daemon off;
4 http {
5         include /etc/nginx/mime.types;
6         access_log  /tmp/nginx.log;
7         server {
8                 listen   8890;
9                 server_name  localhost;
10
11                 # These two location blocks are the interesting part of the config file:
12                 location /media {
13                         root /media/www;
14                         try_files $uri @media;
15                 }
16                 location @media {
17                         proxy_pass http://localhost:8891;
18                         proxy_set_header Host $http_host;
19                 }
20         }
21
22         # I have no idea why *all* of this is required:
23         client_body_temp_path   /tmp;
24         proxy_temp_path /tmp;
25         fastcgi_temp_path       /tmp;
26         uwsgi_temp_path /tmp;
27         scgi_temp_path  /tmp;
28 }
29 events {
30         worker_connections      1024;
31 }