Files
code-snippets/docs/docker-swarm/index.md
Liam Pietralla dd30ade94b
All checks were successful
Build, Test & Publish / Build (pull_request) Successful in 26s
Build, Test & Publish / Build and Publish Container Image (pull_request) Has been skipped
Build, Test & Publish / Deploy to Infrastructure (pull_request) Has been skipped
docker swarm
2025-10-22 13:11:59 +11:00

27 lines
449 B
Markdown

# Docker Swarm Snippets and Musings
## Updating Services
View services:
```bash
docker service ls
```
To scale a service up or down:
```bash
docker service scale <service_name>=<number_of_replicas>
```
Sometimes services get stuck or need to be forcefully updated:
```bash
docker service update --force <service_name>
```
::: tip
Sometimes if you need to force containers to restart use the update force (e.g. after restarting a node).
:::