Custom Canary Deployments

This document describes how to configure and use custom canary deployments to deploy your applications to all target types using Cloud Deploy.

How custom canary deployments work

When you deploy using a custom canary deployment strategy, Cloud Deploy does not modify your manifests in order to facilitate the chosen traffic-balancing configuration. Instead you are responsible for providing manifests that are applied to your target runtime for each canary phase.

Make sure you have the required permissions

In addition to other Identity and Access Management permissions you need for using Cloud Deploy, you need the following permissions in order to perform additional actions that might be needed for a canary deployment:

  • clouddeploy.rollouts.advance
  • clouddeploy.rollouts.ignoreJob
  • clouddeploy.rollouts.cancel
  • clouddeploy.rollouts.retryJob
  • clouddeploy.jobRuns.get
  • clouddeploy.jobRuns.list
  • clouddeploy.jobRuns.terminate

See IAM roles and permissions for more information about what available roles include these permissions.

Prepare your skaffold.yaml

Your skaffold.yaml file defines how your manifests are rendered and deployed. For a custom canary deployment you are responsible for defining profiles that are associated with each canary phase in order to facilitate the chosen traffic-balancing configuration. These profiles are mapped to phases in the delivery pipeline strategy configuration.

The following is an example