replaced deprecated sample code in proxy-setup docs

This commit is contained in:
Tom-McDonald 2019-04-07 12:48:58 +01:00 committed by David Lord
parent bbedd64540
commit 994cd1db33
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8

View file

@ -124,8 +124,8 @@ If your httpd is not providing these headers, the most common setup invokes the
host being set from ``X-Forwarded-Host`` and the remote address from
``X-Forwarded-For``::
from werkzeug.contrib.fixers import ProxyFix
app.wsgi_app = ProxyFix(app.wsgi_app)
from werkzeug.middleware.proxy_fix import ProxyFix
app.wsgi_app = ProxyFix(app.wsgi_app, x_proto=1, x_host=1)
.. admonition:: Trusting Headers