When running terraform destroy the S3 buckets need to be empty to properly complete. Force deletion is already supported for the website bucket using website_bucket_force_destroy = true but the log bucket will still prevent destruction. The added input will allow configuration for the logging bucket to also be force deleted when it is not empty.
Changes
Create log_bucket_force_destroy variable, defaulted to false
Summary
When running
terraform destroy
the S3 buckets need to be empty to properly complete. Force deletion is already supported for the website bucket usingwebsite_bucket_force_destroy = true
but the log bucket will still prevent destruction. The added input will allow configuration for the logging bucket to also be force deleted when it is not empty.Changes
log_bucket_force_destroy
variable, defaulted tofalse
s3_bucket_force_destroy
from cn-terraform/logs-s3-bucket/awsNotes
This is my first PR to a Terraform module, please let me know if there is anything else that would be needed for these changes. Thanks!