Browse Source

Fix config; Add redis to drone

Dashie der otter 3 months ago
parent
commit
5344453b04
3 changed files with 7 additions and 3 deletions
  1. 2
    0
      .drone.yml
  2. 2
    3
      config.py.sample
  3. 3
    0
      tests/config_test.py

+ 2
- 0
.drone.yml View File

@@ -85,3 +85,5 @@ services:
85 85
     environment:
86 86
       - POSTGRES_USER=postgres
87 87
       - POSTGRES_DB=reel2bits_test
88
+  redis:
89
+    image: redis

+ 2
- 3
config.py.sample View File

@@ -14,9 +14,8 @@ SENTRY_USER_ATTRS = ['name', 'email']
14 14
 SENTRY_DSN = ""
15 15
 
16 16
 # Redis configuration for broker, used for async background tasks
17
-BROKER_REDIS_HOST = "127.0.0.1"
18
-BROKER_REDIS_PORT = 6379
19
-BROKER_REDIS_DB = 0
17
+CELERY_BROKER_URL = "redis://127.0.0.1:6379/0"
18
+CELERY_RESULT_BACKEND = "redis://127.0.0.1:6379/0"
20 19
 
21 20
 # They needs to be identical
22 21
 # You can't change them after setup !

+ 3
- 0
tests/config_test.py View File

@@ -34,6 +34,9 @@ DEBUG_TB_PROFILER_ENABLED = False
34 34
 DEBUG_TB_INTERCEPT_REDIRECTS = False
35 35
 DEBUG_TB_ENABLED = False
36 36
 
37
+CELERY_BROKER_URL = "redis://redis:6379/0"
38
+CELERY_RESULT_BACKEND = "redis://redis:6379/0"
39
+
37 40
 BABEL_DEFAULT_LOCALE = "en"
38 41
 BABEL_DEFAULT_TIMEZONE = "UTC"
39 42
 

Loading…
Cancel
Save