Interview Prep/Terraform/Refactoring, Migration and Drift

What do you do when a resource type is deprecated, like inline `acl` on `aws_s3_bucket`?

IntermediateProductionRefactoring, Migration and Drift
Answer

Read the provider's migration guide, adopt the replacement resources (aws_s3_bucket_acl, aws_s3_bucket_ownership_controls), import existing settings into them with import blocks if needed and verify an empty plan. Do it per module with a minor-version release, so consumers upgrade at their own pace.

All Terraform questions Roadmap: Terraform in production

More on Refactoring, Migration and Drift