-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathvariables.tf
More file actions
268 lines (221 loc) · 7.74 KB
/
variables.tf
File metadata and controls
268 lines (221 loc) · 7.74 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
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
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
//********************** Basic Configuration Variables **************************//
variable "subscription_id" {
description = "Subscription ID"
type = string
}
variable "tenant_id" {
description = "Tenant ID"
type = string
}
variable "client_id" {
description = "Application ID(Client ID)"
type = string
}
variable "client_secret" {
description = "A secret string that the application uses to prove its identity when requesting a token. Also can be referred to as application password."
type = string
}
variable "resource_group_name" {
description = "Azure Resource Group name to build into."
type = string
}
variable "mds_name" {
description = "MDS name."
type = string
}
variable "location" {
description = "The location/region where resource will be created. The full list of Azure regions can be found at https://azure.microsoft.com/regions."
type = string
}
variable "tags" {
description = "Assign tags by resource."
type = map(map(string))
default = {}
}
//********************** Virtual Machine Instances Variables **************************//
variable "source_image_vhd_uri" {
description = "The URI of the blob containing the development image. Please use noCustomUri if you want to use marketplace images."
type = string
default = "noCustomUri"
}
variable "admin_username" {
description = "Administrator username of deployed VM. Due to Azure limitations 'notused' name can be used."
type = string
default = "notused"
}
variable "authentication_type" {
description = "Specifies whether a password authentication or SSH Public Key authentication should be used."
type = string
}
variable "admin_password" {
description = "Administrator password of deployed Virtual Machine. The password must meet the complexity requirements of Azure."
type = string
}
variable "admin_SSH_key" {
description = "(Optional) The SSH public key for SSH authentication to the template instances."
type = string
default = ""
}
variable "sic_key" {
description = "Secure Internal Communication (SIC) key."
type = string
validation {
condition = length(var.sic_key) >= 12
error_message = "Variable [sic_key] must be at least 12 characters long."
}
}
variable "serial_console_password_hash" {
description = "Optional parameter, used to enable serial console connection in case of SSH key as authentication type."
type = string
}
variable "maintenance_mode_password_hash" {
description = "Maintenance mode password hash, relevant only for R81.20 and higher versions."
type = string
}
variable "installation_type" {
description = "Installaiton type."
type = string
default = "mds-primary"
validation {
condition = contains([
"mds-primary",
"mds-secondary",
"mds-logserver"
], var.installation_type)
error_message = "Variable [installation_type] must be one of: 'mds-primary', 'mds-secondary', 'mds-logserver'."
}
}
variable "primary" {
type = string
}
variable "secondary" {
type = string
}
variable "logserver" {
type = string
}
variable "vm_size" {
description = "Specifies size of Virtual Machine."
type = string
}
variable "disk_size" {
description = "Storage data disk size size(GB). Select a number between 100 and 3995."
type = string
}
variable "os_version" {
description = "GAIA OS version."
type = string
}
variable "vm_os_sku" {
description = "The sku of the image to be deployed."
type = string
}
variable "vm_os_offer" {
description = "The name of the image offer to be deployed.Choose from: check-point-cg-r8110, check-point-cg-r8120, check-point-cg-r82, check-point-cg-r8210."
type = string
}
variable "allow_upload_download" {
description = "Automatically download Blade Contracts and other important data. Improve product experience by sending data to Check Point."
type = bool
}
variable "admin_shell" {
description = "The admin shell to configure on machine or the first time."
type = string
default = "/etc/cli.sh"
}
variable "bootstrap_script" {
description = "An optional script to run on the initial boot."
default = ""
type = string
}
variable "zone" {
description = "The availability zone to use for the Virtual Machine. Changing this forces a new resource to be created."
type = string
default = ""
}
//********************** Networking Variables **************************//
variable "vnet_name" {
description = "Virtual Network name."
type = string
}
variable "existing_vnet_resource_group" {
description = "The name of the resource group where the Virtual Network is located. Required when using an existing Virtual Network."
type = string
default = ""
}
variable "subnet_name" {
description = "The Virtual Network subnets names."
type = string
}
variable "address_space" {
description = "The address space that is used by a Virtual Network."
type = string
default = "10.0.0.0/16"
}
variable "subnet_prefix" {
description = "Address prefix to be used for network subnet."
type = string
default = "10.0.0.0/24"
}
variable "management_GUI_client_network" {
description = "Allowed GUI clients - GUI clients network CIDR."
type = string
validation {
condition = can(regex("(^0\\.0\\.0\\.0\\/0$)|(^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/32)?$)", var.management_GUI_client_network)) && var.management_GUI_client_network != "0.0.0.0/32"
error_message = "Variable [management_GUI_client_network] must be a valid IPv4 network CIDR."
}
}
variable "mds_enable_api" {
description = "Enable api access to the management."
type = string
default = "disable"
validation {
condition = contains([
"disable",
"all",
"management_only",
"gui_clients"
], var.mds_enable_api)
error_message = "Variable [mds_enable_api] must be one of the following: 'disable', 'all', 'management_only', 'gui_clients'."
}
}
variable "nsg_id" {
description = "(Optional) The Network Security Group ID."
type = string
default = ""
}
variable "storage_account_deployment_mode" {
description = "The deployment mode for the storage account. Options are 'New', 'Existing', 'Managed' and 'None'. If 'Existing', the storage account must be specified in the variable 'existing_storage_account_id'."
type = string
default = "New"
}
variable "add_storage_account_ip_rules" {
description = "Add Storage Account IP rules that allow access to the Serial Console only for IPs based on their geographic location."
type = bool
default = false
}
variable "storage_account_additional_ips" {
description = "IPs/CIDRs that are allowed access to the Storage Account."
type = list(string)
default = []
}
variable "existing_storage_account_name" {
description = "The name of an existing storage account to use if 'storage_account_deployment_mode' is set to 'Existing'."
type = string
default = ""
}
variable "existing_storage_account_resource_group_name" {
description = "The resource group name of an existing storage account to use if 'storage_account_deployment_mode' is set to 'Existing'."
type = string
default = ""
}
variable "sku" {
description = "SKU"
type = string
default = "Standard"
}
variable "security_rules" {
description = "Security rules for the Network Security Group using this format [name, priority, direction, access, protocol, source_source_port_rangesport_range, destination_port_ranges, source_address_prefix, destination_address_prefix, description]."
type = list(any)
default = []
}