-
Notifications
You must be signed in to change notification settings - Fork 19
/
variables.tf
547 lines (455 loc) · 15.5 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
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
variable "region" {
type = string
description = "AWS Region for S3 bucket"
}
variable "launch_type" {
type = string
description = "The ECS launch type (valid options: FARGATE or EC2)"
default = "FARGATE"
}
variable "default_backend_image" {
type = string
default = "cloudposse/default-backend:0.1.2"
description = "ECS default (bootstrap) image"
}
variable "github_oauth_token" {
type = string
description = "GitHub OAuth token. If not provided the token is looked up from SSM"
default = ""
}
variable "github_webhooks_token" {
type = string
description = "GitHub OAuth Token with permissions to create webhooks. If not provided the token is looked up from SSM"
default = ""
}
variable "github_oauth_token_ssm_name" {
type = string
description = "SSM param name to lookup `github_oauth_token` if not provided"
default = ""
}
variable "github_webhooks_token_ssm_name" {
type = string
description = "SSM param name to lookup `github_webhooks_token` if not provided"
default = ""
}
variable "codepipeline_s3_bucket_force_destroy" {
type = bool
description = "A boolean that indicates all objects should be deleted from the CodePipeline artifact store S3 bucket so that the bucket can be destroyed without error"
default = false
}
variable "codepipeline_enabled" {
type = bool
description = "A boolean to enable/disable AWS Codepipeline and ECR"
default = false
}
variable "build_timeout" {
type = number
default = 10
description = "How long in minutes, from 5 to 480 (8 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed."
}
variable "branch" {
type = string
default = "master"
description = "Atlantis branch of the GitHub repository, _e.g._ `master`"
}
variable "repo_name" {
type = string
description = "GitHub repository name of the atlantis to be built and deployed to ECS."
}
variable "repo_owner" {
type = string
description = "GitHub organization containing the Atlantis repository"
}
variable "atlantis_repo_config" {
type = string
description = "Path to atlantis server-side repo config file (https://www.runatlantis.io/docs/server-side-repo-config.html)"
default = "atlantis-repo-config.yaml"
}
variable "atlantis_repo_whitelist" {
type = list(string)
description = "Whitelist of repositories Atlantis will accept webhooks from"
default = []
}
variable "autoscaling_enabled" {
type = bool
description = "A boolean to enable/disable Autoscaling policy for ECS Service"
default = false
}
variable "healthcheck_path" {
type = string
description = "Healthcheck path"
default = "/healthz"
}
variable "chamber_format" {
type = string
default = "/%s/%s"
description = "Format to store parameters in SSM, for consumption with chamber"
}
variable "chamber_service" {
type = string
default = "atlantis"
description = "SSM parameter service name for use with chamber. This is used in chamber_format where /$chamber_service/$parameter would be the default."
}
variable "desired_count" {
type = number
description = "Atlantis desired number of tasks"
default = 1
}
variable "short_name" {
type = string
description = "Alantis short DNS name (e.g. `atlantis`)"
default = "atlantis"
}
variable "hostname" {
type = string
description = "Atlantis URL"
default = ""
}
variable "atlantis_gh_user" {
type = string
description = "Atlantis GitHub user"
}
variable "atlantis_gh_team_whitelist" {
type = string
description = "Atlantis GitHub team whitelist"
default = ""
}
variable "atlantis_gh_webhook_secret" {
type = string
description = "Atlantis GitHub webhook secret"
default = ""
}
variable "atlantis_log_level" {
type = string
description = "Atlantis log level"
default = "info"
}
variable "atlantis_port" {
type = number
description = "Atlantis container port"
default = 4141
}
variable "atlantis_wake_word" {
type = string
description = "Wake world for atlantis"
default = "atlantis"
}
variable "atlantis_webhook_format" {
type = string
default = "https://%s/events"
description = "Template for the Atlantis webhook URL which is populated with the hostname"
}
variable "atlantis_url_format" {
type = string
default = "https://%s"
description = "Template for the Atlantis URL which is populated with the hostname"
}
variable "autoscaling_min_capacity" {
type = number
description = "Atlantis minimum tasks to run"
default = 1
}
variable "autoscaling_max_capacity" {
type = number
description = "Atlantis maximum tasks to run"
default = 1
}
variable "container_repo_credentials" {
type = map(string)
default = null
description = "Container repository credentials; required when using a private repo. This map currently supports a single key; \"credentialsParameter\", which should be the ARN of a Secrets Manager's secret holding the credentials"
}
variable "container_cpu" {
type = number
description = "Atlantis CPUs per task"
default = 256
}
variable "container_memory" {
type = number
description = "Atlantis memory per task"
default = 512
}
variable "policy_arn" {
type = string
default = "arn:aws:iam::aws:policy/AdministratorAccess"
description = "Permission to grant to atlantis server"
}
variable "kms_key_id" {
type = string
default = ""
description = "KMS key ID used to encrypt SSM SecureString parameters"
}
variable "webhook_enabled" {
type = bool
description = "Set to false to prevent the module from creating any webhook resources"
default = true
}
variable "webhook_secret_length" {
type = number
default = 32
description = "GitHub webhook secret length"
}
variable "webhook_events" {
type = list(string)
description = "A list of events which should trigger the webhook."
default = [
"issue_comment",
"pull_request",
"pull_request_review",
"pull_request_review_comment",
"push",
]
}
variable "ssh_private_key_name" {
type = string
default = "atlantis_ssh_private_key"
description = "Atlantis SSH private key name"
}
variable "ssh_public_key_name" {
type = string
default = "atlantis_ssh_public_key"
description = "Atlantis SSH public key name"
}
variable "vpc_id" {
type = string
description = "VPC ID for the ECS Cluster"
}
variable "alb_arn_suffix" {
type = string
description = "The ARN suffix of the ALB"
}
variable "use_alb_security_group" {
type = bool
description = "A flag to enable/disable adding the ingress rule to the ALB security group"
default = true
}
variable "alb_security_group" {
type = string
description = "Security group of the ALB"
}
variable "alb_target_group_alarms_alarm_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to execute when ALB Target Group alarms transition into an ALARM state from any other state."
default = []
}
variable "alb_target_group_alarms_ok_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to execute when ALB Target Group alarms transition into an OK state from any other state."
default = []
}
variable "alb_target_group_alarms_insufficient_data_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to execute when ALB Target Group alarms transition into an INSUFFICIENT_DATA state from any other state."
default = []
}
variable "ecs_alarms_cpu_utilization_high_alarm_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on CPU Utilization High Alarm action"
default = []
}
variable "ecs_alarms_cpu_utilization_high_ok_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on CPU Utilization High OK action"
default = []
}
variable "ecs_alarms_cpu_utilization_low_alarm_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on CPU Utilization Low Alarm action"
default = []
}
variable "ecs_alarms_cpu_utilization_low_ok_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on CPU Utilization Low OK action"
default = []
}
variable "ecs_alarms_memory_utilization_high_alarm_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on Memory Utilization High Alarm action"
default = []
}
variable "ecs_alarms_memory_utilization_high_ok_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on Memory Utilization High OK action"
default = []
}
variable "ecs_alarms_memory_utilization_low_alarm_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on Memory Utilization Low Alarm action"
default = []
}
variable "ecs_alarms_memory_utilization_low_ok_actions" {
type = list(string)
description = "A list of ARNs (i.e. SNS Topic ARN) to notify on Memory Utilization Low OK action"
default = []
}
variable "alb_dns_name" {
type = string
description = "DNS name of ALB"
}
variable "alb_zone_id" {
type = string
description = "The ID of the zone in which ALB is provisioned"
}
variable "ecs_cluster_name" {
type = string
description = "Name of the ECS cluster to deploy Atlantis"
}
variable "ecs_cluster_arn" {
type = string
description = "ARN of the ECS cluster to deploy Atlantis"
}
variable "security_group_ids" {
type = list(string)
default = []
description = "Additional Security Group IDs to allow into ECS Service."
}
variable "private_subnet_ids" {
type = list(string)
default = []
description = "The private subnet IDs"
}
variable "parent_zone_id" {
type = string
description = "The zone ID where the DNS record for the `short_name` will be written"
default = ""
}
variable "overwrite_ssm_parameter" {
type = bool
default = true
description = "Whether to overwrite an existing SSM parameter"
}
variable "alb_ingress_listener_unauthenticated_priority" {
type = number
default = 50
description = "The priority for the rules without authentication, between 1 and 50000 (1 being highest priority). Must be different from `alb_ingress_listener_authenticated_priority` since a listener can't have multiple rules with the same priority"
}
variable "alb_ingress_listener_authenticated_priority" {
type = number
default = 100
description = "The priority for the rules with authentication, between 1 and 50000 (1 being highest priority). Must be different from `alb_ingress_listener_unauthenticated_priority` since a listener can't have multiple rules with the same priority"
}
variable "alb_ingress_unauthenticated_hosts" {
type = list(string)
default = []
description = "Unauthenticated hosts to match in Hosts header (a maximum of 1 can be defined)"
}
variable "alb_ingress_authenticated_hosts" {
type = list(string)
default = []
description = "Authenticated hosts to match in Hosts header (a maximum of 1 can be defined)"
}
variable "alb_ingress_unauthenticated_paths" {
type = list(string)
default = ["/events"]
description = "Unauthenticated path pattern to match (a maximum of 1 can be defined)"
}
variable "alb_ingress_authenticated_paths" {
type = list(string)
default = ["/*"]
description = "Authenticated path pattern to match (a maximum of 1 can be defined)"
}
variable "alb_ingress_unauthenticated_listener_arns" {
type = list(string)
default = []
description = "A list of unauthenticated ALB listener ARNs to attach ALB listener rules to"
}
variable "alb_ingress_unauthenticated_listener_arns_count" {
type = number
default = 0
description = "The number of unauthenticated ARNs in `alb_ingress_unauthenticated_listener_arns`. This is necessary to work around a limitation in Terraform where counts cannot be computed"
}
variable "alb_ingress_authenticated_listener_arns" {
type = list(string)
default = []
description = "A list of authenticated ALB listener ARNs to attach ALB listener rules to"
}
variable "alb_ingress_authenticated_listener_arns_count" {
type = number
default = 0
description = "The number of authenticated ARNs in `alb_ingress_authenticated_listener_arns`. This is necessary to work around a limitation in Terraform where counts cannot be computed"
}
variable "authentication_type" {
type = string
default = ""
description = "Authentication type. Supported values are `COGNITO` and `OIDC`"
}
variable "authentication_cognito_user_pool_arn" {
type = string
description = "Cognito User Pool ARN"
default = ""
}
variable "authentication_cognito_user_pool_client_id" {
type = string
description = "Cognito User Pool Client ID"
default = ""
}
variable "authentication_cognito_user_pool_domain" {
type = string
description = "Cognito User Pool Domain. The User Pool Domain should be set to the domain prefix (`xxx`) instead of full domain (https://xxx.auth.us-west-2.amazoncognito.com)"
default = ""
}
variable "authentication_oidc_client_id" {
type = string
description = "OIDC Client ID"
default = ""
}
variable "authentication_oidc_client_secret" {
type = string
description = "OIDC Client Secret"
default = ""
}
variable "authentication_oidc_issuer" {
type = string
description = "OIDC Issuer"
default = ""
}
variable "authentication_oidc_authorization_endpoint" {
type = string
description = "OIDC Authorization Endpoint"
default = ""
}
variable "authentication_oidc_token_endpoint" {
type = string
description = "OIDC Token Endpoint"
default = ""
}
variable "authentication_oidc_user_info_endpoint" {
type = string
description = "OIDC User Info Endpoint"
default = ""
}
variable "authentication_cognito_user_pool_arn_ssm_name" {
type = string
description = "SSM param name to lookup `authentication_cognito_user_pool_arn` if not provided"
default = ""
}
variable "authentication_cognito_user_pool_client_id_ssm_name" {
type = string
description = "SSM param name to lookup `authentication_cognito_user_pool_client_id` if not provided"
default = ""
}
variable "authentication_cognito_user_pool_domain_ssm_name" {
type = string
description = "SSM param name to lookup `authentication_cognito_user_pool_domain` if not provided"
default = ""
}
variable "authentication_oidc_client_id_ssm_name" {
type = string
description = "SSM param name to lookup `authentication_oidc_client_id` if not provided"
default = ""
}
variable "authentication_oidc_client_secret_ssm_name" {
type = string
description = "SSM param name to lookup `authentication_oidc_client_secret` if not provided"
default = ""
}
variable "alb_target_group_alarms_enabled" {
type = bool
description = "A boolean to enable/disable CloudWatch Alarms for ALB Target metrics"
default = false
}
variable "ecs_alarms_enabled" {
type = bool
description = "A boolean to enable/disable CloudWatch Alarms for ECS Service metrics"
default = false
}