From 24b3f53f7ca3ff94d6e5741ccdd17c6b4365b77c Mon Sep 17 00:00:00 2001 From: jessikitty Date: Tue, 27 Jan 2026 22:32:32 +1100 Subject: [PATCH] Add Phase 2 deployment script --- deploy_phase2.sh | 61 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 deploy_phase2.sh diff --git a/deploy_phase2.sh b/deploy_phase2.sh new file mode 100644 index 0000000..1df21d6 --- /dev/null +++ b/deploy_phase2.sh @@ -0,0 +1,61 @@ +#!/bin/bash +set -e + +echo "🚀 Deploying Phase 2: Chore Management System" +echo "==============================================" +echo "" + +echo "📥 Step 1: Pulling latest changes..." +git pull origin main +echo "✅ Changes pulled" +echo "" + +echo "🛑 Step 2: Stopping existing containers..." +docker-compose down +echo "✅ Containers stopped" +echo "" + +echo "🔨 Step 3: Rebuilding containers (this may take a few minutes)..." +docker-compose build --no-cache +echo "✅ Containers rebuilt" +echo "" + +echo "🚀 Step 4: Starting services..." +docker-compose up -d +echo "✅ Services started" +echo "" + +echo "⏳ Step 5: Waiting for services to initialize (15 seconds)..." +sleep 15 +echo "" + +echo "🔍 Step 6: Checking service health..." +echo "" +echo "Backend Health:" +curl -s http://localhost:8001/health | jq . || echo "Backend not responding yet" +echo "" +echo "Frontend Status:" +curl -s http://localhost:5173 > /dev/null && echo "✅ Frontend is responding" || echo "❌ Frontend not responding yet" +echo "" + +echo "📊 Step 7: Checking running containers..." +docker-compose ps +echo "" + +echo "==============================================" +echo "🎉 Deployment Complete!" +echo "==============================================" +echo "" +echo "📱 Access your Family Hub:" +echo " Frontend: http://localhost:5173" +echo " Backend API: http://localhost:8001" +echo " API Docs: http://localhost:8001/docs" +echo "" +echo "🔑 Login with:" +echo " Username: jess" +echo " Password: password123" +echo "" +echo "📖 See PHASE2_README.md for full documentation" +echo "" +echo "💡 Tip: If login doesn't work immediately, wait another minute" +echo " for the backend to fully initialize, then refresh the page."