Update app.py
Browse files
app.py
CHANGED
@@ -11,7 +11,7 @@ SENTINELS = [('sentinel1', 26379), ('sentinel2', 26379), ('sentinel3', 26379)]
|
|
11 |
MASTER_NAME = 'mymaster'
|
12 |
PASSWORD = 'yourpassword'
|
13 |
|
14 |
-
sentinel = Sentinel(SENTINELS, socket_timeout=0.1,
|
15 |
redis_master = sentinel.master_for(MASTER_NAME, socket_timeout=0.1, decode_responses=True)
|
16 |
redis_slave = sentinel.slave_for(MASTER_NAME, socket_timeout=0.1, decode_responses=True)
|
17 |
|
|
|
11 |
MASTER_NAME = 'mymaster'
|
12 |
PASSWORD = 'yourpassword'
|
13 |
|
14 |
+
sentinel = Sentinel(SENTINELS, socket_timeout=0.1, password='yourpassword')
|
15 |
redis_master = sentinel.master_for(MASTER_NAME, socket_timeout=0.1, decode_responses=True)
|
16 |
redis_slave = sentinel.slave_for(MASTER_NAME, socket_timeout=0.1, decode_responses=True)
|
17 |
|