Docker · Arazzo Workflow
Docker Roll a Swarm Service Onto a New Image
Version 1.0.0
Read a service's current version, update it to a new image, watch the tasks reconverge, and tail the service logs.
Provider
Workflows
rolling-update-service
Update a running swarm service to a new image using its current version index.
Inspects the service to obtain its current spec and version index, submits an updated spec pinned to that version so a concurrent write is rejected rather than lost, then lists tasks and tails logs to confirm the rollout.
1
inspectService
Read the service's current spec and version index. The version index is required by the update call — it is what makes the write conditional on nobody else having changed the service in the meantime.
2
updateService
Submit the updated spec pinned to the version index read above, rolling tasks onto the new image start-first so capacity is never dipped below the target during the update.
3
watchRollout
List the service's tasks desired to be running so the caller can watch the new tasks come up and the old ones drain during the rolling update.
4
confirmUpdateState
Read the service back to check the update status the swarm reports. A state of "completed" means the rollout landed; "paused" or "rolling_back" means it tripped the failure action.
5
tailServiceLogs
Tail the aggregated logs across the service's tasks with timestamps, so a failed rollout can be diagnosed without hunting for individual containers.
Source API Descriptions
openapi
Arazzo Workflow Specification
Work with this as data
Every workflow here is available over the APIs.io API and to AI agents over MCP.