forked from Azure/terraform-azurerm-compute
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvariables.tf
244 lines (206 loc) · 7.69 KB
/
variables.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
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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
variable "resource_group_name" {
description = "The name of the resource group in which the resources will be created."
type = string
}
variable "location" {
description = "(Optional) The location in which the resources will be created."
type = string
default = ""
}
variable "vnet_subnet_id" {
description = "The subnet id of the virtual network where the virtual machines will reside."
type = string
}
variable "public_ip_dns" {
description = "Optional globally unique per datacenter region domain name label to apply to each public ip address. e.g. thisvar.varlocation.cloudapp.azure.com where you specify only thisvar here. This is an array of names which will pair up sequentially to the number of public ips defined in var.nb_public_ip. One name or empty string is required for every public ip. If no public ip is desired, then set this to an array with a single empty string."
type = list(string)
default = [null]
}
variable "admin_password" {
description = "The admin password to be used on the VMSS that will be deployed. The password must meet the complexity requirements of Azure."
type = string
default = ""
}
variable "extra_ssh_keys" {
description = "Same as ssh_key, but allows for setting multiple public keys. Set your first key in ssh_key, and the extras here."
type = list(string)
default = []
}
variable "ssh_key" {
description = "Path to the public key to be used for ssh access to the VM. Only used with non-Windows vms and can be left as-is even if using Windows vms. If specifying a path to a certification on a Windows machine to provision a linux vm use the / in the path versus backslash. e.g. c:/home/id_rsa.pub."
type = string
default = "~/.ssh/id_rsa.pub"
}
variable "ssh_key_values" {
description = "List of Public SSH Keys values to be used for ssh access to the VMs."
type = list(string)
default = []
}
variable "remote_port" {
description = "Remote tcp port to be used for access to the vms created via the nsg applied to the nics."
type = string
default = ""
}
variable "admin_username" {
description = "The admin username of the VM that will be deployed."
type = string
default = "azureuser"
}
variable "custom_data" {
description = "The custom data to supply to the machine. This can be used as a cloud-init for Linux systems."
type = string
default = ""
}
variable "storage_account_type" {
description = "Defines the type of storage account to be created. Valid options are Standard_LRS, Standard_ZRS, Standard_GRS, Standard_RAGRS, Premium_LRS."
type = string
default = "Premium_LRS"
}
variable "vm_size" {
description = "Specifies the size of the virtual machine."
type = string
default = "Standard_D2s_v3"
}
variable "nb_instances" {
description = "Specify the number of vm instances."
type = number
default = 1
}
variable "vm_hostname" {
description = "local name of the Virtual Machine."
type = string
default = "myvm"
}
variable "vm_os_simple" {
description = "Specify UbuntuServer, WindowsServer, RHEL, openSUSE-Leap, CentOS, Debian, CoreOS and SLES to get the latest image version of the specified os. Do not provide this value if a custom value is used for vm_os_publisher, vm_os_offer, and vm_os_sku."
type = string
default = ""
}
variable "vm_os_id" {
description = "The resource ID of the image that you want to deploy if you are using a custom image.Note, need to provide is_windows_image = true for windows custom images."
type = string
default = ""
}
variable "is_windows_image" {
description = "Boolean flag to notify when the custom image is windows based."
type = bool
default = false
}
variable "vm_os_publisher" {
description = "The name of the publisher of the image that you want to deploy. This is ignored when vm_os_id or vm_os_simple are provided."
type = string
default = ""
}
variable "vm_os_offer" {
description = "The name of the offer of the image that you want to deploy. This is ignored when vm_os_id or vm_os_simple are provided."
type = string
default = ""
}
variable "vm_os_sku" {
description = "The sku of the image that you want to deploy. This is ignored when vm_os_id or vm_os_simple are provided."
type = string
default = ""
}
variable "vm_os_version" {
description = "The version of the image that you want to deploy. This is ignored when vm_os_id or vm_os_simple are provided."
type = string
default = "latest"
}
variable "tags" {
description = "The tags to associate with the resources."
type = map(string)
default = {
DoNotDelete = "false"
Name = "OS Ops"
Owner = "aschenck@hashicorp.com"
TTL = 48
}
}
variable "allocation_method" {
description = "Defines how an IP address is assigned. Options are Static or Dynamic."
type = string
default = "Dynamic"
}
variable "public_ip_sku" {
description = "Defines the SKU of the Public IP. Accepted values are Basic and Standard. Defaults to Basic."
type = string
default = "Basic"
}
variable "nb_public_ip" {
description = "Number of public IPs to assign corresponding to one IP per vm. Set to 0 to not assign any public IP addresses."
type = number
default = 1
}
variable "delete_os_disk_on_termination" {
type = bool
description = "Delete datadisk when machine is terminated."
default = false
}
variable "data_sa_type" {
description = "Data Disk Storage Account type."
type = string
default = "Standard_LRS"
}
variable "data_disk_size_gb" {
description = "Storage data disk size size."
type = number
default = 30
}
variable "boot_diagnostics" {
type = bool
description = "(Optional) Enable or Disable boot diagnostics."
default = false
}
variable "boot_diagnostics_sa_type" {
description = "(Optional) Storage account type for boot diagnostics."
type = string
default = "Standard_LRS"
}
variable "enable_accelerated_networking" {
type = bool
description = "(Optional) Enable accelerated networking on Network interface."
default = false
}
variable "enable_ssh_key" {
type = bool
description = "(Optional) Enable ssh key authentication in Linux virtual Machine."
default = true
}
variable "nb_data_disk" {
description = "(Optional) Number of the data disks attached to each virtual machine."
type = number
default = 0
}
variable "source_address_prefixes" {
description = "(Optional) List of source address prefixes allowed to access var.remote_port."
type = list(string)
default = ["0.0.0.0/0"]
}
variable "license_type" {
description = "Specifies the BYOL Type for this Virtual Machine. This is only applicable to Windows Virtual Machines. Possible values are Windows_Client and Windows_Server"
type = string
default = null
}
variable "identity_type" {
description = "The Managed Service Identity Type of this Virtual Machine."
type = string
default = ""
}
variable "identity_ids" {
description = "Specifies a list of user managed identity ids to be assigned to the VM."
type = list(string)
default = []
}
variable "extra_disks" {
description = "(Optional) List of extra data disks attached to each virtual machine."
type = list(object({
name = string
size = number
}))
default = []
}
variable "os_profile_secrets" {
description = "Specifies a list of certificates to be installed on the VM, each list item is a map with the keys source_vault_id, certificate_url and certificate_store."
type = list(map(string))
default = []
}