This repository has been archived by the owner on Aug 25, 2023. It is now read-only.
generated from basisai/terraform-module-template
-
Notifications
You must be signed in to change notification settings - Fork 6
/
variables.tf
351 lines (297 loc) · 8.22 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
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
variable "release_name" {
description = "Helm release name"
type = string
default = "aws-load-balancer-controller"
}
variable "chart_name" {
description = "Helm chart name to provision"
type = string
default = "aws-load-balancer-controller"
}
variable "chart_repository" {
description = "Helm repository for the chart"
type = string
default = "https://aws.github.io/eks-charts"
}
variable "chart_version" {
description = "Version of Chart to install. Set to empty to install the latest version"
type = string
default = "1.3.2"
}
variable "chart_namespace" {
description = "Namespace to install the chart into"
type = string
default = "kube-system"
}
variable "chart_timeout" {
description = "Timeout to wait for the Chart to be deployed."
type = number
default = 300
}
variable "max_history" {
description = "Max History for Helm"
type = number
default = 20
}
########################
# Chart Values
########################
variable "replicas" {
description = "Number of replicas"
type = number
default = 1
}
variable "image_repository" {
description = "Image repository on Dockerhub"
type = string
default = "amazon/aws-alb-ingress-controller"
}
variable "prefer_ecr_repositories" {
description = "Prefer ECR repositories according to the region. If none can be found, `var.image_repository` is used"
type = bool
default = true
}
variable "image_tag" {
description = "Image tag"
type = string
default = "v2.3.0"
}
variable "name_override" {
description = "Name override for resources"
type = string
default = ""
}
variable "fullname_override" {
description = "Full name override for resources"
type = string
default = ""
}
variable "service_account_name" {
description = "Name of service account to create. Not generated"
type = string
default = "aws-load-balancer-controller"
}
variable "service_account_annotations" {
description = "Addiitional Annotations for service account"
type = map(string)
default = {}
}
variable "pod_security_context" {
description = "Pod Security Context"
type = map(any)
default = {
fsGroup = 65534
}
}
variable "security_context" {
description = "Security Context for container"
type = map(any)
default = {
readOnlyRootFilesystem = true
runAsNonRoot = true
allowPrivilegeEscalation = false
}
}
variable "termination_grace_period_seconds" {
description = "Time period for the controller pod to do a graceful shutdown"
type = number
default = 10
}
variable "resources" {
description = "Pod Resources"
type = map(any)
default = {
requests = {
cpu = "100m"
memory = "500Mi"
}
limits = {
cpu = "200m"
memory = "500Mi"
}
}
}
variable "priority_class_name" {
description = "Priority class for pod"
type = string
default = "system-cluster-critical"
}
variable "tolerations" {
description = "Pod Tolerations"
type = list(any)
default = []
}
variable "affinity" {
description = "Pod affinity"
type = map(any)
default = {}
}
variable "pod_annotations" {
description = "Additional annotations on a pod"
type = map(string)
default = {}
}
variable "pod_labels" {
description = "Additional labels on a pod"
type = map(string)
default = {}
}
variable "env" {
description = "Fixed environment variables for container"
type = map(string)
default = {}
}
variable "host_network" {
description = "Use Host Network for pod"
type = bool
default = false
}
variable "extra_volumes" {
description = "Extra volumes"
type = list(any)
default = []
}
variable "extra_volume_mounts" {
description = "Extra Volume mounts"
type = list(any)
default = []
}
variable "pdb" {
description = "PDB for pod"
type = map(any)
default = {}
}
variable "enable_cert_manager" {
description = "Enable cert-manager injection of webhook certficates"
type = bool
default = false
}
########################
# Controller Settings
########################
variable "cluster_name" {
description = "Name of Kubernetes Cluster"
type = string
}
variable "ingress_class" {
description = "The ingress class this controller will satisfy. If not specified, controller will match all ingresses without ingress class annotation and ingresses of type alb"
type = string
default = "alb"
}
variable "region" {
description = "The AWS region for the kubernetes cluster. Set to use KIAM or kube2iam for example."
type = string
default = ""
}
variable "vpc_id" {
description = "The VPC ID for the Kubernetes cluster. Set this manually when your pods are unable to use the metadata service to determine this automatically"
type = string
default = ""
}
variable "aws_max_retries" {
description = "Maximum retries for AWS APIs (default 10)"
type = number
default = 10
}
variable "enable_pod_readiness_gate_inject" {
description = "If enabled, targetHealth readiness gate will get injected to the pod spec for the matching endpoint pods (default true)"
type = bool
default = true
}
variable "enable_shield" {
description = "Enable Shield addon for ALB (default true)"
type = bool
default = true
}
variable "enable_waf" {
description = "Enable WAF addon for ALB (default true)"
type = bool
default = true
}
variable "enable_wafv2" {
description = "Enable WAF V2 addon for ALB (default true)"
type = bool
default = true
}
variable "ingress_max_concurrent_reconciles" {
description = "Maximum number of concurrently running reconcile loops for ingress (default 3)"
type = number
default = 3
}
variable "log_level" {
description = "Log level. Either `info` or `debug"
type = string
default = "info"
}
variable "metrics_bind_addr" {
description = "The address the metric endpoint binds to. (default ':8080')"
type = string
default = ":8080"
}
variable "webhook_bind_port" {
description = "The TCP port the Webhook server binds to. (default 9443)"
type = number
default = 9443
}
variable "service_max_concurrent_reconciles" {
description = "Maximum number of concurrently running reconcile loops for service (default 3)"
type = number
default = 3
}
variable "targetgroupbinding_max_concurrent_reconciles" {
description = "Maximum number of concurrently running reconcile loops for targetGroupBinding"
type = number
default = 3
}
variable "sync_period" {
description = "Period at which the controller forces the repopulation of its local object stores. (default 1h0m0s)"
type = string
default = "1h0m0s"
}
variable "watch_namespace" {
description = "Watch a single namespace if specified, or all namespaces if not"
type = string
default = ""
}
variable "default_tags" {
description = "Default tags to apply to all AWS resources managed by this controller"
type = map(string)
default = {}
}
########################
# IAM Role
########################
variable "cluster_oidc_issuer_url" {
description = "OIDC provider URL for EKS cluster"
type = string
}
variable "iam_role_name" {
description = "Name of IAM role for controller"
type = string
default = "aws-load-balancer-controller"
}
variable "iam_role_description" {
description = "Description for IAM role for controller"
type = string
default = "Used by AWS Load Balancer Controller for EKS"
}
variable "iam_role_path" {
description = "IAM Role path for controller"
type = string
default = ""
}
variable "iam_role_permission_boundary" {
description = "Permission boundary ARN for IAM Role for controller"
type = string
default = ""
}
variable "iam_role_tags" {
description = "Tags for IAM Role for controller"
type = map(string)
default = {}
}
variable "iam_role_policy" {
description = "Override the IAM policy for the controller"
type = string
default = ""
}