forked from decensas/terraform-azurerm-azure-virtual-desktop
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.tf
61 lines (46 loc) · 1.71 KB
/
main.tf
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
provider "azurerm" {
features {}
}
resource "azurerm_resource_group" "main" {
name = "d-avd-availability-set"
location = "westeurope"
}
resource "azurerm_virtual_network" "main" {
name = "d-avd-vnet"
location = azurerm_resource_group.main.location
resource_group_name = azurerm_resource_group.main.name
address_space = ["10.0.0.0/16"]
}
resource "azurerm_subnet" "main" {
name = "default"
virtual_network_name = azurerm_virtual_network.main.name
resource_group_name = azurerm_virtual_network.main.resource_group_name
address_prefixes = ["10.0.0.0/24"]
}
resource "azurerm_network_security_group" "main" {
name = "d-avd-nsg"
location = azurerm_resource_group.main.location
resource_group_name = azurerm_resource_group.main.name
}
resource "azurerm_subnet_network_security_group_association" "main" {
subnet_id = azurerm_subnet.main.id
network_security_group_id = azurerm_network_security_group.main.id
}
module "avd" {
source = "decensas/azure-virtual-desktop/azurerm"
version = "0.1.2"
system_name = "avd"
resource_group_name = azurerm_resource_group.main.name
data_location = azurerm_resource_group.main.location
host_location = azurerm_resource_group.main.location
use_availability_set = true
availability_number_of_fault_domains = 3
availability_number_of_update_domains = 20
vm_size = "Standard_D2s_v3"
number_of_hosts = 3
host_pool_type = "Personal"
avd_users_upns = ["[email protected]", "[email protected]"]
avd_admins_upns = ["[email protected]"]
workspace_friendly_name = "Availability set"
subnet_id = azurerm_subnet.main.id
}