You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description="(Optional) The number of cpu units to reserve for the container. This is optional for tasks using Fargate launch type and the total amount of container_cpu of all containers in a task will need to be lower than the task-level cpu value"
43
-
default=1024# 1 vCPU
43
+
default=1024# 1 vCPU
44
44
}
45
45
46
46
variable"container_depends_on" {
47
-
type=list(string)
48
47
description="(Optional) The dependencies defined for container startup and shutdown. A container can contain multiple dependencies. When a dependency is defined for container startup, for container shutdown it is reversed"
49
-
default=null
48
+
type=list(object({
49
+
containerName =string
50
+
condition =string
51
+
}))
52
+
default=null
50
53
}
51
54
52
55
variable"container_memory" {
@@ -68,63 +71,91 @@ variable "dns_servers" {
68
71
}
69
72
70
73
variable"docker_labels" {
71
-
type=map(string)
72
74
description="(Optional) The configuration options to send to the `docker_labels`"
75
+
type=map(string)
73
76
default=null
74
77
}
75
78
76
79
variable"entrypoint" {
77
-
type=list(string)
78
80
description="(Optional) The entry point that is passed to the container"
81
+
type=list(string)
79
82
default=null
80
83
}
81
84
82
85
variable"environment" {
86
+
description="(Optional) The environment variables to pass to the container. This is a list of maps"
83
87
type=list(object({
84
88
name =string
85
89
value =string
86
90
}))
87
-
description="(Optional) The environment variables to pass to the container. This is a list of maps"
88
-
default=null
91
+
default=null
89
92
}
90
93
91
94
variable"essential" {
92
-
type=bool
93
95
description="(Optional) Determines whether all other containers in a task are stopped, if this container fails or stops for any reason. Due to how Terraform type casts booleans in json it is required to double quote this value"
description="(Optional) The FireLens configuration for the container. This is used to specify and configure a log router for container logs. For more details, see https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_FirelensConfiguration.html"
99
103
type=object({
100
104
type =string
101
105
options =map(string)
102
106
})
103
-
description="(Optional) The FireLens configuration for the container. This is used to specify and configure a log router for container logs. For more details, see https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_FirelensConfiguration.html"
description="(Optional) A map containing command (string), timeout, interval (duration in seconds), retries (1-10, number of times to retry before marking container unhealthy), and startPeriod (0-300, optional grace period to wait, in seconds, before failed healthchecks count toward retries)"
109
113
type=object({
110
114
command =list(string)
111
115
retries =number
112
116
timeout =number
113
117
interval =number
114
118
startPeriod =number
115
119
})
116
-
description="(Optional) A map containing command (string), timeout, interval (duration in seconds), retries (1-10, number of times to retry before marking container unhealthy), and startPeriod (0-300, optional grace period to wait, in seconds, before failed healthchecks count toward retries)"
117
-
default=null
120
+
default=null
118
121
}
119
122
120
123
variable"links" {
121
-
type=list(string)
122
124
description="(Optional) List of container names this container can communicate with without port mappings"
description="Linux-specific modifications that are applied to the container, such as Linux kernel capabilities. For more details, see https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_LinuxParameters.html"
description="(Optional) Log configuration options to send to a custom log driver for the container. For more details, see https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_LogConfiguration.html"
description="(Optional) Log configuration options to send to a custom log driver for the container. For more details, see https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_LogConfiguration.html"
137
-
default=null
167
+
default=null
138
168
}
139
169
140
170
variable"mount_points" {
171
+
description="(Optional) Container mount points. This is a list of maps, where each map should contain a `containerPath` and `sourceVolume`"
141
172
type=list(object({
142
173
containerPath =string
143
174
sourceVolume =string
144
175
}))
145
-
description="(Optional) Container mount points. This is a list of maps, where each map should contain a `containerPath` and `sourceVolume`"
146
-
default=null
176
+
default=null
147
177
}
148
178
149
-
locals {
150
-
port_mappings=[
179
+
variable"port_mappings" {
180
+
description="The port mappings to configure for the container. This is a list of maps. Each map should contain \"containerPort\", \"hostPort\", and \"protocol\", where \"protocol\" is one of \"tcp\" or \"udp\". If using containers in a task with the awsvpc or host network mode, the hostPort can either be left blank or set to the same value as the containerPort"
181
+
type=list(object({
182
+
containerPort =number
183
+
hostPort =number
184
+
protocol =string
185
+
}))
186
+
default=[
151
187
{
152
-
"containerPort"=var.container_port
153
-
"hostPort"=var.container_port
154
-
"protocol"="HTTP"
155
-
},
188
+
containerPort =80
189
+
hostPort =80
190
+
protocol ="tcp"
191
+
}
156
192
]
157
193
}
158
194
159
195
variable"readonly_root_filesystem" {
160
-
type=bool
161
196
description="(Optional) Determines whether a container is given read-only access to its root filesystem. Due to how Terraform type casts booleans in json it is required to double quote this value"
197
+
type=bool
162
198
default=false
163
199
}
164
200
165
201
variable"repository_credentials" {
166
-
type=map(string)
167
202
description="(Optional) 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"
203
+
type=map(string)
168
204
default=null
169
205
}
170
206
171
207
variable"secrets" {
208
+
description="(Optional) The secrets to pass to the container. This is a list of maps"
172
209
type=list(object({
173
210
name =string
174
211
valueFrom =string
175
212
}))
176
-
description="(Optional) The secrets to pass to the container. This is a list of maps"
177
-
default=null
213
+
default=null
178
214
}
179
215
180
216
variable"start_timeout" {
@@ -183,60 +219,79 @@ variable "start_timeout" {
183
219
}
184
220
185
221
variable"system_controls" {
186
-
type=list(map(string))
187
222
description="(Optional) A list of namespaced kernel parameters to set in the container, mapping to the --sysctl option to docker run. This is a list of maps: { namespace = \"\", value = \"\"}"
223
+
type=list(map(string))
188
224
default=null
189
225
}
190
226
191
227
variable"stop_timeout" {
192
-
type=number
193
228
description="(Optional) Timeout in seconds between sending SIGTERM and SIGKILL to container"
229
+
type=number
194
230
default=30
195
231
}
196
232
197
233
variable"ulimits" {
234
+
description="(Optional) Container ulimit settings. This is a list of maps, where each map should contain \"name\", \"hardLimit\" and \"softLimit\""
198
235
type=list(object({
199
236
name =string
200
237
hardLimit =number
201
238
softLimit =number
202
239
}))
203
-
description="(Optional) Container ulimit settings. This is a list of maps, where each map should contain \"name\", \"hardLimit\" and \"softLimit\""
204
-
default=null
240
+
default=null
205
241
}
206
242
207
243
variable"user" {
208
-
type=string
209
244
description="(Optional) The user to run as inside the container. Can be any of these formats: user, user:group, uid, uid:gid, user:gid, uid:group"
245
+
type=string
210
246
default=null
211
247
}
212
248
213
249
variable"volumes_from" {
250
+
description="(Optional) A list of VolumesFrom maps which contain \"sourceContainer\" (name of the container that has the volumes to mount) and \"readOnly\" (whether the container can write to the volume)"
214
251
type=list(object({
215
252
sourceContainer =string
216
253
readOnly =bool
217
254
}))
218
-
description="(Optional) A list of VolumesFrom maps which contain \"sourceContainer\" (name of the container that has the volumes to mount) and \"readOnly\" (whether the container can write to the volume)"
219
-
default=null
255
+
default=null
220
256
}
221
257
222
258
variable"working_directory" {
223
-
type=string
224
259
description="(Optional) The working directory to run commands inside the container"
description="(Optional) A set of placement constraints rules that are taken into consideration during task placement. Maximum number of placement_constraints is 10. This is a list of maps, where each map should contain \"type\" and \"expression\""
269
+
type=list
234
270
default=[]
235
271
}
236
272
237
273
variable"proxy_configuration" {
238
-
type=list
239
274
description="(Optional) The proxy configuration details for the App Mesh proxy. This is a list of maps, where each map should contain \"container_name\", \"properties\" and \"type\""
275
+
type=list
240
276
default=[]
241
277
}
242
278
279
+
variable"volumes" {
280
+
description="(Optional) A set of volume blocks that containers in your task may use"
0 commit comments