diff options
author | Piotr Dobrowolski <admin@tastycode.pl> | 2018-01-26 20:07:28 +0100 |
---|---|---|
committer | Piotr Dobrowolski <admin@tastycode.pl> | 2018-01-26 20:07:28 +0100 |
commit | 8d0e1d1c4166b0a42695582bb222cea590ad8784 (patch) | |
tree | 75e8bd82db0eda88f0841e4ee06aaed0bc0bc7b5 | |
parent | a3ea78f801a4c0e637c162b69e1f00428e86f67d (diff) | |
download | checkinator-8d0e1d1c4166b0a42695582bb222cea590ad8784.tar.gz checkinator-8d0e1d1c4166b0a42695582bb222cea590ad8784.tar.bz2 checkinator-8d0e1d1c4166b0a42695582bb222cea590ad8784.zip |
Add PROXY_FIX config option to enable werkzeug ProxyFix
-rw-r--r-- | at.cfg.dist | 2 | ||||
-rw-r--r-- | at.py | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/at.cfg.dist b/at.cfg.dist index c37efdf..b2e0720 100644 --- a/at.cfg.dist +++ b/at.cfg.dist @@ -17,3 +17,5 @@ SPECIAL_DEVICES = { } SECRET_KEY = 'adaba' + +PROXY_FIX = False @@ -23,6 +23,10 @@ app.jinja_env.add_extension('jinja2.ext.i18n') app.jinja_env.install_null_translations() app.updater = None +if app.config.get('PROXY_FIX'): + from werkzeug.contrib.fixers import ProxyFix + app.wsgi_app = ProxyFix(app.wsgi_app) + auth = SpaceAuth(app) |