mirror of
https://github.com/R0m1k3/Regisflow.git
synced 2026-10-13 10:16:44 +02:00
Resolve Docker issues preventing the application from starting correctly
Fixes "docker-entrypoint.sh not found" and improves Dockerfile for proper entrypoint execution and adds docker-test-quick.sh. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 4b008663-bd72-492b-b0b6-fa252367e730 Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/0715008c-7244-40f4-befc-26c014852236/4b008663-bd72-492b-b0b6-fa252367e730/DWp0Qa4
This commit is contained in:
1 parent
55e4952e74
commit
dbcef0133a
4 files changed
+166
-9
No files matched your search
Executable
+63
@@ -0,0 +1,63 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
echo "🐳 RegisFlow Docker Quick Test"
|
||||
echo "=============================="
|
||||
|
||||
# Nettoyer les anciens containers
|
||||
echo "🧹 Cleaning up existing containers..."
|
||||
docker-compose down -v 2>/dev/null || true
|
||||
docker system prune -f >/dev/null 2>&1 || true
|
||||
|
||||
# Test de build
|
||||
echo "🔨 Building fresh Docker image..."
|
||||
if docker-compose build --no-cache regisflow; then
|
||||
echo "✅ Build successful"
|
||||
else
|
||||
echo "❌ Build failed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Créer .env.production si nécessaire
|
||||
if [[ ! -f ".env.production" ]]; then
|
||||
echo "📝 Creating .env.production from example..."
|
||||
cp .env.production.example .env.production
|
||||
fi
|
||||
|
||||
# Test de démarrage
|
||||
echo "🚀 Starting containers..."
|
||||
if docker-compose up -d; then
|
||||
echo "✅ Containers started"
|
||||
|
||||
# Attendre l'application
|
||||
echo "⏳ Waiting for application..."
|
||||
for i in {1..30}; do
|
||||
if curl -s http://localhost:5000/health >/dev/null 2>&1; then
|
||||
echo "✅ Application is responding!"
|
||||
echo "🏥 Health: $(curl -s http://localhost:5000/health | grep -o '"status":"[^"]*"' || echo 'OK')"
|
||||
break
|
||||
fi
|
||||
echo " Attempt $i/30..."
|
||||
sleep 2
|
||||
done
|
||||
|
||||
if [ $i -eq 30 ]; then
|
||||
echo "❌ Application timeout"
|
||||
echo "📋 Recent logs:"
|
||||
docker-compose logs --tail=10 regisflow
|
||||
exit 1
|
||||
fi
|
||||
|
||||
else
|
||||
echo "❌ Container startup failed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo ""
|
||||
echo "🎉 SUCCESS! RegisFlow is running"
|
||||
echo "================================"
|
||||
echo "Access: http://localhost:5000"
|
||||
echo "Admin: admin / admin123"
|
||||
echo ""
|
||||
echo "To stop: docker-compose down"
|
||||
echo "To see logs: docker-compose logs -f"
|
||||
Reference in new issue
Block a user