https://pulumi.com logo
Title
f

fast-arm-63150

03/12/2022, 12:38 AM
Hi good people! Apologies for the cross-posting but this is a basic question about pulumi that I'm hoping has been addressed before: I have renamed the resource name (the first argument in a resource constructor) and pulumi up complains with a Error 409 that the resource already exists - what is the best practice on dealing with this? I have already: 1. used an alias 2. used delete_before_replace = True So I'm not sure why I would still get this issue? Would really love some insight into this!
q

quiet-wolf-18467

03/13/2022, 10:51 AM
You can rename with the CLI https://www.pulumi.com/docs/reference/cli/pulumi_state_rename/ Though I would have expected an alias to work too
f

fast-arm-63150

03/14/2022, 3:06 PM
@quiet-wolf-18467 Hey I'm using the automation API so no CLI for me
The alias seems to work for 'name' but not 'resource_name' (first constructor in resource)