Skip to content

Commit 4c553cb

Browse files
author
James (ODSC)
authored
Merge pull request #408 from codeforIATI/configure-redis
Add env var to configure Redis URL
2 parents 760f853 + b300055 commit 4c553cb

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

iati_datastore/iatilib/config.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ class Config:
99
# Handle database disconnect error
1010
# https://stackoverflow.com/questions/55457069/how-to-fix-operationalerror-psycopg2-operationalerror-server-closed-the-conn
1111
SQLALCHEMY_ENGINE_OPTIONS = {"pool_pre_ping": True}
12+
RQ_REDIS_URL = os.environ.get(
13+
'IATI_DATASTORE_REDIS_URL', 'redis://localhost:6379/0')
1214

1315
# Due to a nasty OSX bug, we have to prevent checking system for proxies...
1416
# https://wefearchange.org/2018/11/forkmacos.rst.html

0 commit comments

Comments
 (0)