-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmain.tf
More file actions
32 lines (25 loc) · 1.01 KB
/
main.tf
File metadata and controls
32 lines (25 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
resource "azurerm_service_plan" "appserviceplan" {
name = var.name
resource_group_name = var.resource_group_name
location = var.location
os_type = var.os_type
sku_name = var.sku_name
zone_balancing_enabled = var.zone_balancing_enabled
tags = var.tags
lifecycle {
ignore_changes = [tags]
}
}
resource "azurerm_app_service_virtual_network_swift_connection" "appservice_vnet_swift_connection" {
count = var.vnet_integration_enabled ? 1 : 0
app_service_id = azurerm_service_plan.appserviceplan.id
subnet_id = var.vnet_integration_subnet_id
}
module "diagnostic-settings" {
source = "../diagnostic-settings"
name = "${var.name}-diagnostic-setting"
target_resource_id = azurerm_service_plan.appserviceplan.id
log_analytics_workspace_id = var.log_analytics_workspace_id
enabled_metric = var.monitor_diagnostic_setting_appserviceplan_metrics
#enabled_log = var.enabled_log
}