Import L1 (celery) as l1/
This commit is contained in:
12
l1/check_redis.py
Normal file
12
l1/check_redis.py
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Check Redis connectivity."""
|
||||
|
||||
import redis
|
||||
|
||||
try:
|
||||
r = redis.Redis(host='localhost', port=6379, db=0)
|
||||
r.ping()
|
||||
print("Redis: OK")
|
||||
except redis.ConnectionError:
|
||||
print("Redis: Not running")
|
||||
print("Start with: sudo systemctl start redis-server")
|
||||
Reference in New Issue
Block a user