Adds log_analytics module and workspace

This commit is contained in:
Rob Gil
2020-01-27 12:43:46 -05:00
parent 45322c871d
commit 0900c01d88
4 changed files with 45 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
resource "azurerm_resource_group" "log_workspace" {
name = "${var.name}-${var.environment}-log-workspace"
location = var.region
}
resource "azurerm_log_analytics_workspace" "log_workspace" {
name = "${var.name}-${var.environment}-log-workspace"
location = azurerm_resource_group.log_workspace.location
resource_group_name = azurerm_resource_group.log_workspace.name
sku = "Premium"
tags = {
environment = var.environment
owner = var.owner
}
}