-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserver.json
130 lines (130 loc) · 3.88 KB
/
server.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
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"nodeCount": {
"type": "int"
},
"vmSize": {
"type": "string"
},
"diskSize": {
"type": "int"
},
"adminUsername": {
"type": "string"
},
"adminPassword": {
"type": "securestring"
},
"extensionUrl": {
"type": "string"
},
"uniqueString": {
"type": "string"
}
},
"variables": {},
"resources": [
{
"type": "Microsoft.Compute/virtualMachineScaleSets",
"name": "server",
"location": "[resourceGroup().location]",
"apiVersion": "2017-03-30",
"plan": {
"publisher": "couchbase",
"product": "couchbase-server-enterprise",
"name": "byol"
},
"sku": {
"name": "[parameters('vmSize')]",
"tier": "Standard",
"capacity": "[parameters('nodeCount')]"
},
"properties": {
"overprovision": false,
"upgradePolicy": {
"mode": "Manual"
},
"virtualMachineProfile": {
"storageProfile": {
"osDisk": {
"createOption": "FromImage"
},
"imageReference": {
"publisher": "couchbase",
"offer": "couchbase-server-enterprise",
"sku": "byol",
"version": "latest"
},
"dataDisks": [
{
"lun": "0",
"createOption": "empty",
"managedDisk": {
"storageAccountType": "Premium_LRS"
},
"caching": "None",
"diskSizeGB": "[parameters('diskSize')]"
}
]
},
"osProfile": {
"computerNamePrefix": "server",
"adminUsername": "[parameters('adminUsername')]",
"adminPassword": "[parameters('adminPassword')]"
},
"networkProfile": {
"networkInterfaceConfigurations": [
{
"name": "nic",
"properties": {
"primary": "true",
"ipConfigurations": [
{
"name": "ipconfig",
"properties": {
"subnet": {
"id": "[concat(resourceId('Microsoft.Network/virtualNetworks/', 'vnet'), '/subnets/subnet')]"
},
"publicipaddressconfiguration": {
"name": "public",
"properties": {
"idleTimeoutInMinutes": 30,
"dnsSettings": {
"domainNameLabel": "[concat('server-', parameters('uniqueString'))]"
}
}
}
}
}
]
}
}
]
},
"extensionProfile": {
"extensions": [
{
"name": "extension",
"properties": {
"publisher": "Microsoft.Azure.Extensions",
"type": "CustomScript",
"typeHandlerVersion": "2.0",
"autoUpgradeMinorVersion": true,
"settings": {
"fileUris": [
"[concat(parameters('extensionUrl'), 'server.sh')]",
"[concat(parameters('extensionUrl'), 'util.sh')]"
],
"commandToExecute": "[concat('bash server.sh ', parameters('adminUsername'), ' ', parameters('adminPassword'), ' ', parameters('uniqueString'), ' ', resourceGroup().location)]"
}
}
}
]
}
}
}
}
]
}