Skip to content

Commit 43b7eff

Browse files
committed
fix: stop old containers on port 8000 before starting new stack
1 parent bf3b167 commit 43b7eff

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/cd.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,11 @@ jobs:
3535
echo "🏗️ Building containers..."
3636
docker compose build
3737
38-
echo "🔄 Restarting stack..."
39-
docker compose down
38+
echo "� Stopping old containers..."
39+
docker ps -q --filter "publish=8000" | xargs -r docker stop | xargs -r docker rm
40+
docker compose down 2>/dev/null || true
41+
42+
echo "🔄 Starting new stack..."
4043
docker compose up -d
4144
4245
echo "⏳ Waiting for health checks..."

0 commit comments

Comments
 (0)