fix(deployment): correct Redis health check command and add authentication

Previous health check used incorrect command: redis-cli --raw incr ping
This increments a counter instead of checking Redis health.

Changed to proper health check:
- Use standard redis-cli ping command
- Authenticate with password from Docker Secret
- Verify PONG response with grep

This is the ninth cumulative fix for production deployment pipeline.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-11-04 17:01:47 +01:00
parent 41882dafe6
commit 477fe6767e

View File

@@ -209,7 +209,7 @@ services:
# Stricter health checks # Stricter health checks
healthcheck: healthcheck:
test: ["CMD", "redis-cli", "--raw", "incr", "ping"] test: ["CMD", "sh", "-c", "redis-cli -a $$(cat /run/secrets/redis_password 2>/dev/null || echo '') ping | grep -q PONG"]
interval: 10s interval: 10s
timeout: 3s timeout: 3s
retries: 5 retries: 5