This message was deleted.
# google-cloud
s
This message was deleted.
o
Hey Nick! To use
lifecycle.ignore_changes
with
gcp.compute.AttachedDisk
and
gcp.compute.Instance
, you need to add the
ignoreChanges
option to the instance resource in your Pulumi program. Here's an example in TypeScript:
Copy code
typescript
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";

const instance = new gcp.compute.Instance("my-instance", {
    // other instance configuration options...
    attachedDisks: [
        // attached disk configuration...
    ],
}, {
    ignoreChanges: ["attachedDisks"],
});
This will ensure that any changes to the attached disks will not cause Pulumi to try to update the instance resource, avoiding the fight for control of the attached disk block.
🙌 1