CLI Options
- Docker flags
-f | --file FILE
-t | --timeout SECONDS
-w | --wait SECONDS
--wait-after-healthy SECONDS
--env-file FILE
Docker flags
All docker flags can be used with docker rollout
normally, like --context
, --env
, --log-level
, etc.
docker --context my-remote-context rollout <service-name>
The plugin flags are described below.
-f | --file FILE
Path to compose file, can be specified multiple times, as in docker compose
.
Example
Single file:
docker rollout -f docker-compose.yml <service-name>
With override file:
docker rollout -f docker-compose.yml -f docker-compose.override.yml <service-name>
-t | --timeout SECONDS
Timeout in seconds to wait for new container to become healthy, if the container has healthcheck defined.
Default: 60
Example
Decrease timeout to 30 seconds:
docker rollout --timeout 30 <service-name>
-w | --wait SECONDS
Time to wait for new container to be ready if healthcheck is not defined.
Default: 10
Example
Increase wait time to 30 seconds for a service that takes longer to start:
docker rollout --wait 30 <service-name>
--wait-after-healthy SECONDS
Time to wait after new container is healthy before removing old container. Works when a healthcheck is defined. Can be useful if the service healthcheck is not reliable and the service needs some time to stabilize (see #27).
Default: 0
Example
Wait 10 seconds after a new container is healthy before terminating the old container:
docker rollout --wait-after-healthy 10 <service-name>
--env-file FILE
Path to env file, can be specified multiple times, like in docker compose
.
See Docker Compose documentation.
Example
Single env file:
docker rollout --env-file .env <service-name>
Multiple env files:
docker rollout --env-file .env --env-file .env.prod <service-name>