Skip to content

πŸ› fix(triggers): prevent compose update from destroying container on failure (#391)#407

Merged
s-b-e-n-s-o-n merged 2 commits into
mainfrom
release/v1.5.0-rc.29
May 31, 2026
Merged

πŸ› fix(triggers): prevent compose update from destroying container on failure (#391)#407
s-b-e-n-s-o-n merged 2 commits into
mainfrom
release/v1.5.0-rc.29

Conversation

@s-b-e-n-s-o-n
Copy link
Copy Markdown
Contributor

Summary

v1.5.0-rc.29 prep. Bundles the #391 data-loss fix with the changelog/doc finalization from this release-prep pass.

πŸ› Fix β€” #391: failed compose update no longer destroys the container

refreshComposeServiceWithDockerApi removed the old container before recreating it, so any failure of the create step (e.g. the pulled image isn't available for the host platform β€” the reporter's arm/v6-vs-amd64 case) left the service with zero containers and no recovery.

  • Pre-flight host-architecture check on the pulled image β€” aborts before stop/remove if incompatible, leaving the running container untouched.
  • Rollback safety net β€” captures the old container's spec before removal; if recreate still fails, restores the original and re-throws the original error.
  • 10 [#391] regression tests, 100% coverage on Dockercompose.ts, tsc clean.

πŸ“ Release prep (commit af81002f)

Test plan

  • npx vitest run triggers/providers/dockercompose β†’ 570 pass, 100% coverage on changed file
  • tsc --noEmit clean
  • Full CI Verify + E2E green (this PR)

Fixes #391

…oc links

- πŸ“ Fold [Unreleased] + all rc.1–rc.28 sections into a single cumulative
  `## [1.5.0] β€” 2026-05-30` entry so release-cut emits complete notes;
  add the previously-undocumented #402 auth `/health` readiness fix and
  drop orphaned [Unreleased]/[1.5.0-rc.*] compare-link defs
- πŸ› Fix broken deep-link in actions docs β†’ triggers#environment-variable-prefixes
- πŸ› Fix broken deep-link in watchers docs β†’ deprecations#legacy-trigger-labels
- πŸ“ Clarify migration-CLI callout: messaging providers may rename to
  DD_NOTIFICATION_* manually (CLI emits DD_ACTION_* for all types)
…failure (#391)

refreshComposeServiceWithDockerApi removed the old container before
recreating it, so a failed create (e.g. pulled image not available for
the host platform) left the service with zero containers and no recovery.

- πŸ› Add pre-flight host-architecture compatibility check on the pulled
  image; abort before stop/remove if incompatible (the #391 arch-mismatch
  vector) so the running container is untouched
- πŸ› Wrap stop/remove β†’ recreate so a recreate failure restores the
  original container from its captured spec, then re-throws the error
- πŸ§ͺ Add 10 [#391] regression tests; 100% coverage on Dockercompose.ts
- πŸ“ CHANGELOG: revert premature [1.5.0] promotion back to [Unreleased]
  (cutting rc.29, not final) and add the #391 Fixed entry

Fixes: #391
@vercel
Copy link
Copy Markdown

vercel Bot commented May 31, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
drydock-demo Ready Ready Preview, Comment May 31, 2026 1:50am
drydock-website Ready Ready Preview, Comment May 31, 2026 1:50am

@codecov
Copy link
Copy Markdown

codecov Bot commented May 31, 2026

Codecov Report

βœ… All modified and coverable lines are covered by tests.

πŸ“’ Thoughts on this report? Let us know!

Copy link
Copy Markdown
Member

@biggest-littlest biggest-littlest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the #391 compose rollback fix (pre-flight arch check + spec-snapshot restore) and the 10 regression tests β€” logic is sound, CI Verify + E2E green. Approving for v1.5.0-rc.29.

Copy link
Copy Markdown
Member

@ALARGECOMPANY ALARGECOMPANY left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed: rollback path restores the original container on recreate failure and the arch pre-flight aborts before any destructive step. Tests cover both. LGTM for rc.29.

@s-b-e-n-s-o-n s-b-e-n-s-o-n merged commit ed558e6 into main May 31, 2026
41 of 54 checks passed
@s-b-e-n-s-o-n s-b-e-n-s-o-n deleted the release/v1.5.0-rc.29 branch May 31, 2026 02:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

failed Container update leads to removed container

3 participants