mirror of https://github.com/django/django.git
Fixed #26037 -- Documented precedence of USE_X_FORWARDED_HOST/PORT settings.
This commit is contained in:
parent
a872194802
commit
5cda4677b3
|
@ -2519,10 +2519,14 @@ See also :setting:`TIME_ZONE`, :setting:`USE_I18N` and :setting:`USE_L10N`.
|
|||
|
||||
Default: ``False``
|
||||
|
||||
A boolean that specifies whether to use the X-Forwarded-Host header in
|
||||
preference to the Host header. This should only be enabled if a proxy
|
||||
A boolean that specifies whether to use the ``X-Forwarded-Host`` header in
|
||||
preference to the ``Host`` header. This should only be enabled if a proxy
|
||||
which sets this header is in use.
|
||||
|
||||
This setting takes priority over :setting:`USE_X_FORWARDED_PORT`. Per
|
||||
:rfc:`7239#page-7`, the ``X-Forwarded-Host`` header can include the port
|
||||
number, in which case you shouldn't use :setting:`USE_X_FORWARDED_PORT`.
|
||||
|
||||
.. setting:: USE_X_FORWARDED_PORT
|
||||
|
||||
``USE_X_FORWARDED_PORT``
|
||||
|
@ -2532,10 +2536,12 @@ which sets this header is in use.
|
|||
|
||||
Default: ``False``
|
||||
|
||||
A boolean that specifies whether to use the X-Forwarded-Port header in
|
||||
A boolean that specifies whether to use the ``X-Forwarded-Port`` header in
|
||||
preference to the ``SERVER_PORT`` ``META`` variable. This should only be
|
||||
enabled if a proxy which sets this header is in use.
|
||||
|
||||
:setting:`USE_X_FORWARDED_HOST` takes priority over this setting.
|
||||
|
||||
.. setting:: WSGI_APPLICATION
|
||||
|
||||
``WSGI_APPLICATION``
|
||||
|
|
Loading…
Reference in New Issue