Add $scheme forwarding to example nginx configuration

Adding `X-Forwarded-Proto` makes bottle pick up on the original request's scheme (https/http), so that the URL on the welcome page is displayed correctly.
This commit is contained in:
Cristi Vîjdea 2017-11-25 01:26:43 +01:00 committed by GitHub
parent 56fe8f3a26
commit 5241ded111
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -671,6 +671,7 @@ Extend your nginx configuration::
location / {
proxy_set_header Host $host:$server_port;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://pypi;
}