disable kubectl port forwarding and instead rely on a docker contaier for redis

This commit is contained in:
Viktor Barzin 2025-06-22 21:33:02 +00:00
parent 9a164ddfdc
commit 68d88de464
No known key found for this signature in database
GPG key ID: 4056458DBDBF8863

View file

@ -14,13 +14,15 @@ pkill -f celery
pkill watchmedo
set -e
if command -v kubectl &> /dev/null; then
set +e
pkill -f "kubectl port-forward"
set -e
# use redis container instead to avoid overwriting prod
# if command -v kubectl &> /dev/null; then
# set +e
# pkill -f "kubectl port-forward"
# set -e
kubectl port-forward $(kubectl get pods -n redis -o json | jq '.items[0].metadata.name' | sed 's/"//g') --address 0.0.0.0 6379:6379 -n redis &
fi
# # kubectl port-forward $(kubectl get pods -n redis -o json | jq '.items[0].metadata.name' | sed 's/"//g') --address 0.0.0.0 6379:6379 -n redis &
# fi
# Ensure connection to broken is successful
python celery_app.py