Open fjromerom opened 2 years ago
@fjromerom currently AFT does not support change of secondary region after AFT has been deployed. I have gone ahead and created a backlog to potentially support this in future.
As a workaround you could try to manually delete the S3 bucket for the secondary region and wait at-least an hour (as AFT will be re-using the same name for bucket creation ) before you run the terraform apply
with the secondary region change.
Please note that we do not test this use case, we would recommend testing in your non-prod / test environment before trying in production.
Deleting the S3 Bucket worked fine.
Thanks for your input!
AFT Version: 1.6.2
Terraform Version & Provider Versions
terraform version
terraform providers
Bug Description We have made the decision to change the secondary region of AFT and I receive the following error:
It seems the module is passing the region as provider and it's unable to find the current S3 Bucket in the secondary region.
https://github.com/aws-ia/terraform-aws-control_tower_account_factory/blob/d7699b113f29bd5d2ca8986f8430dabc2a003845/modules/aft-backend/main.tf#L80
This behavior differs from how Terraform usually manage the providers which provides more flexibility.
What is the process to make this change in a safe manner?
To Reproduce Steps to reproduce the behavior:
Expected behavior The aft-backend module should support a change in the region. I'm aware I'll need to manually delete all the objects in the S3 Bucket but the module should recreate the resources in the new region afterwards.
Thanks, Francisco