Menu
AWS CodeDeploy
User Guide (API Version 2014-10-06)

Working with Deployment Configurations in AWS CodeDeploy

A deployment configuration is a set of deployment rules and deployment success and failure conditions used by AWS CodeDeploy during a deployment. The deployment configuration specifies the number or percentage of instances that must remain available at any time during a deployment.

You can use one of the three predefined deployment configurations provided by AWS or create a custom deployment configuration that better meets your requirements. If you don't specify a deployment configuration, AWS CodeDeploy uses the CodeDeployDefault.OneAtATime deployment configuration.

To view a list of deployment configurations already registered to your AWS account, see View Deployment Configuration Details.

Predefined Deployment Configurations in AWS

The following table lists the predefined deployment configurations provided by AWS.

Deployment ConfigurationDescription
CodeDeployDefault.AllAtOnceAttempts to deploy an application revision to as many instances as possible at once. The status of the overall deployment will be displayed as Succeeded if the application revision is deployed to one or more of the instances. The status of the overall deployment will be displayed as Failed if the application revision is not deployed to any of the instances. Using an example of nine instances, CodeDeployDefault.AllAtOnce will attempt to deploy to all nine instances at once. The overall deployment will succeed if deployment to even a single instance is successful; it will fail only if deployments to all nine instances fail.
CodeDeployDefault.HalfAtATimeDeploys to up to half of the instances at a time (with fractions rounded down). The overall deployment succeeds if the application revision is deployed to at least half of the instances (with fractions rounded up); otherwise, the deployment fails. In the example of nine instances, it will deploy to up to four instances at a time. The overall deployment succeeds if deployment to five or more instances succeed; otherwise, the deployment fails. The deployment may be successfully deployed to some instances even if the overall deployment fails.
CodeDeployDefault.OneAtATime

Deploys the application revision to only one instance at a time.

For deployment groups that contain more than one instance:

  • The overall deployment succeeds if the application revision is deployed to all of the instances. The exception to this rule is if deployment to the last instance fails, the overall deployment still succeeds. This is because AWS CodeDeploy allows only one instance at a time to be taken offline with the CodeDeployDefault.OneAtATime configuration.

  • The overall deployment fails as soon as the application revision fails to be deployed to any but the last instance. The deployment may be successfully deployed to some instances even if the overall deployment fails.

  • In an example using nine instances, it will deploy to one instance at a time. The overall deployment succeeds if deployment to the first eight instances is successful; the overall deployment fails if deployment to any of the first eight instances fails.

For deployment groups that contain only one instance, the overall deployment is successful only if deployment to the single instance is successful