Merge pull request 'fix: stop old containers before compose up in production deploy' (#65) from dev into main
Deploy Dashboard (Main) / Backend Tests (push) Successful in 21m50s
Deploy Dashboard (Main) / Frontend Tests (push) Successful in 59s
Deploy Dashboard (Main) / Deploy to Production (push) Failing after 4m26s

This commit was merged in pull request #65.
This commit is contained in:
2026-05-18 00:07:43 +08:00
+5
View File
@@ -244,6 +244,11 @@ jobs:
set -e set -e
export DOCKER_API_VERSION=1.43 export DOCKER_API_VERSION=1.43
# Stop and remove old containers to force recreate with new image.
# External networks (gitea_gitea, nas-dashboard_internal) are preserved.
docker compose -f /nas-dashboard/docker-compose.yml down 2>/dev/null || true
echo "Old containers stopped"
# Docker 24 compose fails when it can't connect external networks # Docker 24 compose fails when it can't connect external networks
# during container creation. Try compose first; if the container # during container creation. Try compose first; if the container
# isn't created, strip networks from compose file and retry. # isn't created, strip networks from compose file and retry.