2

For instance, to implement a Blue/Green deployment pipeline with CodeDeploy on AWS ECS, I first use Pulumi to provision Load Balancer, Listeners and Target Groups (among other resources). But after I supply the Listeners to create the DeploymentConfig on CodeDeploy, the Blue/Green deployment controller will manipulate the Listeners on each deployment.

At this point, if I run pulumi preview again, it shows that the Listeners have diverged (due to a new deployment) and Pulumi will attempt to "fix" that, conflicting with the deployment controller.

The only solution I see so far is to use pulumi state delete to make Pulumi stop tracking those resources, but it doesn't seems like the right way to go.

What is the proper way to handle resources that are first create by Pulumi but afterwards managed elsewhere?

Diogo Melo
  • 1,735
  • 3
  • 20
  • 29
  • The issue is not limited to Pulumi. It would be same in Terraform and CloudFormation. Sadly the most probable answer is to manually adjust your code to match new setup. – Marcin Sep 30 '21 at 23:12
  • The best thing I came up with is using attr "ignore_changes" on the resource option. – Diogo Melo Oct 01 '21 at 22:06
  • 1
    Yes, that would work, but this results in a permanent drift which can lead to more issues later on. – Marcin Oct 01 '21 at 23:04

0 Answers0