Spaces:
Running

microfunnel-api / check-deployment.sh
MicroFunnel
Production-ready: Refactored codebase with Railway + Vercel config
cd61bf7
Raw History Blame Contribute Delete
1.55 kB
#!/bin/bash
# Pre-deployment checklist
echo "πŸ” Checking deployment readiness..."
echo ""
# Check if git initialized
if [ ! -d ".git" ]; then
echo "❌ Git not initialized. Run: git init"
exit 1
fi
echo "βœ… Git initialized"
# Check critical files exist
files=(
"backend/railway.json"
"backend/Procfile"
"backend/.env.railway.template"
"frontend/vercel.json"
"frontend/.env.vercel.template"
"DEPLOYMENT.md"
)
for file in "${files[@]}"; do
if [ ! -f "$file" ]; then
echo "❌ Missing: $file"
exit 1
fi
done
echo "βœ… All deployment configs present"
# Check .gitignore
if [ ! -f ".gitignore" ]; then
echo "❌ Missing .gitignore"
exit 1
fi
echo "βœ… .gitignore exists"
# Check if .env files are gitignored
if git check-ignore backend/.env >/dev/null 2>&1; then
echo "βœ… .env files properly ignored"
else
echo "⚠️ WARNING: .env files not ignored! Add to .gitignore"
fi
# Check backend dependencies
if [ ! -f "backend/requirements.txt" ]; then
echo "❌ Missing backend/requirements.txt"
exit 1
fi
echo "βœ… Backend dependencies defined"
# Check frontend dependencies
if [ ! -f "frontend/package.json" ]; then
echo "❌ Missing frontend/package.json"
exit 1
fi
echo "βœ… Frontend dependencies defined"
echo ""
echo "πŸŽ‰ Ready for deployment!"
echo ""
echo "Next steps:"
echo "1. Push to GitHub: git push origin main"
echo "2. Deploy backend to Railway"
echo "3. Deploy frontend to Vercel"
echo "4. Read DEPLOYMENT.md for detailed instructions"