From 5c1a0fc09634ba7693dbd137307aeaa76f1c35b9 Mon Sep 17 00:00:00 2001 From: Andrew Godwin Date: Sun, 20 Mar 2016 18:34:30 -0700 Subject: [PATCH] Update default redis url for test project --- testproject/Dockerfile | 1 + testproject/testproject/settings.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/testproject/Dockerfile b/testproject/Dockerfile index 1381225..721f12f 100644 --- a/testproject/Dockerfile +++ b/testproject/Dockerfile @@ -22,5 +22,6 @@ RUN git clone https://github.com/andrewgodwin/channels.git /srv/channels/ && \ python setup.py install WORKDIR /srv/channels/testproject/ +ENV REDIS_URL=redis://redis:6379 EXPOSE 80 diff --git a/testproject/testproject/settings.py b/testproject/testproject/settings.py index 741508c..d14a41f 100644 --- a/testproject/testproject/settings.py +++ b/testproject/testproject/settings.py @@ -32,7 +32,7 @@ CHANNEL_LAYERS = { "BACKEND": "asgi_redis.RedisChannelLayer", "ROUTING": "testproject.urls.channel_routing", "CONFIG": { - "hosts": [os.environ.get('REDIS_URL', 'redis://redis:6379')], + "hosts": [os.environ.get('REDIS_URL', 'redis://127.0.0.1:6379')], } }, }