docker / docker/cli

Stack rollback on failure

Open
#595 3 comments 7 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area/stack area/swarm kind/feature
Dominant language
Go
Stars
6.1k
Forks
2.2k
Avg merge
1d 15h
Merged PRs (30d)
43

Description

Stack updates should support rollback of the entire stack in cases where some of the service update fails.

Currently the docker stack deploy command offers the ability to automatically rollback failing service via the deploy -> update_config -> failure_action configuration but the rollback action is applied on a service by service basis.

If only some of the services fails during an update the above behaviour will rollback the failing services but update the healthy ones leaving the stack in an inconsistent state.

Furthermore the stack update is done non-interactively meaning that the only way to detect inconsistent state after an update is to actively monitor the state of all services in the stack and try to reconcile it with their respective desired state.

Moved from moby/moby#34712

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the docker stack deploy implementation and the update_config failure_action handling described in the issue. Trace how service updates report failures and how the command determines desired state. Done means a failed update rolls back the entire stack rather than leaving healthy services updated and the stack inconsistent.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, go
Domain
cli, devops
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.