Open thamjayshen opened 1 month ago
[!IMPORTANT] The "Needs: Triage :mag:" label must be removed once the triage process is complete!
[!TIP] For additional guidance on how to triage this issue/PR, see the TF Issue Triage documentation.
[!WARNING] Tagging the AVM Core Team (@Azure/avm-core-team-technical-terraform) due to a module owner or contributor having not responded to this issue within 3 business days. The AVM Core Team will attempt to contact the module owners/contributors directly.
[!TIP]
- To prevent further actions to take effect, the "Status: Response Overdue 🚩" label must be removed, once this issue has been responded to.
- To avoid this rule being (re)triggered, the ""Needs: Triage :mag:" label must be removed as part of the triage process (when the issue is first responded to)!
[!WARNING] Tagging the AVM Core Team (@Azure/avm-core-team-technical-terraform) due to a module owner or contributor having not responded to this issue within 3 business days. The AVM Core Team will attempt to contact the module owners/contributors directly.
[!TIP]
- To prevent further actions to take effect, the "Status: Response Overdue 🚩" label must be removed, once this issue has been responded to.
- To avoid this rule being (re)triggered, the ""Needs: Triage :mag:" label must be removed as part of the triage process (when the issue is first responded to)!
[!CAUTION] This issue requires the AVM Core Team's (@Azure/avm-core-team-technical-terraform) immediate attention as it hasn't been responded to within 6 business days.
[!TIP]
- To avoid this rule being (re)triggered, the "Needs: Triage :mag:" and "Status: Response Overdue :triangular_flag_on_post:" labels must be removed when the issue is first responded to!
- Remove the "Needs: Immediate Attention :bangbang:" label once the issue has been responded to.
Check for previous/existing GitHub issues
Issue Type?
Bug
(Optional) Module Version
No response
(Optional) Correlation Id
No response
Description
configuring flow_logs parameter without specifying the traffic_analytics results in an error. Example configuration: nw1 = { flow_logs = { flowlog1 = { enabled = true name = "test-flowlog" target_resource_id = "your_target_resource_id" storage_account_id = "your_storage_account_id "
no traffic_analytics specified
}
Resolution:
We overwrite in .terraform\modules\network_watcher\main.flowlogs.tf to make it optional
flowAnalyticsConfiguration = each.value.traffic_analytics != null ? { networkWatcherFlowAnalyticsConfiguration = { enabled = each.value.traffic_analytics.enabled trafficAnalyticsInterval = try(each.value.traffic_analytics.interval_in_minutes, 60) workspaceId = each.value.traffic_analytics.workspace_id workspaceRegion = each.value.traffic_analytics.workspace_region workspaceResourceId = each.value.traffic_analytics.workspace_resource_id } } : null