Hello Everyone, After importing a aws resource(sub...
# aws
m
Hello Everyone, After importing a aws resource(subnet) into pulumi I would like to modify the properties. This leads to replacement. Is this a pulumi thing or an aws thing? I would like to change few properties on the resource...
Copy code
pulumi up
Previewing update (network.staging):
     Type                     Name                                           Plan        Info
     pulumi:pulumi:Stack      pulumi-staging-infrastructure-network.staging              
 +   ├─ pulumi:providers:aws  provider                                       create      
 +-  ├─ aws:ec2:Vpc           vpc-staging                                    replace     [diff: +enableDnsSupport,instanceTenancy~__defaults,protect,provider]
 +-  └─ aws:ec2:Subnet        public_subnet_stvk                             replace     [diff: +assignIpv6AddressOnCreation,enableDns64,enableResourceNameDnsARecordOnLaunch,ena
 
Resources:
    + 1 to create
    +-2 to replace
    3 changes. 1 unchanged
b
it depends what you’re replacing. Usually a replacement is because the AWS API is immutable
in this case yes, the properties are immutable
m
So it will delete and recreate...
b
Yes unfortunately. Can you make that change in the API without a delete and recreate?
m
Not sure maybe can try from the console...But I doubt that aws will let me...Will update you with what i find..thank you..
b
I ask because, if you can do it from the console but not Pulumi, that’s a bug if you can’t do it from the console that confirms it’ll delete/replace is expected behavior
m
thanks, that was it./