-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docs - Provide instructions for correcting resource dependencies during aws.s3.Bucket -> aws.s3.BucketV2 migration #5131
Comments
Related to this : #4470 |
@fabien-github I think you're running into this issue: BucketV2 to Bucket aliasing is no longer working· pulumi-aws/4471 Unfortunately, it does require some state edits right now to migrate |
@fabien-github do you have an example program showing the old bucket and those dependent resources I can use to walk through this? |
Sure, here with python, the bucket will be parent of the policy and the iam role :
Directly deleting the bucket following docs :
|
@fabien-github thanks for the example, I think I understand what is happening now. I think we might need to re-order the steps in our migration guide to take this scenario (which I think is a common one) into account. Instead of deleting from state and then performing the import, I think we should perform the import and then delete from state.
There will be a couple of steps during the migration where the resources are technically being managed by two different resource definitions, but since no changes are being made and we are just updated the dependency information in state we should be fine. The other option would be to manually edit the state to update the dependency info instead of running Let me know what you think about this and we can update our migration guide to account for this scenario. cc @t0yv0 |
Hi @corymhall, |
@corymhall thanks so much, could you update the guide at https://www.pulumi.com/registry/packages/aws/how-to-guides/bucketv2-migration/#migrating-with-pulumi-import |
File: themes/default/content//registry/packages/aws/how-to-guides/bucketv2-migration
Hi,
during the migration between aws.s3.Bucket to aws.s3.BucketV2, i was stuck by dependencies during the removal of the bucket state :
--target-dependents
option removes child, so i don't think it will be wanted by users.I'm not sure what is the best way to fix that without editing the state file.
I don't know how you want to handle this case in the documentation. I think it's going to be pretty widespread.
The text was updated successfully, but these errors were encountered: