-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path39958.json
173 lines (173 loc) · 5.72 KB
/
39958.json
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
{
"apiVersion": "2015-06-15",
"type": "Microsoft.Network/networkInterfaces",
"name": "[concat(parameters('VMName'), '-NIC')]",
"location": "[resourceGroup().location]",
"tags": {
"displayName": "VM NIC"
},
"dependsOn": [],
"properties": {
"ipConfigurations": [
{
"name": "ipconfig1",
"properties": {
"privateIPAllocationMethod": "Dynamic",
"subnet": {
"id": "[variables('DCSubnetRef')]"
}
}
}
],
"dnsSettings": {
"dnsServers": [
"[variables('DCIPAddress')]"
]
}
}
},
{
"apiVersion": "2017-03-30",
"type": "Microsoft.Compute/virtualMachines",
"name": "[parameters('VMName')]",
"location": "[resourceGroup().location]",
"tags": {
"displayName": "VM"
},
"dependsOn": [
"[concat('Microsoft.Network/networkInterfaces/', parameters('VMName'), '-NIC')]"
],
"properties": {
"hardwareProfile": {
"vmSize": "[parameters('WSVMSize')]"
},
"osProfile": {
"computerName": "[parameters('VMName')]",
"adminUsername": "[parameters('adminUsername')]",
"adminPassword": "[parameters('adminPassword')]",
"windowsConfiguration": {
"enableAutomaticUpdates": false
}
},
"storageProfile": {
"imageReference": {
"publisher": "MicrosoftWindowsServer",
"offer": "WindowsServer",
"sku": "[parameters('WindowsSKU')]",
"version": "latest"
},
"osDisk": {
"name": "[concat(parameters('VMName'), '-os-disk')]",
"createOption": "FromImage"
}
},
"networkProfile": {
"networkInterfaces": [
{
"id": "[resourceId('Microsoft.Network/networkInterfaces', concat(parameters('VMName'), '-NIC'))]"
}
]
},
"diagnosticsProfile": {
"bootDiagnostics": {
"enabled": true,
"storageUri": "[concat('http://', variables('storageAccountName'), '.blob.core.windows.net')]"
}
}
},
"resources": [
{
"name": "[concat(parameters('VMName'), '/joindomain')]",
"type": "Microsoft.Compute/virtualMachines/extensions",
"comments": "Join domain - JsonADDomainExtension",
"apiVersion": "2016-03-30",
"location": "[resourceGroup().location]",
"dependsOn": [
"[parameters('VMName')]"
],
"tags": {
"displayName": "Join domain"
},
"properties": {
"publisher": "Microsoft.Compute",
"type": "JsonADDomainExtension",
"typeHandlerVersion": "1.3",
"autoUpgradeMinorVersion": true,
"settings": {
"Name": "[parameters('domainName')]",
"User": "[concat(parameters('adminUsername'), '@', parameters('domainName'))]",
"Restart": "true",
"Options": "3",
"OUPath": "[variables('OuPath')]"
},
"protectedSettings": {
"Password": "[parameters('adminPassword')]"
}
}
},
{
"type": "extensions",
"name": "DSCConfiguration",
"apiVersion": "2015-06-15",
"tags": {
"displayName": "DSC Configuration"
},
"location": "[resourceGroup().location]",
"dependsOn": [
"[parameters('VMName')]",
"[concat('Microsoft.Compute/virtualMachines/', parameters('VMName'), '/extensions/joindomain')]"
],
"properties": {
"publisher": "Microsoft.Powershell",
"type": "DSC",
"typeHandlerVersion": "2.20",
"autoUpgradeMinorVersion": true,
"settings": {
"configuration": {
"url": "[concat(parameters('_artifactsLocation'), '/WSConfiguration.zip')]",
"script": "WSConfiguration.ps1",
"function": "JMeter"
},
"configurationArguments": {
"artifactsLocation": "[parameters('_artifactsLocation')]"
}
},
"protectedSettings": {
"configurationUrlSasToken": "[parameters('_artifactsLocationSasToken')]",
"configurationArguments": {
"AdminCreds": {
"userName": "[concat(parameters('adminUsername'), '@', parameters('domainName'))]",
"password": "[parameters('adminPassword')]"
},
"artifactsLocationSasToken": "[parameters('_artifactsLocationSasToken')]"
}
}
}
}
]
},
{
"name": "[concat('shutdown-computevm-', parameters('VMName'))]",
"type": "Microsoft.DevTestLab/schedules",
"apiVersion": "2016-05-15",
"location": "[resourceGroup().location]",
"tags": {
"displayName": "VM AutoShutdown"
},
"dependsOn": [
"[concat('Microsoft.Compute/virtualMachines/', parameters('VMName'))]"
],
"properties": {
"status": "[parameters('AutoShutdownStatus')]",
"taskType": "ComputeVmShutdownTask",
"dailyRecurrence": {
"time": "[parameters('AutoShutdownTime')]"
},
"timeZoneId": "[parameters('AutoShutdownTimeZone')]",
"targetResourceId": "[resourceId('Microsoft.Compute/virtualMachines', parameters('VMName'))]",
"notificationSettings": {
"status": "Disabled",
"timeInMinutes": 30
}
}
}