From 52eb58f2a9de8d4d968550443a58d1120e6e2a8a Mon Sep 17 00:00:00 2001 From: Rodolphe Breard Date: Mon, 12 Nov 2018 14:35:37 +0100 Subject: [PATCH] Add the KHAGANAT_INTERNAL_IPS setting --- README.md | 1 + khaganat/settings.py | 1 + 2 files changed, 2 insertions(+) diff --git a/README.md b/README.md index ead9e49..99dba2d 100644 --- a/README.md +++ b/README.md @@ -65,6 +65,7 @@ You can set the following variables in the `.env` file: * `KHAGANAT_HTTPS_HEADER_VALUE`: Header value for `SECURE_PROXY_SSL_HEADER`, default is `https`. * `KHAGANAT_NSFW_TAGS`: Coma-separated list of words that triggers the content warning in logs, default is `\#nsfw`. * `KHAGANAT_NSFW_NAME`: Name of the cookie holding the NSFW allowance, default is `nsfw_allowed`. +* `KHAGANAT_INTERNAL_IPS`: List of IP considered as internal, coma separated, default is `127.0.0.1,::1`. ## Quick update diff --git a/khaganat/settings.py b/khaganat/settings.py index dc04293..ef604ca 100644 --- a/khaganat/settings.py +++ b/khaganat/settings.py @@ -30,6 +30,7 @@ SECRET_KEY = config('KHAGANAT_SECRET_KEY') DEBUG = config('KHAGANAT_DEBUG', default=False, cast=bool) ALLOWED_HOSTS = config('KHAGANAT_HOSTNAMES', default='', cast=Csv()) +INTERNAL_IPS = config('KHAGANAT_INTERNAL_IPS', default='127.0.0.1,::1', cast=Csv()) # Application definition