iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more
The rollback procedure depends on how the workload is managed. For Docker Compose, restore the previous image reference in compose.yaml (or its environment variable) and run docker compose up -d SERVICE. For Docker Swarm, run docker service rollback SERVICE or docker service update --rollback SERVICE from a manager node. Preserve the exact last-known-good image digest whenever possible; a tag such as latest can point to different image bytes later.
Identify whether the workload uses Compose or Swarm
Do this before changing anything. Compose and Swarm store deployment state differently, so the rollback command for one does not repair the other.
| Question | Docker Compose | Docker Swarm |
|---|---|---|
| Where it runs | Usually one Docker host, described by a Compose file. | A service scheduled across a swarm cluster. |
| How to list the workload | docker compose ps from the project directory. |
docker service ls on a swarm node. |
| Rollback unit | A service container is recreated from the image reference in the Compose configuration. | The service specification is restored to the configuration used before the most recent service update. |
| Primary command | docker compose up -d SERVICE |
docker service rollback SERVICE |
| Where the command must run | A host with the Compose project and Docker access. | A swarm manager for rollback operations. |
| Typical rollout behavior | Compose stops and recreates the changed service. | Swarm can perform a controlled rolling update with parallelism, delay, monitoring, and failure thresholds. |
Recognize a Compose deployment
Look for compose.yaml, compose.yml, or an older docker-compose.yml in the directory used to start the application. Run docker compose ps. The output lists project services and their containers. If the image is supplied through an environment variable, inspect the project’s .env file and any deployment variables before editing the YAML.
The Tool Desk
Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Recognize a Swarm service
Run docker service ls. A result with a replica count such as 3/3 indicates a swarm service rather than an ordinary Compose container. Use docker info --format '{{.Swarm.LocalNodeState}}' to check the local node state. A rollback must be initiated from a manager node; a worker can report task status but cannot perform the service rollback operation.
#1 Best Overall
- Powerful Turbo Fan:CAGIWIRU Electric Air Duster have reached speed up to 130000RPM,Can efficient remove dust and debris.With LED light and Three Adjustable Speed to meet with different cleaning tasks.
- With Attached USB C Fasting Charging cable.Charing 3 hours,Enjoy up to 240 minutes of use on the lowest setting, For third speed can use for 25mins.with four charging options to meet with your needs.
- Wide Application: attached 5 different nozzles,making it suitable for a variety of scenes, such as car,pet, pc, keyboards, and other electronic devices. It also serves for office and home clean duster.
- Handy Design & Portable:Cordless air duster electric nozzle is Light weight and small size, design and comfortable to hold and space saving, convenient to carry around. You can put it in your room or inside the car without taking up space.
- Economical &Reusable: Built durable materials with a long-lasting battery,our CAGIWIRU air duster it's a sustainable alternative to disposable air cans.
Freeze the incident and capture the known-good state
Stop automated deployments first. A second update can overwrite the service history or make it unclear which image caused the failure. Record the service name, current image reference, container or task identifiers, recent logs, health status, and the last-known-good tag or digest in the incident notes.
- Stop further changes. Pause the release pipeline, scheduled deploy job, or configuration automation that might update the service again.
- Record the currently deployed reference. For Compose, inspect the running container with
docker compose ps -q SERVICEfollowed bydocker inspect CONTAINER_ID --format '{{.Config.Image}}'. For Swarm, usedocker service inspect SERVICE --format '{{.Spec.TaskTemplate.ContainerSpec.Image}}'. Keep the complete output, including an@sha256:digest if Docker shows one. - Save evidence. Capture
docker compose logs --since 30m SERVICEfor Compose ordocker service ps SERVICE --no-truncand the relevant service logs for Swarm. Note when the first error appeared and whether the failure is a crash, failed health check, bad response, or data problem. - Find the prior reference. Check the previous release record, image-promotion log, registry metadata, or deployment commit. Do not assume that a version-looking tag still points to the same bytes.
If the old digest is still present on the host, Docker may be able to recreate the service without downloading it. If it is not local, pull that exact digest from the registry before starting the replacement. Verify that the registry still retains it.
Use an immutable image identity for the rollback
Docker describes each tag as representing a digest, similar to a Git hash. A tag is a human-friendly pointer; the digest identifies the image content. Tags such as latest are updated frequently, and even a versioned tag can be moved by a registry owner. Swarm resolves a tag through the registry during a service update and then runs tasks using the resolved digest.
Recommended Free Tools
For recovery, prefer a reference such as:
registry.example/app@sha256:<known-good-digest>
Compose accepts both tag syntax and digest syntax:
registry.example/app:2.8.3
registry.example/app@sha256:<known-good-digest>
Use the digest that actually ran successfully, not merely the tag that was listed in an old deployment file. If only a tag is available, confirm its current digest in the registry and compare it with the digest recorded for the healthy release. A tag that has moved cannot restore the previous bytes by itself.
Roll back a Docker Compose service
1. Restore the image reference
Open the Compose file used for the deployment and change only the affected service’s image reference, unless the incident also requires a configuration change. For example:
services:
api:
image: 'registry.example/app@sha256:<known-good-digest>'
ports:
- '8080:8080'
If the file uses a variable, restore the variable instead:
Rank #2
- Screen Cleaner is Your Screen’s New Bestfriend! - EVEO is proud to present a screen cleaner that’s perfectly suited for your TV. Meet your new screen cleaner, computer screen cleaner, laptop cleaner, iPad cleaner, Macbook,tv cleaner or any other electronic device. Our screen cleaner spray and wipe along with the included plush microfiber cloth, easily removes dust, fingerprints & other smudges on the screen’s surface. Clean effectively for a streak-free screen
- Gentle on your Screens - Our screen cleaner spray and wipes is compatible to be used even for the most sensitive LCD, LED, CRT, and OLED screens in proper use. Be at ease knowing that this product is compatible with all the major brands: LG, SONY, Samsung, Sharp, iPad, iPhone, Android screens, Kindle, PC monitors - we’ve got you covered! Can be used as LCD screen cleaner, tv cleaner, smart tv screen cleaner, and more
- Premium Super Soft Plush Microfiber Cloth - Included in this efficient screen cleaning kit. This screen cleaner spray and wipe has our signature plush microfiber cloth specially designed to comply with screens and monitors and leave them streak-free. Has been shown to effectively absorbs stubborn stains, zero streaks, and no fiber shedding. Always use this together with our screen cleaner for the best results
- Easy-to-Use Screen Cleaner Kit + microfiber cleaning cloth - The EVEO Screen Cleaning Kit will easily be your new favorite tool when it comes to taking care of the things you love most, quick and easy solution for a streak-free screen. Simply screw on the sprayer gun on the screen cleaner bottle. Spray the cleaning liquid onto the microfiber cloth, then wipe the screen until desired cleanliness & shine is achieved.
- Quality Screen Care Kit Worth Purchasing - Enjoy a convenient Screen Cleaner anytime, anywhere you need it. Your satisfaction is our top priority. We stand behind the quality of our products and that’s why, you shouldn’t be worrying at all. We manufacture the Best Screen Cleaner. and can be used for laptop cleaning kit, laptop screen cleaner, tv screen cleaner for smart tv. MacBook screen cleaner, monitor cleaner or screen cleaner spray for electronic devices with microfiber cleaning cloth
services:
api:
image: '${APP_IMAGE}'
APP_IMAGE=registry.example/app@sha256:<known-good-digest>
Keep the service name unchanged. Changing it can create a second service instead of replacing the failed one.
2. Recreate the service
From the directory containing the Compose project, run:
docker compose up -d SERVICE
Docker documents that docker compose up stops and recreates a service when its image or configuration changed. Mounted volumes are preserved by default, so recreating the container does not normally delete named-volume data. Compose may reuse an existing image if the exact digest is already local; otherwise it pulls the specified reference as part of the operation.
If you intentionally need fresh anonymous volumes, Compose provides --renew-anon-volumes. Do not add that option during a routine image rollback unless you have reviewed the volume declarations and accepted the data consequences.
3. Confirm the new container and image
- Check state with
docker compose ps. The service should be running and any health status should become healthy. - Read startup output with
docker compose logs SERVICE. Look for the expected application version, successful dependency connections, and absence of restart loops. - Confirm the image actually used by inspecting the container:
docker inspect CONTAINER_ID --format '{{.Config.Image}}'. - Send a representative request through the same endpoint used by clients. Test a read path and, where safe, a write path that exercises the affected code.
4. Reconnect clients by service name
When Compose recreates a container, Docker can assign it a different IP address. Clients inside the Compose network should connect to the stable service name, such as api:8080, rather than a container IP. Existing connections to the old container can close during replacement, so clients should reconnect with their normal retry policy.
Free tools Windows power users keep installed
One-click scans. No signup required.
Roll back a Docker Swarm service
1. Run the rollback on a manager
After identifying the service and confirming that the previous service specification is the desired one, execute:
Rank #3
- 【Large size】:Measuring 800 x 300 mm/ 31. 5×12 inches, which is wider and taller than others. Large mouse pad can perfectly fit your keyboard and mouse of any size, and there is also ample space for peripherals such as phones, tablets, etc.
- 【LED backlight mouse pad】:Blade Hawks RGB mouse pad provides 7 static modes and 7 dynamic modes will give you the options you are looking for. Power-off memory function remembers the last lighting mode you selected. The super glow fiber Chroma will give you a colorful gaming setup that you want.
- 【Anti-slip rubber base】:Made from Natural rubber, this gaming mousepad will firmly grip your desktop, allowing you to enjoy the ultimate precision in the games you are most passionate about. It also comes with a texture that enhances this ability even further.
- 【Smooth and waterproof surface】: Micro-textured cloth surface, for extremely precise mouse control and a smooth movement. When liquid splashes on the gaming mouse pad, it forms water droplets and slides down. Will not delay your work or gameplay.
- 【Plug and play】: This mouse and keyboard pad is powered by USB, plug and play, no driver required. One button control light modes. Press one time to change the lighting mode, press twice to change the brightness, press and hold about 3 seconds turn ON/OFF.
docker service rollback SERVICE
The equivalent update form is:
docker service update --rollback SERVICE
Docker’s CLI documentation defines this operation as reverting the service to the configuration that was in place before the most recent docker service update command. That means it rolls back one recorded update, not an arbitrary historical release. If several updates occurred after the good release, inspect the service history and redeploy the exact known-good image and settings instead of assuming one rollback reaches the desired state.
2. Watch task replacement
Use these commands while the rollback progresses:
docker service ps SERVICE --no-trunc
docker service inspect SERVICE --pretty
docker service logs SERVICE
Tasks may pass through states such as Preparing, Starting, and Running. A task that repeatedly exits, fails its health check, or is rejected by a node requires investigation before declaring recovery. The service’s desired and running replica counts should converge.
3. Understand Swarm image resolution
When Swarm updates a service from a tag, the manager queries the registry and resolves that tag to a digest. The tasks then use the resolved digest. If the registry tag has moved since the healthy deployment, issuing an update with the same tag may deploy different bytes. Record and deploy the known-good digest whenever possible, for example:
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
docker service update --image registry.example/app@sha256:<known-good-digest> SERVICE
Use an explicit image update only when the rollback history does not contain the desired configuration or when you need to restore a particular older release. An image-only change does not automatically undo database migrations, queue messages, or external configuration changes.
Validate the rollback before closing the incident
A container or task showing “running” is not sufficient proof that the application is recovered. Validate infrastructure state and user-visible behavior separately.
Compose validation checklist
docker compose psshows the expected service state and health result.docker compose logs SERVICEcontains normal startup and no repeating crash or migration errors.- The inspected image reference matches the recorded known-good tag or digest.
- Dependencies such as databases, caches, and queues connect successfully.
- A representative request returns the expected status, response shape, and business result.
- Monitoring shows that error rate, latency, and restart count have returned to the normal baseline for the environment.
Swarm validation checklist
docker service ps SERVICE --no-truncshows the required number of running tasks.docker service inspect SERVICEshows the intended image and update state.- Service logs do not show task rejection, health-check failure, or repeated restarts.
- Requests succeed through the cluster’s published endpoint or load balancer.
- Each replica behaves consistently; one healthy task does not prove that every node is serving the same release.
Keep the failed image reference and logs attached to the incident record. They are useful if the same symptom returns after a later deployment.
Rank #4
- 【Softer and More Comfortable】Vaydeer wrist rest has unique diamond pattern, which is the combination of softness and aesthetics. The materials of wrist rest are improved into higher quality memory foam and covered with silky smooth lycra. The computer wrist rest makes you as comfortable and cushiony as like rest your wrists on clouds.
- 【Ergonomic Wrist Saver】The wrist rests for keyboard and mouse comes with a 17.32×3.15×0.83 inch keyboard wrist pad and a 5.94×3.15×0.83 inch mouse wrist support. Based on ergonomic design, the unique concave shape is the perfect fit for your wrist joints. The wrist rest pad fits most computer keyboards and laptops, improve hand and wrist posture, release your wrist and arm stress.
- 【Non-Slip Rubber Bottom】Featuring an anti-skid silicone base on the bottom, this wrist keyboard support stays firmly in place on your desk, preventing the padding from sliding around, ensuring stable and consistent wrist support during extended computer sessions.
- 【Better Experience & Pain Relief】Our keyboard arm rest is beneficial to alleviate the soreness caused by direct contact and friction between your arm and a hard desk surface, reducing the risk of wrist fatigue or carpal tunnel. The soft texture of memory foam can evenly distribute the pressure around your wrists and provide good support with just enough give.
- 【Helpful in Multiple Scenarios】Whether you're working, studying, writing, typing, gaming, this keyboard and mouse rest combo is an essential accessory to add comfort and support to your hands and wrists. It’s also a great gift for men, women, family, friend, coworker, gamer, teacher, etc.
Account for data, schema, and network side effects
An image rollback changes application binaries and files inside the container. It does not automatically reverse changes made outside the image.
Database migrations
A bad release may have applied a schema migration before it began failing. The previous binary might not understand the new schema, or it might require a backward-compatible migration. Check the application’s migration history and compatibility policy before directing production traffic to the old image. Reversing a migration is a separate, potentially destructive operation and should not be bundled casually with the container rollback.
Queues and external writes
Messages emitted by the failed release can remain in a queue, and records written to an external system remain there after the container is replaced. Determine whether the old version can safely consume those messages and whether compensating actions are required. Do not delete a queue or volume merely to make the old image start.
Volumes and cleanup commands
Named volumes are normally retained by Compose recreation, but commands such as docker compose down -v remove volumes and can destroy persistent data. Anonymous-volume behavior can also be changed with --renew-anon-volumes. Review the volume declarations and backup status before any cleanup.
Addresses and client connections
A recreated Compose container can receive a new IP address, and old TCP connections terminate when the container is replaced. Use service discovery names, published ports, or the swarm service endpoint rather than hard-coding container addresses. Verify that connection pools and retry logic recover without creating duplicate writes.
Do these 3 things before closing this tab:
1Fix the driver behind crashes, sound loss and screen glitches2Repair Windows errors before they cause bigger problems3Scan for outdated or missing drivers - takes under a minuteConfigure automatic protection for future Swarm updates
Swarm exposes controls for monitor duration, maximum failure ratio, parallelism, delay, failure action, and operation order. Setting --update-failure-action=rollback tells Swarm to revert automatically when an update exceeds the configured failure threshold.
Best Value
- 【No Drill Mounted】Cable management tray can be assembled in as little as 3 minutes or less-simply. Side clips easily clampe the edge of desk, pass through the holes on the sides, and secure excess cables with baskets. Desk cable management supports inward or outward installation to meet your needs in different scenarios, and provides you with great convenience when collecting and organizing wires.
- 【Rubber Pad Protects Desk】Wire organizer under desk built-in soft rubber pads on the clamp protect your desk from scratches, so you will not damage your furniture or office.
- 【Sturdy and Beautiful】Cord management under desk is made of high-quality carbon steel and holds about 15 lbs. The wire basket has 2 holes on each side of the tray to enable your cables to pass freely. Cable baskets are suitable for desk thickness use from 0.4" to 2.4".
- 【Space Saving & Keep Organized】Desk cable management tray holds all your power cords, outlet strips, USB hubs and computer transformers hidden from your feet, and the data cables will not enter the vacuum cleaner to keep your desk clean and tidy. Desk wire organizer is also suitable for use in the kitchen and outdoors.
- 【Reduce Safety Risks】Cable tray under desk keeps all plugs away from your kids, no more worry about tripping. Using 2 holes wire tray saves extra space, helps you easily cabling and wire protection. The mesh design is not easy to accumulate dust, but avoids safety accidents caused by messy wires.
docker service update
--update-parallelism 1
--update-delay 10s
--update-monitor 60s
--update-max-failure-ratio 0.1
--update-failure-action rollback
SERVICE
Choose a monitor window long enough to include startup, dependency initialization, and early health checks. A window that ends immediately after process startup can miss failures that appear only when traffic arrives. Parallelism and delay determine how much capacity is exposed during the rollout; conservative values reduce blast radius but lengthen deployment time.
Define rollback behavior in a Compose deploy specification
The Compose deploy specification exposes analogous update_config and rollback_config fields, including failure_action, monitor, max_failure_ratio, parallelism, delay, and order. Use them when the Compose implementation and deployment target support those fields.
services:
api:
image: 'registry.example/app:2.8.3'
deploy:
update_config:
parallelism: 1
delay: 10s
monitor: 60s
failure_action: rollback
max_failure_ratio: 0.1
order: start-first
rollback_config:
parallelism: 1
delay: 5s
monitor: 60s
failure_action: pause
max_failure_ratio: 0.1
order: stop-first
These settings govern how an orchestrated deployment proceeds; they do not create a backup of database data or guarantee that an incompatible schema can be used by the previous image. Test the deployment behavior in a staging environment that resembles production.
Troubleshoot common rollback failures
The old tag starts the bad image again
The tag probably moved in the registry. Compare the digest now resolved by the registry with the digest recorded for the healthy release. Replace the tag with the exact @sha256: reference, or restore the tag in the registry only under a controlled change process.
The digest cannot be pulled
Check registry authentication, repository retention, and the digest spelling. If the image exists in another trusted registry or on a host that still has it locally, preserve a copy according to your organization’s change policy before attempting the rollback. Do not substitute a similarly named tag without verifying its digest.
Compose says the service is unchanged
Confirm that you edited the Compose file and project directory actually used by the deployment, and that an environment variable is not overriding the image. Run docker compose config to render the effective configuration, then rerun docker compose up -d SERVICE.
The Swarm rollback has no useful effect
Check that you are on a manager and that the failed release was created by docker service update. Swarm rollback restores the configuration immediately before the most recent update; it cannot infer an older release that is not in that history. Use an explicit image digest and restore any other changed service settings when necessary.
Outdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware matchWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallThe old application starts but fails health checks
Inspect health-check output and application logs, then compare environment variables, secrets, mounted configuration, and network dependencies between the failed and restored specifications. If the database schema or external API contract changed, the previous image may genuinely be incompatible. Stop sending traffic until that compatibility issue is resolved.
Clients still report errors after tasks are healthy
Reconnect clients and inspect the routing layer, DNS, load balancer, and connection pools. A healthy container does not repair a stale client connection or a proxy that cached the failed endpoint. Verify a fresh request from the same network path real users take.
Quick Recap
Quick decision guide
| Situation | Action |
|---|---|
| One-host Compose project, previous digest known | Restore the digest in the Compose configuration and run docker compose up -d SERVICE. |
| Swarm service, last update is the bad release | Run docker service rollback SERVICE on a manager and monitor tasks. |
| Tag may have moved | Do not rely on the tag; deploy the recorded digest. |
| Application changed schema or external data | Treat compatibility, migration, and data recovery as separate decisions before restoring traffic. |
| Rollback appears successful but users still fail | Check health checks, logs, routing, reconnect behavior, and a representative request rather than relying on container state alone. |
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

