Skip to main content

redeploy

redeploy a deployment

🚀 Redeploy a deployment.

Redeploying rolls out the current settings as a rolling update: the running spherelet keeps serving until the new one passes its health check, so there's no downtime.

By default the command waits for the rollout to finish: the new spherelets are ready and the old ones have stopped. It exits non-zero if the rollout fails or doesn't finish within --wait-timeout (the rollout carries on in the background either way). It waits in CI and when piped too, so the exit code reflects the outcome. Pass --no-wait to return as soon as the redeploy is accepted.

With --output json or yaml, the final status is printed as an object: id, status, success, timed_out and, on failure, a message.

Usage​

csph deployments redeploy [flags]

Options​

Command Specific​

--account <string>
account ID
--no-wait
return as soon as the redeploy is accepted instead of waiting for the rollout to finish

--wait-timeout <duration> (default "5m0s")

how long to wait for the rollout to finish before exiting non-zero

Formatting​

For more information about formatting options, see Formatting.

-o, --output <string>

output format: [table|plain|csv|json|yaml]

Inherited​

--config <string>
config file (default is $HOME/.config/computesphere/configuration.yaml)
--debug
enable debug logging

-h, --help

show this help message

-i, --interactive

run interactively (prompts, pickers, table browser)
--log-level <string>
log level: [trace|debug|info|warn|error|fatal|panic|disabled||api]
--no-color
disable color output
--no-input
disable interactive mode

Examples​

# redeploy a deployment interactively
> csph deployments redeploy

# redeploy a deployment and wait for the rollout to finish
> csph deployments redeploy <deployment-id>

# give a slow rollout longer to finish
> csph deployments redeploy <deployment-id> --wait-timeout 10m

# start the redeploy and return immediately
> csph deployments redeploy <deployment-id> --no-wait

# report the final status as JSON (e.g. in CI)
> csph deployments redeploy <deployment-id> -o json

See also​