-
-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathvariables.tf
More file actions
224 lines (187 loc) · 7.13 KB
/
variables.tf
File metadata and controls
224 lines (187 loc) · 7.13 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
variable "region" {
type = string
description = "AWS region"
}
variable "create_s3_bucket" {
type = bool
description = "Enabling or disabling the creatation of an S3 bucket for AWS MWAA"
default = true
}
variable "create_iam_role" {
type = bool
description = "Enabling or disabling the creatation of a default IAM Role for AWS MWAA"
default = true
}
variable "additionals_managed_policy_arns" {
type = list(any)
description = "List of managed policies to attach to the MWAA IAM role"
default = []
}
variable "additionals_policy_documents" {
type = list(any)
description = "List of JSON IAM policy documents to attach to the MWAA IAM role"
default = []
}
variable "source_bucket_arn" {
type = string
description = "If `create_s3_bucket` is `false` then set this to the Amazon Resource Name (ARN) of your Amazon S3 storage bucket."
default = null
}
variable "execution_role_arn" {
type = string
default = ""
description = "If `create_iam_role` is `false` then set this to the target MWAA execution role"
}
variable "airflow_configuration_options" {
description = "The Airflow override options"
type = any
default = null
}
variable "airflow_version" {
type = string
description = "Airflow version of the MWAA environment, will be set by default to the latest version that MWAA supports."
default = ""
}
variable "dag_s3_path" {
type = string
description = "The relative path to the DAG folder on your Amazon S3 storage bucket."
default = "dags"
}
variable "environment_class" {
type = string
description = "Environment class for the cluster. Possible options are mw1.small, mw1.medium, mw1.large."
default = "mw1.small"
}
variable "kms_key" {
type = string
description = "The Amazon Resource Name (ARN) of your KMS key that you want to use for encryption. Will be set to the ARN of the managed KMS key aws/airflow by default."
default = null
}
variable "max_workers" {
type = number
description = "The maximum number of workers that can be automatically scaled up. Value need to be between 1 and 25."
default = 10
}
variable "min_workers" {
type = number
description = "The minimum number of workers that you want to run in your environment."
default = 1
}
variable "worker_replacement_strategy" {
type = string
description = "The worker replacement strategy to use when updating the environment. Valid values: `FORCED`, `GRACEFUL`. `FORCED` means Apache Airflow workers will be stopped and replaced without waiting for tasks to complete before an update. `GRACEFUL` means Apache Airflow workers will be able to complete running tasks for up to 12 hours during an update before being stopped and replaced."
default = null
validation {
condition = var.worker_replacement_strategy == null || contains(["FORCED", "GRACEFUL"], var.worker_replacement_strategy)
error_message = "Valid values are: `FORCED`, `GRACEFUL`, or `null`."
}
}
variable "max_webservers" {
type = number
description = "The maximum number of web servers that you want to run in your environment."
default = 2
}
variable "min_webservers" {
type = number
description = "The minimum number of web servers that you want to run in your environment."
default = 2
}
variable "schedulers" {
type = number
description = "The number of schedulers that you want to run in your environment."
default = 2
}
variable "plugins_s3_object_version" {
type = string
description = "The plugins.zip file version you want to use."
default = null
}
variable "plugins_s3_path" {
type = string
description = "The relative path to the plugins.zip file on your Amazon S3 storage bucket. For example, plugins.zip. If a relative path is provided in the request, then plugins_s3_object_version is required"
default = null
}
variable "requirements_s3_object_version" {
type = string
description = "The requirements.txt file version you"
default = null
}
variable "requirements_s3_path" {
type = string
description = "The relative path to the requirements.txt file on your Amazon S3 storage bucket. For example, requirements.txt. If a relative path is provided in the request, then requirements_s3_object_version is required"
default = null
}
variable "webserver_access_mode" {
type = string
description = "Specifies whether the webserver should be accessible over the internet or via your specified VPC. Possible options: PRIVATE_ONLY (default) and PUBLIC_ONLY."
default = "PRIVATE_ONLY"
}
variable "weekly_maintenance_window_start" {
type = string
description = "Specifies the start date for the weekly maintenance window."
default = null
}
variable "dag_processing_logs_enabled" {
type = bool
description = "Enabling or disabling the collection of logs for processing DAGs"
default = false
}
variable "dag_processing_logs_level" {
type = string
description = "DAG processing logging level. Valid values: CRITICAL, ERROR, WARNING, INFO, DEBUG"
default = "INFO"
}
variable "scheduler_logs_enabled" {
type = bool
description = "Enabling or disabling the collection of logs for the schedulers"
default = false
}
variable "scheduler_logs_level" {
type = string
description = "Schedulers logging level. Valid values: CRITICAL, ERROR, WARNING, INFO, DEBUG"
default = "INFO"
}
variable "task_logs_enabled" {
type = bool
description = "Enabling or disabling the collection of logs for DAG tasks"
default = false
}
variable "task_logs_level" {
type = string
description = "DAG tasks logging level. Valid values: CRITICAL, ERROR, WARNING, INFO, DEBUG"
default = "INFO"
}
variable "webserver_logs_enabled" {
type = bool
description = "Enabling or disabling the collection of logs for the webservers"
default = false
}
variable "webserver_logs_level" {
type = string
description = "Webserver logging level. Valid values: CRITICAL, ERROR, WARNING, INFO, DEBUG"
default = "INFO"
}
variable "worker_logs_enabled" {
type = bool
description = "Enabling or disabling the collection of logs for the workers"
default = false
}
variable "worker_logs_level" {
type = string
description = "Workers logging level. Valid values: CRITICAL, ERROR, WARNING, INFO, DEBUG"
default = "INFO"
}
variable "subnet_ids" {
type = list(string)
description = "The private subnet IDs in which the environment should be created. MWAA requires two subnets"
}
variable "startup_script_s3_path" {
type = string
description = "The relative path to the script hosted in your bucket. The script runs as your environment starts before starting the Apache Airflow process."
default = null
}
variable "startup_script_s3_object_version" {
type = string
description = "The version of the startup shell script you want to use. You must specify the version ID that Amazon S3 assigns to the file every time you update the script."
default = null
}