enough-caravan-98871
02/16/2023, 3:57 PMpulumi up
after the successful deployment, Pulumi wants to update the VirtualNetwork resource to delete the subnet and peerings. Obviously, I dont want it to do that. This is strange behavior. How can I resolve it? Thanks!icy-doctor-13719
02/16/2023, 4:01 PMpulumi preview --diff
and bake any of the changes its trying to make into my code. it does a lot of things behind the scenes if stuff isn’t explicitly defined. you can also go to the resource in Azure and look at the JSON view for the API version you’re using.enough-caravan-98871
02/16/2023, 4:06 PMpulumi up
. I have everything defined explicitly. I think what I might need here is to utilize ignoreChanges
in the VirtualNetwork resource. I have never used `ignoreChanges' before and am having trouble declaring it.ignoreChanges: ["subnets", "virtualNetworkPeerings"]
did the trick.cold-midnight-30607
02/16/2023, 4:20 PMenough-caravan-98871
02/16/2023, 4:24 PMignoreChanges
worked perfectly. I was just surprised that it could not figure that out by default. I realize now that there is indeed power in being able to declare specifically what you want it to do.blue-potato-57538
02/17/2023, 9:36 AMenough-caravan-98871
02/27/2023, 11:37 PM