mirror of
https://github.com/sissbruecker/linkding
synced 2024-11-10 06:04:15 +00:00
Allow to log real client ip in logs when using a reverse proxy (#398)
* Allow to log real client ip in logs when using a reverse proxy * rearrange options --------- Co-authored-by: Sascha Ißbrücker <sascha.issbruecker@googlemail.com>
This commit is contained in:
parent
d1819c6503
commit
a94eb5f85a
2 changed files with 11 additions and 1 deletions
|
@ -109,6 +109,12 @@ Multiple origins can be specified by separating them with a comma (`,`).
|
||||||
|
|
||||||
This setting is adopted from the Django framework used by linkding, more information on the setting is available in the [Django documentation](https://docs.djangoproject.com/en/4.0/ref/settings/#std-setting-CSRF_TRUSTED_ORIGINS).
|
This setting is adopted from the Django framework used by linkding, more information on the setting is available in the [Django documentation](https://docs.djangoproject.com/en/4.0/ref/settings/#std-setting-CSRF_TRUSTED_ORIGINS).
|
||||||
|
|
||||||
|
### `LD_LOG_X_FORWARDED_FOR`
|
||||||
|
|
||||||
|
Values: `true` or `false` | Default = `false`
|
||||||
|
|
||||||
|
Set uWSGI [log-x-forwarded-for](https://uwsgi-docs.readthedocs.io/en/latest/Options.html?#log-x-forwarded-for) parameter allowing to keep the real IP of clients in logs when using a reverse proxy.
|
||||||
|
|
||||||
### `LD_DB_ENGINE`
|
### `LD_DB_ENGINE`
|
||||||
|
|
||||||
Values: `postgres` or `sqlite` | Default = `sqlite`
|
Values: `postgres` or `sqlite` | Default = `sqlite`
|
||||||
|
|
|
@ -23,3 +23,7 @@ http-timeout = %(_)
|
||||||
socket-timeout = %(_)
|
socket-timeout = %(_)
|
||||||
harakiri = %(_)
|
harakiri = %(_)
|
||||||
endif =
|
endif =
|
||||||
|
|
||||||
|
if-env = LD_LOG_X_FORWARDED_FOR
|
||||||
|
log-x-forwarded-for = %(_)
|
||||||
|
endif =
|
||||||
|
|
Loading…
Reference in a new issue