-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
feat: support bucket_key_enabled for server_side_encryption_configura… #82
feat: support bucket_key_enabled for server_side_encryption_configura… #82
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please update versions.tf
with a minimum version of Terraform AWS provider 3.36.0 in the module and in the examples.
Also, could you please add the same change to modules/object?
Thank you!
main.tf
Outdated
@@ -196,6 +196,7 @@ resource "aws_s3_bucket" "this" { | |||
for_each = length(keys(lookup(server_side_encryption_configuration.value, "rule", {}))) == 0 ? [] : [lookup(server_side_encryption_configuration.value, "rule", {})] | |||
|
|||
content { | |||
bucket_key_enabled = lookup(rule.value, "bucket_key_enabled", false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leave the default value as null
, please.
@@ -196,6 +196,7 @@ resource "aws_s3_bucket" "this" { | |||
for_each = length(keys(lookup(server_side_encryption_configuration.value, "rule", {}))) == 0 ? [] : [lookup(server_side_encryption_configuration.value, "rule", {})] | |||
|
|||
content { | |||
bucket_key_enabled = lookup(rule.value, "bucket_key_enabled", null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please do a similar update to the object
submodule also.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I misread the contents of the first review.
I'll do it.
2aab7ac
to
d128396
Compare
Thanks, @kumashun8 ! v2.1.0 has been just released. |
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
…tion.rule
Description
Make
server_side_encryption_configuration
to be able to set tobucket_key_enabled
.Motivation and Context
Recently,
bucket_key_enable
was supported byterraform-provider-aws
in the following PR.so I'd like to reflect that here as well.
hashicorp/terraform-provider-aws#16581
Breaking Changes
bucket_key_enabled
is a optional value, so compatibility won't be lost.How Has This Been Tested?
examples/*
projectscurrent plan at
example/complete
result is below (extracted).and apply was done successfully (extracted).
next, edit
example/complete/main.tf
line:191-199 to add variablebucket_key_enabled
like this.plan result is below (extracted).
and apply complete successfully (extracted).