Skip to content

Commit

Permalink
Merge pull request #179 from CDCgov/better-logging-query
Browse files Browse the repository at this point in the history
Make the Logging Query Similar to TI's
  • Loading branch information
halprin authored Oct 3, 2024
2 parents 81143ad + 13dfa69 commit 0d6a809
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion operations/template/logs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ resource "azurerm_log_analytics_query_pack_query" "structured_application_logs"
query_pack_id = azurerm_log_analytics_query_pack.application_logs_pack.id
categories = ["applications"]

body = "AppServiceConsoleLogs | extend JsonResult = parse_json(ResultDescription) | project-away TimeGenerated, Level, ResultDescription, Host, Type, _ResourceId, OperationName, TenantId, SourceSystem | evaluate bag_unpack(JsonResult)"
body = "AppServiceConsoleLogs | project JsonResult = parse_json(ResultDescription) | evaluate bag_unpack(JsonResult) | project-reorder ['time'], level, msg"
}

resource "azurerm_monitor_diagnostic_setting" "app_to_logs" {
Expand Down

0 comments on commit 0d6a809

Please sign in to comment.