deploy: use docker healthcheck

This commit is contained in:
2026-05-15 21:59:06 +04:00
parent 310d5abb8b
commit 66d8ed1e00
2 changed files with 8 additions and 14 deletions
+2 -14
View File
@@ -56,17 +56,5 @@ jobs:
|| docker network create konstitisyon_network
echo "==> Build et démarrage du frontend"
docker compose up -d --build
echo "==> Vérification santé"
for i in $(seq 1 12); do
status=$(curl -s -o /dev/null -w "%{http_code}" http://localhost:4000)
if echo "$status" | grep -qE "^[23]"; then
echo "Déploiement OK (HTTP $status)"
exit 0
fi
echo " Attente... ($i/12) [HTTP $status]"
sleep 5
done
echo "Échec : le frontend ne répond pas après 60s"
exit 1
docker compose up -d --build --wait
echo "Déploiement OK"