Skip to main content
In this lesson we demonstrate how to perform a gradual release using the canary deployment model provided by Argo Rollouts. Argo Rollouts extends Kubernetes Deployments with more control over update behavior — enabling canary, blue-green, and progressive delivery strategies. The canary strategy routes a percentage of traffic to a new revision and increases that percentage in controlled steps with optional pauses for validation.
The image shows a webpage titled "Canary Deployment Strategy" from Argo Rollouts, discussing a method for gradually releasing a new software version. It includes an overview and table of contents on the right.

Rollout manifest (canary strategy) — overview

A Rollout manifest (kind: Rollout) looks like a Deployment but gives you fine-grained control of updates. Instead of replacing all pods at once, the canary strategy lets you increment traffic using setWeight steps and pause actions (timed or indefinite). Example Rollout (illustrative):
Pause duration formats supported: seconds (10s), minutes (10m), hours (1h), or an empty object ({}) for an indefinite (manual) pause:
A pause: {} is an indefinite pause — the rollout will wait until you manually promote the next step (UI or kubectl argo rollouts promote). Plan for manual verification before continuing.

Blue-green (reference snippet)

For comparison, here is a sample blue-green configuration (used for preview/promotion workflows):

Applying the canary example from the repository

This repository contains a patterns/canary/ folder with rollout.yml and service.yml. Below are the manifests used in the demo. Initial rollout.yml (canary steps):
For demo speed we adjusted timed pauses to 10s so the rollout completes faster:
Commands to create the namespace and apply the manifests:
Expected simplified output after apply:
Argo Rollouts manages ReplicaSets and pods for Rollout resources. You will not see a Kubernetes Deployment for this workload — instead look for rollout.argoproj.io and ReplicaSets.

Inspecting Rollouts

List rollouts in the cluster or a specific namespace:
Example output:

Accessing the application and observing canary traffic

The Service exposes the app on a NodePort (e.g., 30797). In the demo we continuously polled the /app endpoint and printed the reported application version. Use this local script (adjust the port as necessary):
This output will show mostly v1 at first, then occasional v2 responses as the canary begins, then a growing mix of v2 as the setWeight increases, and finally all v2 once the rollout completes.

Promoting a new version (UI or CLI)

To promote a new revision, update the container image to v2 in the manifest and apply it (or use the UI). The Rollout will create a new revision and follow the configured canary steps:
  • A setWeight: 20 step means 2 of 10 pods will run v2 while 8 run v1.
  • If the first step contains pause: {}, the rollout will stop for manual promotion.
  • On manual promotion, the rollout proceeds to 40%, 60%, 80%, and finally 100% (with configured pauses).
Promote with the kubectl plugin:
Make sure the kubectl-argo-rollouts plugin is installed if you plan to promote from the CLI. Alternatively, use the Argo Rollouts UI.
The image shows the interface of Argo Rollouts, displaying a canary deployment strategy with various weighted steps and a successful revision summary.
Example progression (polling output):
As you promote through higher setWeight steps, the frequency of v2 responses increases until all pods serve v2.
The image shows an Argo Rollouts dashboard for managing application rollout strategies, specifically using a canary deployment strategy. It displays steps with weight settings, a container selection, and revision details.

Rollbacks and stability

Argo Rollouts keeps a revision history and supports rollback to a previous revision if issues are detected during promotion. You can revert using the UI or the CLI to restore a stable revision. The UI highlights stable revisions and current status for easy rollback.
The image shows a software interface for managing application rollouts, displaying steps like setting weights and pauses, with revisions marked as stable or "No Pods".

Quick reference

Table: common pause durations and promotion commands Summary of best practices
  • Use setWeight steps to route a specific percentage of traffic to a new revision.
  • Combine timed pauses (e.g., 10s, 1m) with indefinite pauses ({}) for manual verification.
  • Observe application metrics and logs during each pause before promoting.
  • Use the Argo Rollouts UI or kubectl-argo-rollouts plugin to promote, inspect, and roll back as needed.
Ensure Argo Rollouts CRDs and controller are installed in your cluster and install the kubectl-argo-rollouts plugin if you intend to promote or inspect rollouts from the CLI. See the Argo Rollouts installation guide for details.
That’s all for now.

Watch Video

Practice Lab