Skip to content

Instantly share code, notes, and snippets.

@oc
Last active August 29, 2015 13:56
Show Gist options
  • Save oc/9093393 to your computer and use it in GitHub Desktop.
Save oc/9093393 to your computer and use it in GitHub Desktop.
upstream ze-backend {
server backend.server.local:7500 fail_timeout=0;
}
location /stuff-proxied-to-backend {
# Tried this
max_ranges 0;
try_files $uri @ze-backend;
}
location @ze-backend {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
# And tried this (and both)
proxy_pass_request_body off;
proxy_set_header Content-Length 0;
max_ranges 0;
proxy_pass http://ze-backend;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment