Skip to content

Deploying changes

Statera applies configuration changes to running services gradually and lets you pause or roll back at any point.

Apply

statera apply production.yaml

This computes the diff against the live state, validates it, and begins a rollout. By default the change reaches 10% of instances first, then the rest once health checks stay green.

Watch a rollout

statera rollout status billing-api
revision 128 → 129
  canary    10%   healthy
  remaining 90%   in progress (62%)
  started   12s ago

Pause and resume

statera rollout pause billing-api
statera rollout resume billing-api

A paused rollout holds its current percentage until you resume or roll back.

Roll back

statera rollback billing-api --to 128

Rollback is itself a gradual rollout, so the previous state returns the same safe way it left.

In CI

A typical pipeline step:

export STATERA_TOKEN=$CI_STATERA_TOKEN
statera validate production.yaml
statera apply production.yaml --wait

--wait blocks until the rollout finishes and returns a non-zero exit code if any instance fails its health check, so a bad change fails the pipeline.

Tip

Run statera validate as a separate earlier stage so obviously broken configuration is caught before the deploy job even starts.