-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathvariables.tf
268 lines (219 loc) · 6.74 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
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
########################################
# General Vars
########################################
variable "name" {
description = "Moniker to apply to all resources in the module"
type = string
}
variable "tags" {
default = {}
description = "User-Defined tags"
type = map(string)
}
########################################
# Nexus Vars
########################################
variable "license_secret" {
default = ""
description = "S3 key including any prefix that has the Nexus Pro license (omit for OSS installs)"
type = string
}
variable "volume_key" {
default = "nexus-volume"
description = "This value is set to a key on the EBS volume and must be present for the nexus instance to be permitted to attach it."
type = string
}
########################################
# ASG Vars
########################################
variable "additional_ports" {
default = []
description = "Additional ports (besides 80/443 for the UI) to open on the nexus instance and create listeners for"
type = list(number)
}
variable "additional_ports_protocol" {
default = "HTTPS"
description = "Protocol [HTTP, HTTPS] to use for the additional ports"
type = string
}
variable "ami_id" {
description = "AMI to build on (must have `ansible-role-nexus` module installed)"
type = string
}
variable "asg_additional_iam_policies" {
default = []
description = "Additional IAM policies to attach to the ASG instance profile"
type = list(string)
}
variable "asg_additional_security_groups" {
default = []
description = "Additional security group IDs to attach to ASG instances"
type = list(string)
}
variable "asg_additional_target_group_arns" {
default = []
description = "ARNs of additional target groups to attach to the ASG"
type = list(string)
}
variable "asg_additional_user_data" {
default = ""
description = "Additional User Data to attach to the launch template"
type = string
}
variable "asg_desired_capacity" {
default = 1
description = "The number of Amazon EC2 instances that should be running in the group."
type = number
}
variable "asg_instance_type" {
default = "t3a.micro"
description = "Instance type for scim app"
type = string
}
variable "asg_key_name" {
default = null
description = "Optional keypair to associate with instances"
type = string
}
variable "asg_max_size" {
default = 2
description = "Maximum number of instances in the autoscaling group"
type = number
}
variable "asg_min_size" {
default = 1
description = "Minimum number of instances in the autoscaling group"
type = number
}
variable "asg_subnets" {
description = "Subnets to associate ASG instances with (specify 1 or more)"
type = list(string)
}
variable "enabled_metrics" {
description = "List of enabled metrics for the Auto Scaling Group"
type = list(string)
default = []
}
variable "additional_user_data" {
description = "Additional user data to configure the EC2 instances"
type = string
default = ""
}
########################################
# Networking Vars
########################################
variable "access_logs_bucket" {
default = null
description = "The name of the bucket to store LB access logs in. Required if `access_logs_enabled` is `true`"
type = string
}
variable "access_logs_enabled" {
default = false
description = "Whether to enable LB access logging"
type = bool
}
variable "access_logs_prefix" {
default = null
description = "The path prefix to apply to the LB access logs."
type = string
}
variable "availability_zone" {
default = null
description = "Specify the availability zone that the instance will be deployed in if using an EBS volume"
type = string
}
variable "elb_additional_sg_tags" {
default = {}
description = "Additional tags to apply to the ELB security group. Useful if you use an external process to manage ingress rules."
type = map(string)
}
variable "elb_allowed_cidr_blocks" {
default = ["0.0.0.0/0"]
description = "List of allowed CIDR blocks. If `[]` is specified, no inbound ingress rules will be created"
type = list(string)
}
variable "elb_certificate" {
description = "ARN of certificate to associate with ELB"
type = string
}
variable "elb_internal" {
default = true
description = "Create as an internal or internet-facing ELB"
type = bool
}
variable "elb_subnets" {
description = "Subnets to associate ELB to"
type = list(string)
}
variable "vpc_id" {
description = "VPC to create associated resources in"
type = string
}
########################################
# EBS Vars
########################################
variable "ebs_data_volume" {
default = false
description = "Whether to use EBS instead of EFS"
type = bool
}
variable "ebs_volume_size" {
default = 100
description = "Size of Nexus data volume in GB"
type = number
}
variable "ebs_volume_snapshot_id" {
default = ""
description = "Snapshot ID to use as source for new EBS volume"
type = string
}
########################################
# EFS Vars
########################################
variable "efs_additional_allowed_security_groups" {
default = []
description = "Additional security group IDs to attach to the EFS export"
type = list(string)
}
variable "efs_backup_retain_days" {
default = 30
description = "Days to retain EFS backups for (only used if `enable_efs_backups=true`)"
type = number
}
variable "efs_backup_schedule" {
default = "cron(0 5 ? * * *)"
description = "AWS Backup cron schedule (only used if `enable_efs_backups=true`)"
type = string
}
variable "efs_backup_vault_name" {
default = "nexus-efs-vault"
description = "AWS Backup vault name (only used if `enable_efs_backups=true`)"
type = string
}
variable "efs_subnets" {
description = "Subnets to create EFS mountpoints in"
type = list(string)
}
variable "enable_efs_backups" {
default = false
description = "Enable EFS backups using AWS Backup (recommended if you aren't going to back up EFS some other way)"
type = bool
}
########################################
# RootVolume Vars
########################################
variable "root_volume_encryption" {
default = true
description = "Encrypted root volume"
type = bool
}
variable "root_volume_size" {
default = 8
description = "Size of the root volume"
type = number
}
variable "root_volume_type" {
default = "gp3"
description = "Size of the root volume"
type = string
}