aboutsummaryrefslogtreecommitdiffstats
path: root/config.py
diff options
context:
space:
mode:
authorGravatar Christopher Baklid <[email protected]>2018-05-25 14:21:10 +0200
committerGravatar Christopher Baklid <[email protected]>2018-05-25 14:21:10 +0200
commit85dbc20a80a2b4c233708be1460da7909e205388 (patch)
tree36d98fca1d490ffe4af0b07defe979389fbe5390 /config.py
parentgenerate new queue based on session id to lock user to their own event chain (diff)
lint
Diffstat (limited to 'config.py')
-rw-r--r--config.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/config.py b/config.py
index cb428fe..f6ae0f7 100644
--- a/config.py
+++ b/config.py
@@ -1,5 +1,6 @@
import os
+
def attempt_automatically_finding_the_ip_of_rmq():
try:
import docker
@@ -7,9 +8,10 @@ def attempt_automatically_finding_the_ip_of_rmq():
containers = client.containers.get('snekbox_pdrmq_1')
HOST = list(containers.attrs.get('NetworkSettings').get('Networks').values())[0]['IPAddress']
return HOST
- except:
+ except Exception:
return '172.17.0.2'
+
USERNAME = 'guest'
PASSWORD = 'guest'
HOST = os.environ.get('RMQ_HOST', attempt_automatically_finding_the_ip_of_rmq())