Skip to content

Commit

Permalink
* 2.6.1 -- 2024-09-11
Browse files Browse the repository at this point in the history
  - cloudtrail
    - add variable enable_logging to disable the objectlogging trail
  • Loading branch information
badra001 committed Sep 11, 2024
1 parent 655f5c6 commit 583407e
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 3 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -365,4 +365,8 @@

* 2.6.0 -- 2024-07-09
- cloudtrail
- add variable enable_organization_s3_objectlogging, when usewd with enable_organization, to do data events
- add variable enable_organization_s3_objectlogging, when used with enable_organization, to do data events

* 2.6.1 -- 2024-09-11
- cloudtrail
- add variable enable_logging to disable the objectlogging trail
1 change: 1 addition & 0 deletions cloudtrail/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,7 @@ No modules.
| <a name="input_component_tags"></a> [component\_tags](#input\_component\_tags) | Additional tags for Components (s3, kms, ddb) | `map(map(string))` | <pre>{<br> "ddb": {},<br> "kms": {},<br> "s3": {}<br>}</pre> | no |
| <a name="input_create_cloudtrail"></a> [create\_cloudtrail](#input\_create\_cloudtrail) | Flag to enable or disable creation of cloudtrail | `bool` | `true` | no |
| <a name="input_enable_cloudwatch_logs"></a> [enable\_cloudwatch\_logs](#input\_enable\_cloudwatch\_logs) | Enable CloudWatch Logs for this CloudTrail | `bool` | `true` | no |
| <a name="input_enable_logging"></a> [enable\_logging](#input\_enable\_logging) | Enable CloudTrail logging. This is to be able to turn off a CloudTrail (like the objectlogging, which we are removing) | `bool` | `true` | no |
| <a name="input_enable_organization"></a> [enable\_organization](#input\_enable\_organization) | Enable CloudTrail as an organization trail. This will only work in the organization master or delegated account | `bool` | `false` | no |
| <a name="input_enable_organization_s3_objectlogging"></a> [enable\_organization\_s3\_objectlogging](#input\_enable\_organization\_s3\_objectlogging) | Enable CloudTrail organization trail S3 data events | `bool` | `false` | no |
| <a name="input_enable_s3_sns"></a> [enable\_s3\_sns](#input\_enable\_s3\_sns) | Flag to enable or disable the creation of SNS for the Cloudtrail S3 bucket | `bool` | `false` | no |
Expand Down
2 changes: 1 addition & 1 deletion cloudtrail/cloudtrail.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ resource "aws_cloudtrail" "this" {
include_global_service_events = true
is_multi_region_trail = var.enable_organization ? true : false
enable_log_file_validation = true
enable_logging = true
enable_logging = var.enable_logging
kms_key_id = var.kms_key_arn
sns_topic_name = var.enable_sns ? aws_sns_topic.cloudtrail[0].arn : null
cloud_watch_logs_group_arn = var.enable_cloudwatch_logs ? format("%v:*", aws_cloudwatch_log_group.this[0].arn) : null
Expand Down
7 changes: 7 additions & 0 deletions cloudtrail/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -125,3 +125,10 @@ variable "create_cloudtrail" {
type = bool
default = true
}

variable "enable_logging" {
description = "Enable CloudTrail logging. This is to be able to turn off a CloudTrail (like the objectlogging, which we are removing)"
type = bool
default = true
}

2 changes: 1 addition & 1 deletion common/version.tf
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
locals {
_module_version = "2.6.0"
_module_version = "2.6.1"
}

0 comments on commit 583407e

Please sign in to comment.