server { listen localhost; server_name daapr.localhost; root /home/www-data/daapr; index index.html; location ~ ^/favicon.ico$ { root /home/www-data/roundcube/web/skins/default/images; log_not_found off; access_log off; expires max; } location = /robots.txt { allow all; log_not_found off; access_log off; } # Deny all attempts to access hidden files such as .htaccess, .htpasswd, .DS_Store (Mac). location ~ /(\.|temp|logs) { deny all; access_log off; log_not_found off; } } server { listen 80; server_name daap.localhost; add_header Access-Control-Allow-Origin "*"; location / { proxy_pass http://localhost:3689; proxy_next_upstream error timeout invalid_header http_500 http_502 http_503 http_504; proxy_redirect off; #proxy_buffering off; proxy_buffering on; #proxy_buffers 128k; proxy_cache daap; proxy_cache_valid 6d; proxy_cache_valid 404 1m; proxy_ignore_headers Cache-Control Expires DAAP-Server; #proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } }