hashicorp / terraform-provider-aws

The AWS Provider enables Terraform to manage AWS resources.
https://registry.terraform.io/providers/hashicorp/aws
Mozilla Public License 2.0
9.85k stars 9.2k forks source link

[Enhancement]: aws_amplify_domain_association certificate_settings AMPLIFY_MANAGED should be default #38387

Open rsi-mrobinson opened 4 months ago

rsi-mrobinson commented 4 months ago

Description

the newly added (>=5.57.0) certificate_settings attribute should default to AMPLIFY_MANAGED rather than null. Existing resources appear to result in plans where the certificate settings are being removed, despite amplify managed domains being the default up to this point. The new certificate setting block should respect this an only be required to override the default settings.

Affected Resource(s) and/or Data Source(s)

aws_amplify_domain_association

Potential Terraform Configuration

No response

References

No response

Would you like to implement a fix?

None

github-actions[bot] commented 4 months ago

Community Note

Voting for Prioritization

Volunteering to Work on This Issue

justinretzolk commented 4 months ago

Hey @rsi-mrobinson 👋 Thank you for taking the time to raise this! To make sure I understand -- you're saying that if you update the version and make no other configuration changes, resources are being replaced on the next apply?

rsi-mrobinson commented 4 months ago

That's correct, if you upgrade to 5.57 or above without making changes to this resource, the plan shows a change to remove the default amplify managed dns

aayushsss1 commented 4 months ago

Hey @justinretzolk @rsi-mrobinson I can take this issue up, just to be clear the only change would be to add Default : "AMPLIFY_MANAGED" here right?

https://github.com/hashicorp/terraform-provider-aws/blob/c3b9b48e3b84197374aa8b3263c2b12ded3acfcc/internal/service/amplify/domain_association.go#L61-L67

rsi-mrobinson commented 4 months ago

That's what I'm thinking