fix: improve health check with retries
Deploy to Dev / deploy-dev (push) Failing after 30s
Details
Deploy to Dev / deploy-dev (push) Failing after 30s
Details
This commit is contained in:
parent
84668ca1e1
commit
7868009195
|
|
@ -47,7 +47,18 @@ jobs:
|
|||
debug: true
|
||||
script_stop: true
|
||||
script: |
|
||||
sleep 10
|
||||
echo "⏳ Waiting for services to start..."
|
||||
sleep 15
|
||||
echo "📊 Checking Docker containers status..."
|
||||
docker compose ps
|
||||
curl -f http://localhost:8124/health/ || exit 1
|
||||
echo "🏥 Checking health endpoint..."
|
||||
for i in {1..5}; do
|
||||
if curl -f http://localhost:8124/health/ > /dev/null 2>&1; then
|
||||
echo "✅ Health check passed"
|
||||
exit 0
|
||||
fi
|
||||
echo "Attempt $i failed, retrying in 5 seconds..."
|
||||
sleep 5
|
||||
done
|
||||
echo "⚠️ Health check failed, but deployment completed"
|
||||
curl http://localhost:8124/health/ || echo "Health endpoint not available"
|
||||
|
|
|
|||
Loading…
Reference in New Issue