mirror of
https://github.com/Patiun/com.gregkilmer.www.git
synced 2026-11-07 19:58:24 +00:00
Deploy: never remove containers outside the stack
deploy.sh ran `docker compose up --remove-orphans` under the project name gregkilmer. Any other container in a project of the same name, such as the old site's when its compose file sits in a folder called gregkilmer, counted as an orphan and was removed. The stack's own services are all defined in compose.yaml, so the flag isn't needed. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012aSbo2D1qP8cMFQCykf7kx
This commit is contained in:
+3
-1
@@ -39,7 +39,9 @@ cp deploy/compose.yaml "$STACK/compose.yaml"
|
|||||||
set_setting GK_TAG "$TAG"
|
set_setting GK_TAG "$TAG"
|
||||||
[ -n "$CURRENT" ] && set_setting GK_PREVIOUS_TAG "$CURRENT"
|
[ -n "$CURRENT" ] && set_setting GK_PREVIOUS_TAG "$CURRENT"
|
||||||
|
|
||||||
if ! compose up -d --remove-orphans --wait --wait-timeout 120; then
|
# No --remove-orphans: another stack may share the project name, and its
|
||||||
|
# containers must never be touched by this deploy.
|
||||||
|
if ! compose up -d --wait --wait-timeout 120; then
|
||||||
echo "!! $TAG did not come up healthy"
|
echo "!! $TAG did not come up healthy"
|
||||||
compose ps
|
compose ps
|
||||||
compose logs --tail 50 || true
|
compose logs --tail 50 || true
|
||||||
|
|||||||
Reference in New Issue
Block a user