pid /tmp/nginx.pid; error_log /tmp/nginx-error.log info; daemon off; http {
include /etc/nginx/mime.types; access_log /tmp/nginx.log; server { listen 8890; server_name localhost; # These two location blocks are the interesting part of the config file: location /media { root /media/www; try_files $uri @media; } location @media { proxy_pass http://localhost:8891; proxy_set_header Host $http_host; } } # I have no idea why *all* of this is required: client_body_temp_path /tmp; proxy_temp_path /tmp; fastcgi_temp_path /tmp; uwsgi_temp_path /tmp; scgi_temp_path /tmp;
} events {
worker_connections 1024;
}