Skip to content

08 2020 codeploy deploymentgroup condition

Jeff Griffiths (@aws) edited this page Nov 17, 2020 · 3 revisions

Resource conditions were not applied to DeploymentPreference resources

The SAM transform currently has a bug where resource conditions are not applied to DeploymentPreference resources, causing unnecessary resources to be created. In the future the SAM team will release a new version of the SAM transform that correctly applies resource conditions. If you then deploy your application with this new version of the SAM transform, no unnecessary resource will be created, howver you may run into problems if you have discovered and referenced these resources directly.

To mitigate this issue, please review the resources associated with your application in the AWS Console and ensure you are not directly referencing any 'AWS::CodeDeploy::DeploymentGroup' resources from other parts of your application or infrastructure. If you are, you can work around the problem in one of two ways:

  1. remove or adjust the resource conditions in your code to ensure the resources are still created.
  2. retain the resource conditions in your template and instead use the AWS Console to manually create alternative resources to refer to.

For more information on this issue, please see Pull Request 1578.