We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a93c233 commit 7bfc001Copy full SHA for 7bfc001
vpc-flow-logs.tf
@@ -24,10 +24,14 @@ resource "aws_flow_log" "this" {
24
vpc_id = local.vpc_id
25
max_aggregation_interval = var.flow_log_max_aggregation_interval
26
27
- destination_options {
28
- file_format = var.flow_log_file_format
29
- hive_compatible_partitions = var.flow_log_hive_compatible_partitions
30
- per_hour_partition = var.flow_log_per_hour_partition
+ dynamic "destination_options" {
+ for_each = var.flow_log_destination_type == "s3" ? [true] : []
+
+ content {
31
+ file_format = var.flow_log_file_format
32
+ hive_compatible_partitions = var.flow_log_hive_compatible_partitions
33
+ per_hour_partition = var.flow_log_per_hour_partition
34
+ }
35
}
36
37
tags = merge(var.tags, var.vpc_flow_log_tags)
0 commit comments