must-cdk 0.0.7__py3-none-any.whl → 0.0.8__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
must_cdk/__init__.py CHANGED
@@ -33,18 +33,451 @@ def check_type(argname: str, value: object, expected_type: typing.Any) -> typing
33
33
 
34
34
  from ._jsii import *
35
35
 
36
+ import aws_cdk as _aws_cdk_ceddda9d
36
37
  import aws_cdk.aws_apigateway as _aws_cdk_aws_apigateway_ceddda9d
37
38
  import aws_cdk.aws_certificatemanager as _aws_cdk_aws_certificatemanager_ceddda9d
39
+ import aws_cdk.aws_cloudwatch as _aws_cdk_aws_cloudwatch_ceddda9d
40
+ import aws_cdk.aws_codedeploy as _aws_cdk_aws_codedeploy_ceddda9d
38
41
  import aws_cdk.aws_ec2 as _aws_cdk_aws_ec2_ceddda9d
39
42
  import aws_cdk.aws_ecs as _aws_cdk_aws_ecs_ceddda9d
43
+ import aws_cdk.aws_ecs_patterns as _aws_cdk_aws_ecs_patterns_ceddda9d
40
44
  import aws_cdk.aws_elasticloadbalancingv2 as _aws_cdk_aws_elasticloadbalancingv2_ceddda9d
41
45
  import aws_cdk.aws_iam as _aws_cdk_aws_iam_ceddda9d
42
46
  import aws_cdk.aws_lambda as _aws_cdk_aws_lambda_ceddda9d
43
47
  import aws_cdk.aws_logs as _aws_cdk_aws_logs_ceddda9d
44
48
  import aws_cdk.aws_route53 as _aws_cdk_aws_route53_ceddda9d
49
+ import aws_cdk.aws_s3 as _aws_cdk_aws_s3_ceddda9d
50
+ import aws_cdk.aws_synthetics as _aws_cdk_aws_synthetics_ceddda9d
45
51
  import constructs as _constructs_77d1e7e8
46
52
 
47
53
 
54
+ class ApiCanary(
55
+ _aws_cdk_aws_synthetics_ceddda9d.Canary,
56
+ metaclass=jsii.JSIIMeta,
57
+ jsii_type="must-cdk.ApiCanary",
58
+ ):
59
+ '''A CloudWatch Synthetic Canary for monitoring APIs.'''
60
+
61
+ def __init__(
62
+ self,
63
+ scope: _constructs_77d1e7e8.Construct,
64
+ id: builtins.str,
65
+ *,
66
+ base_url: builtins.str,
67
+ artifacts_bucket_location: typing.Optional[typing.Union[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation, typing.Dict[builtins.str, typing.Any]]] = None,
68
+ canary_name: typing.Optional[builtins.str] = None,
69
+ duration_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
70
+ failure_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
71
+ role: typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole] = None,
72
+ schedule: typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule] = None,
73
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
74
+ start_after_creation: typing.Optional[builtins.bool] = None,
75
+ steps: typing.Optional[typing.Sequence[typing.Union["ApiTestStep", typing.Dict[builtins.str, typing.Any]]]] = None,
76
+ success_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
77
+ thread_count: typing.Optional[jsii.Number] = None,
78
+ time_to_live: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
79
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
80
+ vpc_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
81
+ ) -> None:
82
+ '''
83
+ :param scope: -
84
+ :param id: -
85
+ :param base_url: The base URL to use for tests.
86
+ :param artifacts_bucket_location: The s3 location that stores the data of the canary runs. Default: - A new s3 bucket will be created without a prefix.
87
+ :param canary_name: The name of the canary. Be sure to give it a descriptive name that distinguishes it from other canaries in your account. Do not include secrets or proprietary information in your canary name. The canary name makes up part of the canary ARN, which is included in outbound calls over the internet. Default: - A unique name will be generated from the construct ID
88
+ :param duration_alarm_threshold: The threshold for triggering an alarm on the test duration. Default: - no alarm is created for duration
89
+ :param failure_retention_period: How many days should failed runs be retained. Default: Duration.days(31)
90
+ :param role: Canary execution role. This is the role that will be assumed by the canary upon execution. It controls the permissions that the canary will have. The role must be assumable by the AWS Lambda service principal. If not supplied, a role will be created with all the required permissions. If you provide a Role, you must add the required permissions. Default: - A unique role will be generated for this canary. You can add permissions to roles by calling 'addToRolePolicy'.
91
+ :param schedule: Specify the schedule for how often the canary runs. For example, if you set ``schedule`` to ``rate(10 minutes)``, then the canary will run every 10 minutes. You can set the schedule with ``Schedule.rate(Duration)`` (recommended) or you can specify an expression using ``Schedule.expression()``. Default: 'rate(5 minutes)'
92
+ :param security_groups: The list of security groups to associate with the canary's network interfaces. You must provide ``vpc`` when using this prop. Default: - If the canary is placed within a VPC and a security group is not specified a dedicated security group will be created for this canary.
93
+ :param start_after_creation: Whether or not the canary should start after creation. Default: true
94
+ :param steps: The steps to perform in the synthetic test.
95
+ :param success_retention_period: How many days should successful runs be retained. Default: Duration.days(31)
96
+ :param thread_count: The number of threads to run concurrently for the synthetic test. Default: - 20
97
+ :param time_to_live: How long the canary will be in a 'RUNNING' state. For example, if you set ``timeToLive`` to be 1 hour and ``schedule`` to be ``rate(10 minutes)``, your canary will run at 10 minute intervals for an hour, for a total of 6 times. Default: - no limit
98
+ :param vpc: The VPC where this canary is run. Specify this if the canary needs to access resources in a VPC. Default: - Not in VPC
99
+ :param vpc_subnets: Where to place the network interfaces within the VPC. You must provide ``vpc`` when using this prop. Default: - the Vpc default strategy if not specified
100
+ '''
101
+ if __debug__:
102
+ type_hints = typing.get_type_hints(_typecheckingstub__09d06c1c95daaaf23d076abac602f3a69682f6d183c18d319586c4a3ad15e539)
103
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
104
+ check_type(argname="argument id", value=id, expected_type=type_hints["id"])
105
+ props = ApiCanaryProps(
106
+ base_url=base_url,
107
+ artifacts_bucket_location=artifacts_bucket_location,
108
+ canary_name=canary_name,
109
+ duration_alarm_threshold=duration_alarm_threshold,
110
+ failure_retention_period=failure_retention_period,
111
+ role=role,
112
+ schedule=schedule,
113
+ security_groups=security_groups,
114
+ start_after_creation=start_after_creation,
115
+ steps=steps,
116
+ success_retention_period=success_retention_period,
117
+ thread_count=thread_count,
118
+ time_to_live=time_to_live,
119
+ vpc=vpc,
120
+ vpc_subnets=vpc_subnets,
121
+ )
122
+
123
+ jsii.create(self.__class__, self, [scope, id, props])
124
+
125
+ @jsii.member(jsii_name="addTestStep")
126
+ def add_test_step(
127
+ self,
128
+ *,
129
+ name: builtins.str,
130
+ path: builtins.str,
131
+ body: typing.Optional[builtins.str] = None,
132
+ expected_value: typing.Any = None,
133
+ headers: typing.Optional[typing.Mapping[builtins.str, builtins.str]] = None,
134
+ jmes_path: typing.Optional[builtins.str] = None,
135
+ method: typing.Optional[builtins.str] = None,
136
+ ) -> None:
137
+ '''Add a new test step to this canary.
138
+
139
+ :param name: Name of test.
140
+ :param path: Path of HTTP request, relative to baseUrl.
141
+ :param body: Optional body to include in HTTP request. Default: - no body included.
142
+ :param expected_value: Expected value to compare against the jmesPath. Default: - undefined
143
+ :param headers: Optional headers to include in HTTP request. Default: - no headers included.
144
+ :param jmes_path: JMESPath to apply against the response from the HTTP request and compare against expected value. Default: - no JMESPath assertion will be performed.
145
+ :param method: Optional method to for HTTP request. Default: - GET
146
+ '''
147
+ step = ApiTestStep(
148
+ name=name,
149
+ path=path,
150
+ body=body,
151
+ expected_value=expected_value,
152
+ headers=headers,
153
+ jmes_path=jmes_path,
154
+ method=method,
155
+ )
156
+
157
+ return typing.cast(None, jsii.invoke(self, "addTestStep", [step]))
158
+
159
+ @builtins.property
160
+ @jsii.member(jsii_name="successAlarm")
161
+ def success_alarm(self) -> _aws_cdk_aws_cloudwatch_ceddda9d.Alarm:
162
+ '''A CloudWatch Alarm that triggers when the success rate falls below 100% over the past 2 periods.'''
163
+ return typing.cast(_aws_cdk_aws_cloudwatch_ceddda9d.Alarm, jsii.get(self, "successAlarm"))
164
+
165
+ @success_alarm.setter
166
+ def success_alarm(self, value: _aws_cdk_aws_cloudwatch_ceddda9d.Alarm) -> None:
167
+ if __debug__:
168
+ type_hints = typing.get_type_hints(_typecheckingstub__8725a15a28149bfb608a400e26cfbe5e4841d0766e308d94bd820bae8ef15018)
169
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
170
+ jsii.set(self, "successAlarm", value) # pyright: ignore[reportArgumentType]
171
+
172
+ @builtins.property
173
+ @jsii.member(jsii_name="durationAlarm")
174
+ def duration_alarm(self) -> typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.Alarm]:
175
+ '''A CloudWatch Alarm that triggers when the duration of the tests exceeds the given threshold over the past 2 periods.'''
176
+ return typing.cast(typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.Alarm], jsii.get(self, "durationAlarm"))
177
+
178
+ @duration_alarm.setter
179
+ def duration_alarm(
180
+ self,
181
+ value: typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.Alarm],
182
+ ) -> None:
183
+ if __debug__:
184
+ type_hints = typing.get_type_hints(_typecheckingstub__5e693bebe82a00de7c7762fadb1e226601529313a62b3e1a2a8527584ea39940)
185
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
186
+ jsii.set(self, "durationAlarm", value) # pyright: ignore[reportArgumentType]
187
+
188
+
189
+ @jsii.data_type(
190
+ jsii_type="must-cdk.ApiCanaryProps",
191
+ jsii_struct_bases=[],
192
+ name_mapping={
193
+ "base_url": "baseUrl",
194
+ "artifacts_bucket_location": "artifactsBucketLocation",
195
+ "canary_name": "canaryName",
196
+ "duration_alarm_threshold": "durationAlarmThreshold",
197
+ "failure_retention_period": "failureRetentionPeriod",
198
+ "role": "role",
199
+ "schedule": "schedule",
200
+ "security_groups": "securityGroups",
201
+ "start_after_creation": "startAfterCreation",
202
+ "steps": "steps",
203
+ "success_retention_period": "successRetentionPeriod",
204
+ "thread_count": "threadCount",
205
+ "time_to_live": "timeToLive",
206
+ "vpc": "vpc",
207
+ "vpc_subnets": "vpcSubnets",
208
+ },
209
+ )
210
+ class ApiCanaryProps:
211
+ def __init__(
212
+ self,
213
+ *,
214
+ base_url: builtins.str,
215
+ artifacts_bucket_location: typing.Optional[typing.Union[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation, typing.Dict[builtins.str, typing.Any]]] = None,
216
+ canary_name: typing.Optional[builtins.str] = None,
217
+ duration_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
218
+ failure_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
219
+ role: typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole] = None,
220
+ schedule: typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule] = None,
221
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
222
+ start_after_creation: typing.Optional[builtins.bool] = None,
223
+ steps: typing.Optional[typing.Sequence[typing.Union["ApiTestStep", typing.Dict[builtins.str, typing.Any]]]] = None,
224
+ success_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
225
+ thread_count: typing.Optional[jsii.Number] = None,
226
+ time_to_live: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
227
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
228
+ vpc_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
229
+ ) -> None:
230
+ '''
231
+ :param base_url: The base URL to use for tests.
232
+ :param artifacts_bucket_location: The s3 location that stores the data of the canary runs. Default: - A new s3 bucket will be created without a prefix.
233
+ :param canary_name: The name of the canary. Be sure to give it a descriptive name that distinguishes it from other canaries in your account. Do not include secrets or proprietary information in your canary name. The canary name makes up part of the canary ARN, which is included in outbound calls over the internet. Default: - A unique name will be generated from the construct ID
234
+ :param duration_alarm_threshold: The threshold for triggering an alarm on the test duration. Default: - no alarm is created for duration
235
+ :param failure_retention_period: How many days should failed runs be retained. Default: Duration.days(31)
236
+ :param role: Canary execution role. This is the role that will be assumed by the canary upon execution. It controls the permissions that the canary will have. The role must be assumable by the AWS Lambda service principal. If not supplied, a role will be created with all the required permissions. If you provide a Role, you must add the required permissions. Default: - A unique role will be generated for this canary. You can add permissions to roles by calling 'addToRolePolicy'.
237
+ :param schedule: Specify the schedule for how often the canary runs. For example, if you set ``schedule`` to ``rate(10 minutes)``, then the canary will run every 10 minutes. You can set the schedule with ``Schedule.rate(Duration)`` (recommended) or you can specify an expression using ``Schedule.expression()``. Default: 'rate(5 minutes)'
238
+ :param security_groups: The list of security groups to associate with the canary's network interfaces. You must provide ``vpc`` when using this prop. Default: - If the canary is placed within a VPC and a security group is not specified a dedicated security group will be created for this canary.
239
+ :param start_after_creation: Whether or not the canary should start after creation. Default: true
240
+ :param steps: The steps to perform in the synthetic test.
241
+ :param success_retention_period: How many days should successful runs be retained. Default: Duration.days(31)
242
+ :param thread_count: The number of threads to run concurrently for the synthetic test. Default: - 20
243
+ :param time_to_live: How long the canary will be in a 'RUNNING' state. For example, if you set ``timeToLive`` to be 1 hour and ``schedule`` to be ``rate(10 minutes)``, your canary will run at 10 minute intervals for an hour, for a total of 6 times. Default: - no limit
244
+ :param vpc: The VPC where this canary is run. Specify this if the canary needs to access resources in a VPC. Default: - Not in VPC
245
+ :param vpc_subnets: Where to place the network interfaces within the VPC. You must provide ``vpc`` when using this prop. Default: - the Vpc default strategy if not specified
246
+ '''
247
+ if isinstance(artifacts_bucket_location, dict):
248
+ artifacts_bucket_location = _aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation(**artifacts_bucket_location)
249
+ if isinstance(vpc_subnets, dict):
250
+ vpc_subnets = _aws_cdk_aws_ec2_ceddda9d.SubnetSelection(**vpc_subnets)
251
+ if __debug__:
252
+ type_hints = typing.get_type_hints(_typecheckingstub__b52b092204732a9d7b4031c2682b2facb0ffa90d719105c9d03ed168de7472f0)
253
+ check_type(argname="argument base_url", value=base_url, expected_type=type_hints["base_url"])
254
+ check_type(argname="argument artifacts_bucket_location", value=artifacts_bucket_location, expected_type=type_hints["artifacts_bucket_location"])
255
+ check_type(argname="argument canary_name", value=canary_name, expected_type=type_hints["canary_name"])
256
+ check_type(argname="argument duration_alarm_threshold", value=duration_alarm_threshold, expected_type=type_hints["duration_alarm_threshold"])
257
+ check_type(argname="argument failure_retention_period", value=failure_retention_period, expected_type=type_hints["failure_retention_period"])
258
+ check_type(argname="argument role", value=role, expected_type=type_hints["role"])
259
+ check_type(argname="argument schedule", value=schedule, expected_type=type_hints["schedule"])
260
+ check_type(argname="argument security_groups", value=security_groups, expected_type=type_hints["security_groups"])
261
+ check_type(argname="argument start_after_creation", value=start_after_creation, expected_type=type_hints["start_after_creation"])
262
+ check_type(argname="argument steps", value=steps, expected_type=type_hints["steps"])
263
+ check_type(argname="argument success_retention_period", value=success_retention_period, expected_type=type_hints["success_retention_period"])
264
+ check_type(argname="argument thread_count", value=thread_count, expected_type=type_hints["thread_count"])
265
+ check_type(argname="argument time_to_live", value=time_to_live, expected_type=type_hints["time_to_live"])
266
+ check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
267
+ check_type(argname="argument vpc_subnets", value=vpc_subnets, expected_type=type_hints["vpc_subnets"])
268
+ self._values: typing.Dict[builtins.str, typing.Any] = {
269
+ "base_url": base_url,
270
+ }
271
+ if artifacts_bucket_location is not None:
272
+ self._values["artifacts_bucket_location"] = artifacts_bucket_location
273
+ if canary_name is not None:
274
+ self._values["canary_name"] = canary_name
275
+ if duration_alarm_threshold is not None:
276
+ self._values["duration_alarm_threshold"] = duration_alarm_threshold
277
+ if failure_retention_period is not None:
278
+ self._values["failure_retention_period"] = failure_retention_period
279
+ if role is not None:
280
+ self._values["role"] = role
281
+ if schedule is not None:
282
+ self._values["schedule"] = schedule
283
+ if security_groups is not None:
284
+ self._values["security_groups"] = security_groups
285
+ if start_after_creation is not None:
286
+ self._values["start_after_creation"] = start_after_creation
287
+ if steps is not None:
288
+ self._values["steps"] = steps
289
+ if success_retention_period is not None:
290
+ self._values["success_retention_period"] = success_retention_period
291
+ if thread_count is not None:
292
+ self._values["thread_count"] = thread_count
293
+ if time_to_live is not None:
294
+ self._values["time_to_live"] = time_to_live
295
+ if vpc is not None:
296
+ self._values["vpc"] = vpc
297
+ if vpc_subnets is not None:
298
+ self._values["vpc_subnets"] = vpc_subnets
299
+
300
+ @builtins.property
301
+ def base_url(self) -> builtins.str:
302
+ '''The base URL to use for tests.'''
303
+ result = self._values.get("base_url")
304
+ assert result is not None, "Required property 'base_url' is missing"
305
+ return typing.cast(builtins.str, result)
306
+
307
+ @builtins.property
308
+ def artifacts_bucket_location(
309
+ self,
310
+ ) -> typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation]:
311
+ '''The s3 location that stores the data of the canary runs.
312
+
313
+ :default: - A new s3 bucket will be created without a prefix.
314
+ '''
315
+ result = self._values.get("artifacts_bucket_location")
316
+ return typing.cast(typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation], result)
317
+
318
+ @builtins.property
319
+ def canary_name(self) -> typing.Optional[builtins.str]:
320
+ '''The name of the canary.
321
+
322
+ Be sure to give it a descriptive name that distinguishes it from
323
+ other canaries in your account.
324
+
325
+ Do not include secrets or proprietary information in your canary name. The canary name
326
+ makes up part of the canary ARN, which is included in outbound calls over the internet.
327
+
328
+ :default: - A unique name will be generated from the construct ID
329
+
330
+ :see: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/servicelens_canaries_security.html
331
+ '''
332
+ result = self._values.get("canary_name")
333
+ return typing.cast(typing.Optional[builtins.str], result)
334
+
335
+ @builtins.property
336
+ def duration_alarm_threshold(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
337
+ '''The threshold for triggering an alarm on the test duration.
338
+
339
+ :default: - no alarm is created for duration
340
+ '''
341
+ result = self._values.get("duration_alarm_threshold")
342
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
343
+
344
+ @builtins.property
345
+ def failure_retention_period(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
346
+ '''How many days should failed runs be retained.
347
+
348
+ :default: Duration.days(31)
349
+ '''
350
+ result = self._values.get("failure_retention_period")
351
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
352
+
353
+ @builtins.property
354
+ def role(self) -> typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole]:
355
+ '''Canary execution role.
356
+
357
+ This is the role that will be assumed by the canary upon execution.
358
+ It controls the permissions that the canary will have. The role must
359
+ be assumable by the AWS Lambda service principal.
360
+
361
+ If not supplied, a role will be created with all the required permissions.
362
+ If you provide a Role, you must add the required permissions.
363
+
364
+ :default:
365
+
366
+ - A unique role will be generated for this canary.
367
+ You can add permissions to roles by calling 'addToRolePolicy'.
368
+
369
+ :see: required permissions: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-synthetics-canary.html#cfn-synthetics-canary-executionrolearn
370
+ '''
371
+ result = self._values.get("role")
372
+ return typing.cast(typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole], result)
373
+
374
+ @builtins.property
375
+ def schedule(self) -> typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule]:
376
+ '''Specify the schedule for how often the canary runs.
377
+
378
+ For example, if you set ``schedule`` to ``rate(10 minutes)``, then the canary will run every 10 minutes.
379
+ You can set the schedule with ``Schedule.rate(Duration)`` (recommended) or you can specify an expression using ``Schedule.expression()``.
380
+
381
+ :default: 'rate(5 minutes)'
382
+ '''
383
+ result = self._values.get("schedule")
384
+ return typing.cast(typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule], result)
385
+
386
+ @builtins.property
387
+ def security_groups(
388
+ self,
389
+ ) -> typing.Optional[typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]]:
390
+ '''The list of security groups to associate with the canary's network interfaces.
391
+
392
+ You must provide ``vpc`` when using this prop.
393
+
394
+ :default:
395
+
396
+ - If the canary is placed within a VPC and a security group is
397
+ not specified a dedicated security group will be created for this canary.
398
+ '''
399
+ result = self._values.get("security_groups")
400
+ return typing.cast(typing.Optional[typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]], result)
401
+
402
+ @builtins.property
403
+ def start_after_creation(self) -> typing.Optional[builtins.bool]:
404
+ '''Whether or not the canary should start after creation.
405
+
406
+ :default: true
407
+ '''
408
+ result = self._values.get("start_after_creation")
409
+ return typing.cast(typing.Optional[builtins.bool], result)
410
+
411
+ @builtins.property
412
+ def steps(self) -> typing.Optional[typing.List["ApiTestStep"]]:
413
+ '''The steps to perform in the synthetic test.'''
414
+ result = self._values.get("steps")
415
+ return typing.cast(typing.Optional[typing.List["ApiTestStep"]], result)
416
+
417
+ @builtins.property
418
+ def success_retention_period(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
419
+ '''How many days should successful runs be retained.
420
+
421
+ :default: Duration.days(31)
422
+ '''
423
+ result = self._values.get("success_retention_period")
424
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
425
+
426
+ @builtins.property
427
+ def thread_count(self) -> typing.Optional[jsii.Number]:
428
+ '''The number of threads to run concurrently for the synthetic test.
429
+
430
+ :default: - 20
431
+ '''
432
+ result = self._values.get("thread_count")
433
+ return typing.cast(typing.Optional[jsii.Number], result)
434
+
435
+ @builtins.property
436
+ def time_to_live(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
437
+ '''How long the canary will be in a 'RUNNING' state.
438
+
439
+ For example, if you set ``timeToLive`` to be 1 hour and ``schedule`` to be ``rate(10 minutes)``,
440
+ your canary will run at 10 minute intervals for an hour, for a total of 6 times.
441
+
442
+ :default: - no limit
443
+ '''
444
+ result = self._values.get("time_to_live")
445
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
446
+
447
+ @builtins.property
448
+ def vpc(self) -> typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc]:
449
+ '''The VPC where this canary is run.
450
+
451
+ Specify this if the canary needs to access resources in a VPC.
452
+
453
+ :default: - Not in VPC
454
+ '''
455
+ result = self._values.get("vpc")
456
+ return typing.cast(typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc], result)
457
+
458
+ @builtins.property
459
+ def vpc_subnets(self) -> typing.Optional[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection]:
460
+ '''Where to place the network interfaces within the VPC.
461
+
462
+ You must provide ``vpc`` when using this prop.
463
+
464
+ :default: - the Vpc default strategy if not specified
465
+ '''
466
+ result = self._values.get("vpc_subnets")
467
+ return typing.cast(typing.Optional[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection], result)
468
+
469
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
470
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
471
+
472
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
473
+ return not (rhs == self)
474
+
475
+ def __repr__(self) -> str:
476
+ return "ApiCanaryProps(%s)" % ", ".join(
477
+ k + "=" + repr(v) for k, v in self._values.items()
478
+ )
479
+
480
+
48
481
  class ApiGatewayToLambdaCustomDomain(
49
482
  _constructs_77d1e7e8.Construct,
50
483
  metaclass=jsii.JSIIMeta,
@@ -219,43 +652,1700 @@ class ApiGatewayToLambdaProps:
219
652
 
220
653
  :default: - no custom domain
221
654
  '''
222
- result = self._values.get("custom_domain_name")
223
- return typing.cast(typing.Optional[builtins.str], result)
655
+ result = self._values.get("custom_domain_name")
656
+ return typing.cast(typing.Optional[builtins.str], result)
657
+
658
+ @builtins.property
659
+ def existing_lambda_obj(
660
+ self,
661
+ ) -> typing.Optional[_aws_cdk_aws_lambda_ceddda9d.Function]:
662
+ '''Existing instance of Lambda Function object, providing both this and ``lambdaFunctionProps`` will cause an error.
663
+
664
+ :default: - None
665
+ '''
666
+ result = self._values.get("existing_lambda_obj")
667
+ return typing.cast(typing.Optional[_aws_cdk_aws_lambda_ceddda9d.Function], result)
668
+
669
+ @builtins.property
670
+ def hosted_zone(self) -> typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone]:
671
+ '''Optional Route53 hosted zone to create alias record for the custom domain.
672
+
673
+ :default: - no Route53 alias record created
674
+ '''
675
+ result = self._values.get("hosted_zone")
676
+ return typing.cast(typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone], result)
677
+
678
+ @builtins.property
679
+ def lambda_function_props(
680
+ self,
681
+ ) -> typing.Optional[_aws_cdk_aws_lambda_ceddda9d.FunctionProps]:
682
+ '''User provided props to override the default props for the Lambda function.'''
683
+ result = self._values.get("lambda_function_props")
684
+ return typing.cast(typing.Optional[_aws_cdk_aws_lambda_ceddda9d.FunctionProps], result)
685
+
686
+ @builtins.property
687
+ def log_group_props(
688
+ self,
689
+ ) -> typing.Optional[_aws_cdk_aws_logs_ceddda9d.LogGroupProps]:
690
+ result = self._values.get("log_group_props")
691
+ return typing.cast(typing.Optional[_aws_cdk_aws_logs_ceddda9d.LogGroupProps], result)
692
+
693
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
694
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
695
+
696
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
697
+ return not (rhs == self)
698
+
699
+ def __repr__(self) -> str:
700
+ return "ApiGatewayToLambdaProps(%s)" % ", ".join(
701
+ k + "=" + repr(v) for k, v in self._values.items()
702
+ )
703
+
704
+
705
+ @jsii.data_type(
706
+ jsii_type="must-cdk.ApiTestStep",
707
+ jsii_struct_bases=[],
708
+ name_mapping={
709
+ "name": "name",
710
+ "path": "path",
711
+ "body": "body",
712
+ "expected_value": "expectedValue",
713
+ "headers": "headers",
714
+ "jmes_path": "jmesPath",
715
+ "method": "method",
716
+ },
717
+ )
718
+ class ApiTestStep:
719
+ def __init__(
720
+ self,
721
+ *,
722
+ name: builtins.str,
723
+ path: builtins.str,
724
+ body: typing.Optional[builtins.str] = None,
725
+ expected_value: typing.Any = None,
726
+ headers: typing.Optional[typing.Mapping[builtins.str, builtins.str]] = None,
727
+ jmes_path: typing.Optional[builtins.str] = None,
728
+ method: typing.Optional[builtins.str] = None,
729
+ ) -> None:
730
+ '''
731
+ :param name: Name of test.
732
+ :param path: Path of HTTP request, relative to baseUrl.
733
+ :param body: Optional body to include in HTTP request. Default: - no body included.
734
+ :param expected_value: Expected value to compare against the jmesPath. Default: - undefined
735
+ :param headers: Optional headers to include in HTTP request. Default: - no headers included.
736
+ :param jmes_path: JMESPath to apply against the response from the HTTP request and compare against expected value. Default: - no JMESPath assertion will be performed.
737
+ :param method: Optional method to for HTTP request. Default: - GET
738
+ '''
739
+ if __debug__:
740
+ type_hints = typing.get_type_hints(_typecheckingstub__171a53d32e45dddc3d74e9b9e98d60f757ac6028bcc531de07738ff4251515ed)
741
+ check_type(argname="argument name", value=name, expected_type=type_hints["name"])
742
+ check_type(argname="argument path", value=path, expected_type=type_hints["path"])
743
+ check_type(argname="argument body", value=body, expected_type=type_hints["body"])
744
+ check_type(argname="argument expected_value", value=expected_value, expected_type=type_hints["expected_value"])
745
+ check_type(argname="argument headers", value=headers, expected_type=type_hints["headers"])
746
+ check_type(argname="argument jmes_path", value=jmes_path, expected_type=type_hints["jmes_path"])
747
+ check_type(argname="argument method", value=method, expected_type=type_hints["method"])
748
+ self._values: typing.Dict[builtins.str, typing.Any] = {
749
+ "name": name,
750
+ "path": path,
751
+ }
752
+ if body is not None:
753
+ self._values["body"] = body
754
+ if expected_value is not None:
755
+ self._values["expected_value"] = expected_value
756
+ if headers is not None:
757
+ self._values["headers"] = headers
758
+ if jmes_path is not None:
759
+ self._values["jmes_path"] = jmes_path
760
+ if method is not None:
761
+ self._values["method"] = method
762
+
763
+ @builtins.property
764
+ def name(self) -> builtins.str:
765
+ '''Name of test.'''
766
+ result = self._values.get("name")
767
+ assert result is not None, "Required property 'name' is missing"
768
+ return typing.cast(builtins.str, result)
769
+
770
+ @builtins.property
771
+ def path(self) -> builtins.str:
772
+ '''Path of HTTP request, relative to baseUrl.'''
773
+ result = self._values.get("path")
774
+ assert result is not None, "Required property 'path' is missing"
775
+ return typing.cast(builtins.str, result)
776
+
777
+ @builtins.property
778
+ def body(self) -> typing.Optional[builtins.str]:
779
+ '''Optional body to include in HTTP request.
780
+
781
+ :default: - no body included.
782
+ '''
783
+ result = self._values.get("body")
784
+ return typing.cast(typing.Optional[builtins.str], result)
785
+
786
+ @builtins.property
787
+ def expected_value(self) -> typing.Any:
788
+ '''Expected value to compare against the jmesPath.
789
+
790
+ :default: - undefined
791
+ '''
792
+ result = self._values.get("expected_value")
793
+ return typing.cast(typing.Any, result)
794
+
795
+ @builtins.property
796
+ def headers(self) -> typing.Optional[typing.Mapping[builtins.str, builtins.str]]:
797
+ '''Optional headers to include in HTTP request.
798
+
799
+ :default: - no headers included.
800
+ '''
801
+ result = self._values.get("headers")
802
+ return typing.cast(typing.Optional[typing.Mapping[builtins.str, builtins.str]], result)
803
+
804
+ @builtins.property
805
+ def jmes_path(self) -> typing.Optional[builtins.str]:
806
+ '''JMESPath to apply against the response from the HTTP request and compare against expected value.
807
+
808
+ :default: - no JMESPath assertion will be performed.
809
+ '''
810
+ result = self._values.get("jmes_path")
811
+ return typing.cast(typing.Optional[builtins.str], result)
812
+
813
+ @builtins.property
814
+ def method(self) -> typing.Optional[builtins.str]:
815
+ '''Optional method to for HTTP request.
816
+
817
+ :default: - GET
818
+ '''
819
+ result = self._values.get("method")
820
+ return typing.cast(typing.Optional[builtins.str], result)
821
+
822
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
823
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
824
+
825
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
826
+ return not (rhs == self)
827
+
828
+ def __repr__(self) -> str:
829
+ return "ApiTestStep(%s)" % ", ".join(
830
+ k + "=" + repr(v) for k, v in self._values.items()
831
+ )
832
+
833
+
834
+ @jsii.data_type(
835
+ jsii_type="must-cdk.AppSpecHooks",
836
+ jsii_struct_bases=[],
837
+ name_mapping={
838
+ "after_allow_test_traffic": "afterAllowTestTraffic",
839
+ "after_allow_traffic": "afterAllowTraffic",
840
+ "after_install": "afterInstall",
841
+ "before_allow_traffic": "beforeAllowTraffic",
842
+ "before_install": "beforeInstall",
843
+ },
844
+ )
845
+ class AppSpecHooks:
846
+ def __init__(
847
+ self,
848
+ *,
849
+ after_allow_test_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
850
+ after_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
851
+ after_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
852
+ before_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
853
+ before_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
854
+ ) -> None:
855
+ '''Lifecycle hooks configuration.
856
+
857
+ :param after_allow_test_traffic: Lambda or ARN of a lambda to run tasks after the test listener serves traffic to the replacement task set.
858
+ :param after_allow_traffic: Lambda or ARN of a lambda to run tasks after the second target group serves traffic to the replacement task set.
859
+ :param after_install: Lambda or ARN of a lambda to run tasks after the replacement task set is created and one of the target groups is associated with it.
860
+ :param before_allow_traffic: Lambda or ARN of a lambda to run tasks after the second target group is associated with the replacement task set, but before traffic is shifted to the replacement task set.
861
+ :param before_install: Lambda or ARN of a lambda to run tasks before the replacement task set is created.
862
+ '''
863
+ if __debug__:
864
+ type_hints = typing.get_type_hints(_typecheckingstub__ff5030e61a5fd08fabf54e34ff261d6fa3b0a899cf455b923b66273d671d18f9)
865
+ check_type(argname="argument after_allow_test_traffic", value=after_allow_test_traffic, expected_type=type_hints["after_allow_test_traffic"])
866
+ check_type(argname="argument after_allow_traffic", value=after_allow_traffic, expected_type=type_hints["after_allow_traffic"])
867
+ check_type(argname="argument after_install", value=after_install, expected_type=type_hints["after_install"])
868
+ check_type(argname="argument before_allow_traffic", value=before_allow_traffic, expected_type=type_hints["before_allow_traffic"])
869
+ check_type(argname="argument before_install", value=before_install, expected_type=type_hints["before_install"])
870
+ self._values: typing.Dict[builtins.str, typing.Any] = {}
871
+ if after_allow_test_traffic is not None:
872
+ self._values["after_allow_test_traffic"] = after_allow_test_traffic
873
+ if after_allow_traffic is not None:
874
+ self._values["after_allow_traffic"] = after_allow_traffic
875
+ if after_install is not None:
876
+ self._values["after_install"] = after_install
877
+ if before_allow_traffic is not None:
878
+ self._values["before_allow_traffic"] = before_allow_traffic
879
+ if before_install is not None:
880
+ self._values["before_install"] = before_install
881
+
882
+ @builtins.property
883
+ def after_allow_test_traffic(
884
+ self,
885
+ ) -> typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]]:
886
+ '''Lambda or ARN of a lambda to run tasks after the test listener serves traffic to the replacement task set.'''
887
+ result = self._values.get("after_allow_test_traffic")
888
+ return typing.cast(typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]], result)
889
+
890
+ @builtins.property
891
+ def after_allow_traffic(
892
+ self,
893
+ ) -> typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]]:
894
+ '''Lambda or ARN of a lambda to run tasks after the second target group serves traffic to the replacement task set.'''
895
+ result = self._values.get("after_allow_traffic")
896
+ return typing.cast(typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]], result)
897
+
898
+ @builtins.property
899
+ def after_install(
900
+ self,
901
+ ) -> typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]]:
902
+ '''Lambda or ARN of a lambda to run tasks after the replacement task set is created and one of the target groups is associated with it.'''
903
+ result = self._values.get("after_install")
904
+ return typing.cast(typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]], result)
905
+
906
+ @builtins.property
907
+ def before_allow_traffic(
908
+ self,
909
+ ) -> typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]]:
910
+ '''Lambda or ARN of a lambda to run tasks after the second target group is associated with the replacement task set, but before traffic is shifted to the replacement task set.'''
911
+ result = self._values.get("before_allow_traffic")
912
+ return typing.cast(typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]], result)
913
+
914
+ @builtins.property
915
+ def before_install(
916
+ self,
917
+ ) -> typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]]:
918
+ '''Lambda or ARN of a lambda to run tasks before the replacement task set is created.'''
919
+ result = self._values.get("before_install")
920
+ return typing.cast(typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]], result)
921
+
922
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
923
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
924
+
925
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
926
+ return not (rhs == self)
927
+
928
+ def __repr__(self) -> str:
929
+ return "AppSpecHooks(%s)" % ", ".join(
930
+ k + "=" + repr(v) for k, v in self._values.items()
931
+ )
932
+
933
+
934
+ class ApplicationLoadBalancedCodeDeployedFargateService(
935
+ _aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedFargateService,
936
+ metaclass=jsii.JSIIMeta,
937
+ jsii_type="must-cdk.ApplicationLoadBalancedCodeDeployedFargateService",
938
+ ):
939
+ '''A Fargate service running on an ECS cluster fronted by an application load balancer and deployed by CodeDeploy.'''
940
+
941
+ def __init__(
942
+ self,
943
+ scope: _constructs_77d1e7e8.Construct,
944
+ id: builtins.str,
945
+ *,
946
+ access_log_bucket: typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket] = None,
947
+ access_log_prefix: typing.Optional[builtins.str] = None,
948
+ api_canary_schedule: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
949
+ api_canary_thread_count: typing.Optional[jsii.Number] = None,
950
+ api_canary_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
951
+ api_test_steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
952
+ application_name: typing.Optional[builtins.str] = None,
953
+ deployment_config: typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig] = None,
954
+ deployment_group_name: typing.Optional[builtins.str] = None,
955
+ deployment_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
956
+ deregistration_delay: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
957
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
958
+ response_time_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
959
+ target_health_check: typing.Optional[typing.Union[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
960
+ termination_wait_time: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
961
+ test_port: typing.Optional[jsii.Number] = None,
962
+ assign_public_ip: typing.Optional[builtins.bool] = None,
963
+ container_cpu: typing.Optional[jsii.Number] = None,
964
+ container_memory_limit_mib: typing.Optional[jsii.Number] = None,
965
+ health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
966
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
967
+ task_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
968
+ capacity_provider_strategies: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
969
+ certificate: typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate] = None,
970
+ circuit_breaker: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker, typing.Dict[builtins.str, typing.Any]]] = None,
971
+ cloud_map_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions, typing.Dict[builtins.str, typing.Any]]] = None,
972
+ cluster: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster] = None,
973
+ deployment_controller: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentController, typing.Dict[builtins.str, typing.Any]]] = None,
974
+ desired_count: typing.Optional[jsii.Number] = None,
975
+ domain_name: typing.Optional[builtins.str] = None,
976
+ domain_zone: typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone] = None,
977
+ enable_ecs_managed_tags: typing.Optional[builtins.bool] = None,
978
+ enable_execute_command: typing.Optional[builtins.bool] = None,
979
+ health_check_grace_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
980
+ idle_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
981
+ ip_address_type: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType] = None,
982
+ listener_port: typing.Optional[jsii.Number] = None,
983
+ load_balancer: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer] = None,
984
+ load_balancer_name: typing.Optional[builtins.str] = None,
985
+ max_healthy_percent: typing.Optional[jsii.Number] = None,
986
+ min_healthy_percent: typing.Optional[jsii.Number] = None,
987
+ open_listener: typing.Optional[builtins.bool] = None,
988
+ propagate_tags: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource] = None,
989
+ protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
990
+ protocol_version: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion] = None,
991
+ public_load_balancer: typing.Optional[builtins.bool] = None,
992
+ record_type: typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType] = None,
993
+ redirect_http: typing.Optional[builtins.bool] = None,
994
+ service_name: typing.Optional[builtins.str] = None,
995
+ ssl_policy: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy] = None,
996
+ target_protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
997
+ task_image_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions, typing.Dict[builtins.str, typing.Any]]] = None,
998
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
999
+ cpu: typing.Optional[jsii.Number] = None,
1000
+ ephemeral_storage_gib: typing.Optional[jsii.Number] = None,
1001
+ memory_limit_mib: typing.Optional[jsii.Number] = None,
1002
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
1003
+ runtime_platform: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform, typing.Dict[builtins.str, typing.Any]]] = None,
1004
+ task_definition: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition] = None,
1005
+ ) -> None:
1006
+ '''Constructs a new instance of the ApplicationLoadBalancedCodeDeployedFargateService class.
1007
+
1008
+ :param scope: -
1009
+ :param id: -
1010
+ :param access_log_bucket: The bucket to use for access logs from the Application Load Balancer. Default: - a new S3 bucket will be created
1011
+ :param access_log_prefix: The prefix to use for access logs from the Application Load Balancer. Default: - none
1012
+ :param api_canary_schedule: The frequency for running the api canaries. Default: - 5 minutes
1013
+ :param api_canary_thread_count: The number of threads to run concurrently for the synthetic test. Default: - 20
1014
+ :param api_canary_timeout: The threshold for how long a api canary can take to run. Default: - no alarm is created for test duration
1015
+ :param api_test_steps: The steps to run in the canary. Default: - no synthetic test will be created
1016
+ :param application_name: The physical, human-readable name of the CodeDeploy Application. Default: an auto-generated name will be used
1017
+ :param deployment_config: The deployment configuration to use for the deployment group. Default: - EcsDeploymentConfig.ALL_AT_ONCE
1018
+ :param deployment_group_name: The physical, human-readable name of the CodeDeploy Deployment Group. Default: An auto-generated name will be used.
1019
+ :param deployment_timeout: The timeout for a CodeDeploy deployment. Default: - 60 minutes
1020
+ :param deregistration_delay: The amount of time for ELB to wait before changing the state of a deregistering target from 'draining' to 'unused'. Default: - 300 seconds
1021
+ :param hooks: Optional lifecycle hooks. Default: - no lifecycle hooks
1022
+ :param response_time_alarm_threshold: The threshold for response time alarm. Default: - no alarm will be created
1023
+ :param target_health_check: The healthcheck to configure on the Application Load Balancer target groups. Default: - no health check is configured
1024
+ :param termination_wait_time: The time to wait before terminating the original (blue) task set. Default: - 10 minutes
1025
+ :param test_port: The port to use for test traffic on the listener. Default: - listenerPort + 1
1026
+ :param assign_public_ip: Determines whether the service will be assigned a public IP address. Default: false
1027
+ :param container_cpu: The minimum number of CPU units to reserve for the container. Default: - No minimum CPU units reserved.
1028
+ :param container_memory_limit_mib: The amount (in MiB) of memory to present to the container. If your container attempts to exceed the allocated memory, the container is terminated. Default: - No memory limit.
1029
+ :param health_check: The health check command and associated configuration parameters for the container. Default: - Health check configuration from container.
1030
+ :param security_groups: The security groups to associate with the service. If you do not specify a security group, a new security group is created. Default: - A new security group is created.
1031
+ :param task_subnets: The subnets to associate with the service. Default: - Public subnets if ``assignPublicIp`` is set, otherwise the first available one of Private, Isolated, Public, in that order.
1032
+ :param capacity_provider_strategies: A list of Capacity Provider strategies used to place a service. Default: - undefined
1033
+ :param certificate: Certificate Manager certificate to associate with the load balancer. Setting this option will set the load balancer protocol to HTTPS. Default: - No certificate associated with the load balancer, if using the HTTP protocol. For HTTPS, a DNS-validated certificate will be created for the load balancer's specified domain name if a domain name and domain zone are specified.
1034
+ :param circuit_breaker: Whether to enable the deployment circuit breaker. If this property is defined, circuit breaker will be implicitly enabled. Default: - disabled
1035
+ :param cloud_map_options: The options for configuring an Amazon ECS service to use service discovery. Default: - AWS Cloud Map service discovery is not enabled.
1036
+ :param cluster: The name of the cluster that hosts the service. If a cluster is specified, the vpc construct should be omitted. Alternatively, you can omit both cluster and vpc. Default: - create a new cluster; if both cluster and vpc are omitted, a new VPC will be created for you.
1037
+ :param deployment_controller: Specifies which deployment controller to use for the service. For more information, see `Amazon ECS Deployment Types <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html>`_ Default: - Rolling update (ECS)
1038
+ :param desired_count: The desired number of instantiations of the task definition to keep running on the service. The minimum value is 1 Default: - The default is 1 for all new services and uses the existing service's desired count when updating an existing service.
1039
+ :param domain_name: The domain name for the service, e.g. "api.example.com.". Default: - No domain name.
1040
+ :param domain_zone: The Route53 hosted zone for the domain, e.g. "example.com.". Default: - No Route53 hosted domain zone.
1041
+ :param enable_ecs_managed_tags: Specifies whether to enable Amazon ECS managed tags for the tasks within the service. For more information, see `Tagging Your Amazon ECS Resources <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-using-tags.html>`_ Default: false
1042
+ :param enable_execute_command: Whether ECS Exec should be enabled. Default: - false
1043
+ :param health_check_grace_period: The period of time, in seconds, that the Amazon ECS service scheduler ignores unhealthy Elastic Load Balancing target health checks after a task has first started. Default: - defaults to 60 seconds if at least one load balancer is in-use and it is not already set
1044
+ :param idle_timeout: The load balancer idle timeout, in seconds. Can be between 1 and 4000 seconds Default: - CloudFormation sets idle timeout to 60 seconds
1045
+ :param ip_address_type: The type of IP address to use. Default: - IpAddressType.IPV4
1046
+ :param listener_port: Listener port of the application load balancer that will serve traffic to the service. Default: - The default listener port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). A domain name and zone must be also be specified if using HTTPS.
1047
+ :param load_balancer: The application load balancer that will serve traffic to the service. The VPC attribute of a load balancer must be specified for it to be used to create a new service with this pattern. [disable-awslint:ref-via-interface] Default: - a new load balancer will be created.
1048
+ :param load_balancer_name: Name of the load balancer. Default: - Automatically generated name.
1049
+ :param max_healthy_percent: The maximum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that can run in a service during a deployment. Default: - 100 if daemon, otherwise 200
1050
+ :param min_healthy_percent: The minimum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that must continue to run and remain healthy during a deployment. Default: - 0 if daemon, otherwise 50
1051
+ :param open_listener: Determines whether or not the Security Group for the Load Balancer's Listener will be open to all traffic by default. Default: true -- The security group allows ingress from all IP addresses.
1052
+ :param propagate_tags: Specifies whether to propagate the tags from the task definition or the service to the tasks in the service. Tags can only be propagated to the tasks within the service during service creation. Default: - none
1053
+ :param protocol: The protocol for connections from clients to the load balancer. The load balancer port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). If HTTPS, either a certificate or domain name and domain zone must also be specified. Default: HTTP. If a certificate is specified, the protocol will be set by default to HTTPS.
1054
+ :param protocol_version: The protocol version to use. Default: ApplicationProtocolVersion.HTTP1
1055
+ :param public_load_balancer: Determines whether the Load Balancer will be internet-facing. Default: true
1056
+ :param record_type: Specifies whether the Route53 record should be a CNAME, an A record using the Alias feature or no record at all. This is useful if you need to work with DNS systems that do not support alias records. Default: ApplicationLoadBalancedServiceRecordType.ALIAS
1057
+ :param redirect_http: Specifies whether the load balancer should redirect traffic on port 80 to the {@link listenerPort} to support HTTP->HTTPS redirects. This is only valid if the protocol of the ALB is HTTPS. Default: false
1058
+ :param service_name: The name of the service. Default: - CloudFormation-generated name.
1059
+ :param ssl_policy: The security policy that defines which ciphers and protocols are supported by the ALB Listener. Default: - The recommended elastic load balancing security policy
1060
+ :param target_protocol: The protocol for connections from the load balancer to the ECS tasks. The default target port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). Default: HTTP.
1061
+ :param task_image_options: The properties required to create a new task definition. TaskDefinition or TaskImageOptions must be specified, but not both. Default: none
1062
+ :param vpc: The VPC where the container instances will be launched or the elastic network interfaces (ENIs) will be deployed. If a vpc is specified, the cluster construct should be omitted. Alternatively, you can omit both vpc and cluster. Default: - uses the VPC defined in the cluster or creates a new VPC.
1063
+ :param cpu: The number of cpu units used by the task. Valid values, which determines your range of valid values for the memory parameter: 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB increments 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB increments 8192 (8 vCPU) - Available memory values: Between 16GB and 60GB in 4GB increments 16384 (16 vCPU) - Available memory values: Between 32GB and 120GB in 8GB increments This default is set in the underlying FargateTaskDefinition construct. Default: 256
1064
+ :param ephemeral_storage_gib: The amount (in GiB) of ephemeral storage to be allocated to the task. The minimum supported value is ``21`` GiB and the maximum supported value is ``200`` GiB. Only supported in Fargate platform version 1.4.0 or later. Default: Undefined, in which case, the task will receive 20GiB ephemeral storage.
1065
+ :param memory_limit_mib: The amount (in MiB) of memory used by the task. This field is required and you must use one of the following values, which determines your range of valid values for the cpu parameter: 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 vCPU) 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: 512 (.5 vCPU) 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU) Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - Available cpu values: 2048 (2 vCPU) Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - Available cpu values: 4096 (4 vCPU) Between 16384 (16 GB) and 61440 (60 GB) in increments of 4096 (4 GB) - Available cpu values: 8192 (8 vCPU) Between 32768 (32 GB) and 122880 (120 GB) in increments of 8192 (8 GB) - Available cpu values: 16384 (16 vCPU) This default is set in the underlying FargateTaskDefinition construct. Default: 512
1066
+ :param platform_version: The platform version on which to run your service. If one is not specified, the LATEST platform version is used by default. For more information, see `AWS Fargate Platform Versions <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html>`_ in the Amazon Elastic Container Service Developer Guide. Default: Latest
1067
+ :param runtime_platform: The runtime platform of the task definition. Default: - If the property is undefined, ``operatingSystemFamily`` is LINUX and ``cpuArchitecture`` is X86_64
1068
+ :param task_definition: The task definition to use for tasks in the service. TaskDefinition or TaskImageOptions must be specified, but not both. [disable-awslint:ref-via-interface] Default: - none
1069
+ '''
1070
+ if __debug__:
1071
+ type_hints = typing.get_type_hints(_typecheckingstub__cdc591d3fee959d6fc3e921fd142a865c9095fcaa7afe54cfab63ad9654b3069)
1072
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
1073
+ check_type(argname="argument id", value=id, expected_type=type_hints["id"])
1074
+ props = ApplicationLoadBalancedCodeDeployedFargateServiceProps(
1075
+ access_log_bucket=access_log_bucket,
1076
+ access_log_prefix=access_log_prefix,
1077
+ api_canary_schedule=api_canary_schedule,
1078
+ api_canary_thread_count=api_canary_thread_count,
1079
+ api_canary_timeout=api_canary_timeout,
1080
+ api_test_steps=api_test_steps,
1081
+ application_name=application_name,
1082
+ deployment_config=deployment_config,
1083
+ deployment_group_name=deployment_group_name,
1084
+ deployment_timeout=deployment_timeout,
1085
+ deregistration_delay=deregistration_delay,
1086
+ hooks=hooks,
1087
+ response_time_alarm_threshold=response_time_alarm_threshold,
1088
+ target_health_check=target_health_check,
1089
+ termination_wait_time=termination_wait_time,
1090
+ test_port=test_port,
1091
+ assign_public_ip=assign_public_ip,
1092
+ container_cpu=container_cpu,
1093
+ container_memory_limit_mib=container_memory_limit_mib,
1094
+ health_check=health_check,
1095
+ security_groups=security_groups,
1096
+ task_subnets=task_subnets,
1097
+ capacity_provider_strategies=capacity_provider_strategies,
1098
+ certificate=certificate,
1099
+ circuit_breaker=circuit_breaker,
1100
+ cloud_map_options=cloud_map_options,
1101
+ cluster=cluster,
1102
+ deployment_controller=deployment_controller,
1103
+ desired_count=desired_count,
1104
+ domain_name=domain_name,
1105
+ domain_zone=domain_zone,
1106
+ enable_ecs_managed_tags=enable_ecs_managed_tags,
1107
+ enable_execute_command=enable_execute_command,
1108
+ health_check_grace_period=health_check_grace_period,
1109
+ idle_timeout=idle_timeout,
1110
+ ip_address_type=ip_address_type,
1111
+ listener_port=listener_port,
1112
+ load_balancer=load_balancer,
1113
+ load_balancer_name=load_balancer_name,
1114
+ max_healthy_percent=max_healthy_percent,
1115
+ min_healthy_percent=min_healthy_percent,
1116
+ open_listener=open_listener,
1117
+ propagate_tags=propagate_tags,
1118
+ protocol=protocol,
1119
+ protocol_version=protocol_version,
1120
+ public_load_balancer=public_load_balancer,
1121
+ record_type=record_type,
1122
+ redirect_http=redirect_http,
1123
+ service_name=service_name,
1124
+ ssl_policy=ssl_policy,
1125
+ target_protocol=target_protocol,
1126
+ task_image_options=task_image_options,
1127
+ vpc=vpc,
1128
+ cpu=cpu,
1129
+ ephemeral_storage_gib=ephemeral_storage_gib,
1130
+ memory_limit_mib=memory_limit_mib,
1131
+ platform_version=platform_version,
1132
+ runtime_platform=runtime_platform,
1133
+ task_definition=task_definition,
1134
+ )
1135
+
1136
+ jsii.create(self.__class__, self, [scope, id, props])
1137
+
1138
+ @jsii.member(jsii_name="addServiceAsTarget")
1139
+ def _add_service_as_target(
1140
+ self,
1141
+ service: _aws_cdk_aws_ecs_ceddda9d.BaseService,
1142
+ ) -> None:
1143
+ '''Adds service as a target of the target group.
1144
+
1145
+ :param service: -
1146
+ '''
1147
+ if __debug__:
1148
+ type_hints = typing.get_type_hints(_typecheckingstub__2e9ebe4d64205e08ed6953e0bfeed401797c431625ac1359c850bea7289fd3bd)
1149
+ check_type(argname="argument service", value=service, expected_type=type_hints["service"])
1150
+ return typing.cast(None, jsii.invoke(self, "addServiceAsTarget", [service]))
1151
+
1152
+ @builtins.property
1153
+ @jsii.member(jsii_name="accessLogBucket")
1154
+ def access_log_bucket(self) -> _aws_cdk_aws_s3_ceddda9d.IBucket:
1155
+ '''S3 Bucket used for access logs.'''
1156
+ return typing.cast(_aws_cdk_aws_s3_ceddda9d.IBucket, jsii.get(self, "accessLogBucket"))
1157
+
1158
+ @access_log_bucket.setter
1159
+ def access_log_bucket(self, value: _aws_cdk_aws_s3_ceddda9d.IBucket) -> None:
1160
+ if __debug__:
1161
+ type_hints = typing.get_type_hints(_typecheckingstub__04c27870fbc63c85094d295b9f732c20ae2ea852010c4ad421bcde70ea6317b9)
1162
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1163
+ jsii.set(self, "accessLogBucket", value) # pyright: ignore[reportArgumentType]
1164
+
1165
+ @builtins.property
1166
+ @jsii.member(jsii_name="application")
1167
+ def application(self) -> _aws_cdk_aws_codedeploy_ceddda9d.EcsApplication:
1168
+ '''CodeDeploy application for this service.'''
1169
+ return typing.cast(_aws_cdk_aws_codedeploy_ceddda9d.EcsApplication, jsii.get(self, "application"))
1170
+
1171
+ @application.setter
1172
+ def application(
1173
+ self,
1174
+ value: _aws_cdk_aws_codedeploy_ceddda9d.EcsApplication,
1175
+ ) -> None:
1176
+ if __debug__:
1177
+ type_hints = typing.get_type_hints(_typecheckingstub__d9fc5156a1b8cf5bbc9b35e9b6746bb1f8400e7a99432fae8b3c01d42f18cf4f)
1178
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1179
+ jsii.set(self, "application", value) # pyright: ignore[reportArgumentType]
1180
+
1181
+ @builtins.property
1182
+ @jsii.member(jsii_name="deployment")
1183
+ def deployment(self) -> "EcsDeployment":
1184
+ '''CodeDeploy deployment for this service.'''
1185
+ return typing.cast("EcsDeployment", jsii.get(self, "deployment"))
1186
+
1187
+ @deployment.setter
1188
+ def deployment(self, value: "EcsDeployment") -> None:
1189
+ if __debug__:
1190
+ type_hints = typing.get_type_hints(_typecheckingstub__272d02dc1b0a56f7951e43174a9099ef41f00eb05cc85b8c8467dfffa4c7b575)
1191
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1192
+ jsii.set(self, "deployment", value) # pyright: ignore[reportArgumentType]
1193
+
1194
+ @builtins.property
1195
+ @jsii.member(jsii_name="deploymentGroup")
1196
+ def deployment_group(self) -> _aws_cdk_aws_codedeploy_ceddda9d.EcsDeploymentGroup:
1197
+ '''CodeDeploy deployment group for this service.'''
1198
+ return typing.cast(_aws_cdk_aws_codedeploy_ceddda9d.EcsDeploymentGroup, jsii.get(self, "deploymentGroup"))
1199
+
1200
+ @deployment_group.setter
1201
+ def deployment_group(
1202
+ self,
1203
+ value: _aws_cdk_aws_codedeploy_ceddda9d.EcsDeploymentGroup,
1204
+ ) -> None:
1205
+ if __debug__:
1206
+ type_hints = typing.get_type_hints(_typecheckingstub__447b00dfcf799fcb98a028b408aa3d1099e3032ff90cdfbf5edb60629924fa4f)
1207
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1208
+ jsii.set(self, "deploymentGroup", value) # pyright: ignore[reportArgumentType]
1209
+
1210
+ @builtins.property
1211
+ @jsii.member(jsii_name="greenTargetGroup")
1212
+ def green_target_group(
1213
+ self,
1214
+ ) -> _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationTargetGroup:
1215
+ '''Test target group to use for CodeDeploy deployments.'''
1216
+ return typing.cast(_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationTargetGroup, jsii.get(self, "greenTargetGroup"))
1217
+
1218
+ @green_target_group.setter
1219
+ def green_target_group(
1220
+ self,
1221
+ value: _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationTargetGroup,
1222
+ ) -> None:
1223
+ if __debug__:
1224
+ type_hints = typing.get_type_hints(_typecheckingstub__aa3a26b4b04d4908d2ea2109d2b4d87bedc95a0fe8cd0a8d0540b8791158781c)
1225
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1226
+ jsii.set(self, "greenTargetGroup", value) # pyright: ignore[reportArgumentType]
1227
+
1228
+ @builtins.property
1229
+ @jsii.member(jsii_name="testListener")
1230
+ def test_listener(
1231
+ self,
1232
+ ) -> _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationListener:
1233
+ '''Test listener to use for CodeDeploy deployments.'''
1234
+ return typing.cast(_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationListener, jsii.get(self, "testListener"))
1235
+
1236
+ @test_listener.setter
1237
+ def test_listener(
1238
+ self,
1239
+ value: _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationListener,
1240
+ ) -> None:
1241
+ if __debug__:
1242
+ type_hints = typing.get_type_hints(_typecheckingstub__a2ed1861141868939832c87d220366d1440d0ef23114460879e579d0433e3a14)
1243
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1244
+ jsii.set(self, "testListener", value) # pyright: ignore[reportArgumentType]
1245
+
1246
+ @builtins.property
1247
+ @jsii.member(jsii_name="apiCanary")
1248
+ def api_canary(self) -> typing.Optional[ApiCanary]:
1249
+ '''API Canary for the service.'''
1250
+ return typing.cast(typing.Optional[ApiCanary], jsii.get(self, "apiCanary"))
1251
+
1252
+ @api_canary.setter
1253
+ def api_canary(self, value: typing.Optional[ApiCanary]) -> None:
1254
+ if __debug__:
1255
+ type_hints = typing.get_type_hints(_typecheckingstub__627a57fa5d3bba90628c374262020d7d1795c5bf62770ef75633f192fd5753d9)
1256
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1257
+ jsii.set(self, "apiCanary", value) # pyright: ignore[reportArgumentType]
1258
+
1259
+ @builtins.property
1260
+ @jsii.member(jsii_name="healthAlarm")
1261
+ def health_alarm(self) -> typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.IAlarm]:
1262
+ '''Composite alarm for monitoring health of service.'''
1263
+ return typing.cast(typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.IAlarm], jsii.get(self, "healthAlarm"))
1264
+
1265
+ @health_alarm.setter
1266
+ def health_alarm(
1267
+ self,
1268
+ value: typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.IAlarm],
1269
+ ) -> None:
1270
+ if __debug__:
1271
+ type_hints = typing.get_type_hints(_typecheckingstub__e070ffcc3fb27284424c9fd4af0ef70d9a50ac85df05cd34a1127edefb90d397)
1272
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
1273
+ jsii.set(self, "healthAlarm", value) # pyright: ignore[reportArgumentType]
1274
+
1275
+
1276
+ @jsii.data_type(
1277
+ jsii_type="must-cdk.ApplicationLoadBalancedCodeDeployedFargateServiceProps",
1278
+ jsii_struct_bases=[
1279
+ _aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedFargateServiceProps
1280
+ ],
1281
+ name_mapping={
1282
+ "capacity_provider_strategies": "capacityProviderStrategies",
1283
+ "certificate": "certificate",
1284
+ "circuit_breaker": "circuitBreaker",
1285
+ "cloud_map_options": "cloudMapOptions",
1286
+ "cluster": "cluster",
1287
+ "deployment_controller": "deploymentController",
1288
+ "desired_count": "desiredCount",
1289
+ "domain_name": "domainName",
1290
+ "domain_zone": "domainZone",
1291
+ "enable_ecs_managed_tags": "enableECSManagedTags",
1292
+ "enable_execute_command": "enableExecuteCommand",
1293
+ "health_check_grace_period": "healthCheckGracePeriod",
1294
+ "idle_timeout": "idleTimeout",
1295
+ "ip_address_type": "ipAddressType",
1296
+ "listener_port": "listenerPort",
1297
+ "load_balancer": "loadBalancer",
1298
+ "load_balancer_name": "loadBalancerName",
1299
+ "max_healthy_percent": "maxHealthyPercent",
1300
+ "min_healthy_percent": "minHealthyPercent",
1301
+ "open_listener": "openListener",
1302
+ "propagate_tags": "propagateTags",
1303
+ "protocol": "protocol",
1304
+ "protocol_version": "protocolVersion",
1305
+ "public_load_balancer": "publicLoadBalancer",
1306
+ "record_type": "recordType",
1307
+ "redirect_http": "redirectHTTP",
1308
+ "service_name": "serviceName",
1309
+ "ssl_policy": "sslPolicy",
1310
+ "target_protocol": "targetProtocol",
1311
+ "task_image_options": "taskImageOptions",
1312
+ "vpc": "vpc",
1313
+ "cpu": "cpu",
1314
+ "ephemeral_storage_gib": "ephemeralStorageGiB",
1315
+ "memory_limit_mib": "memoryLimitMiB",
1316
+ "platform_version": "platformVersion",
1317
+ "runtime_platform": "runtimePlatform",
1318
+ "task_definition": "taskDefinition",
1319
+ "assign_public_ip": "assignPublicIp",
1320
+ "container_cpu": "containerCpu",
1321
+ "container_memory_limit_mib": "containerMemoryLimitMiB",
1322
+ "health_check": "healthCheck",
1323
+ "security_groups": "securityGroups",
1324
+ "task_subnets": "taskSubnets",
1325
+ "access_log_bucket": "accessLogBucket",
1326
+ "access_log_prefix": "accessLogPrefix",
1327
+ "api_canary_schedule": "apiCanarySchedule",
1328
+ "api_canary_thread_count": "apiCanaryThreadCount",
1329
+ "api_canary_timeout": "apiCanaryTimeout",
1330
+ "api_test_steps": "apiTestSteps",
1331
+ "application_name": "applicationName",
1332
+ "deployment_config": "deploymentConfig",
1333
+ "deployment_group_name": "deploymentGroupName",
1334
+ "deployment_timeout": "deploymentTimeout",
1335
+ "deregistration_delay": "deregistrationDelay",
1336
+ "hooks": "hooks",
1337
+ "response_time_alarm_threshold": "responseTimeAlarmThreshold",
1338
+ "target_health_check": "targetHealthCheck",
1339
+ "termination_wait_time": "terminationWaitTime",
1340
+ "test_port": "testPort",
1341
+ },
1342
+ )
1343
+ class ApplicationLoadBalancedCodeDeployedFargateServiceProps(
1344
+ _aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedFargateServiceProps,
1345
+ ):
1346
+ def __init__(
1347
+ self,
1348
+ *,
1349
+ capacity_provider_strategies: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
1350
+ certificate: typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate] = None,
1351
+ circuit_breaker: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker, typing.Dict[builtins.str, typing.Any]]] = None,
1352
+ cloud_map_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1353
+ cluster: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster] = None,
1354
+ deployment_controller: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentController, typing.Dict[builtins.str, typing.Any]]] = None,
1355
+ desired_count: typing.Optional[jsii.Number] = None,
1356
+ domain_name: typing.Optional[builtins.str] = None,
1357
+ domain_zone: typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone] = None,
1358
+ enable_ecs_managed_tags: typing.Optional[builtins.bool] = None,
1359
+ enable_execute_command: typing.Optional[builtins.bool] = None,
1360
+ health_check_grace_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1361
+ idle_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1362
+ ip_address_type: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType] = None,
1363
+ listener_port: typing.Optional[jsii.Number] = None,
1364
+ load_balancer: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer] = None,
1365
+ load_balancer_name: typing.Optional[builtins.str] = None,
1366
+ max_healthy_percent: typing.Optional[jsii.Number] = None,
1367
+ min_healthy_percent: typing.Optional[jsii.Number] = None,
1368
+ open_listener: typing.Optional[builtins.bool] = None,
1369
+ propagate_tags: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource] = None,
1370
+ protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
1371
+ protocol_version: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion] = None,
1372
+ public_load_balancer: typing.Optional[builtins.bool] = None,
1373
+ record_type: typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType] = None,
1374
+ redirect_http: typing.Optional[builtins.bool] = None,
1375
+ service_name: typing.Optional[builtins.str] = None,
1376
+ ssl_policy: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy] = None,
1377
+ target_protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
1378
+ task_image_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions, typing.Dict[builtins.str, typing.Any]]] = None,
1379
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
1380
+ cpu: typing.Optional[jsii.Number] = None,
1381
+ ephemeral_storage_gib: typing.Optional[jsii.Number] = None,
1382
+ memory_limit_mib: typing.Optional[jsii.Number] = None,
1383
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
1384
+ runtime_platform: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform, typing.Dict[builtins.str, typing.Any]]] = None,
1385
+ task_definition: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition] = None,
1386
+ assign_public_ip: typing.Optional[builtins.bool] = None,
1387
+ container_cpu: typing.Optional[jsii.Number] = None,
1388
+ container_memory_limit_mib: typing.Optional[jsii.Number] = None,
1389
+ health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
1390
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
1391
+ task_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
1392
+ access_log_bucket: typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket] = None,
1393
+ access_log_prefix: typing.Optional[builtins.str] = None,
1394
+ api_canary_schedule: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1395
+ api_canary_thread_count: typing.Optional[jsii.Number] = None,
1396
+ api_canary_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1397
+ api_test_steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
1398
+ application_name: typing.Optional[builtins.str] = None,
1399
+ deployment_config: typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig] = None,
1400
+ deployment_group_name: typing.Optional[builtins.str] = None,
1401
+ deployment_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1402
+ deregistration_delay: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1403
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
1404
+ response_time_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1405
+ target_health_check: typing.Optional[typing.Union[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
1406
+ termination_wait_time: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
1407
+ test_port: typing.Optional[jsii.Number] = None,
1408
+ ) -> None:
1409
+ '''The properties for the ApplicationLoadBalancedCodeDeployedFargateService service.
1410
+
1411
+ :param capacity_provider_strategies: A list of Capacity Provider strategies used to place a service. Default: - undefined
1412
+ :param certificate: Certificate Manager certificate to associate with the load balancer. Setting this option will set the load balancer protocol to HTTPS. Default: - No certificate associated with the load balancer, if using the HTTP protocol. For HTTPS, a DNS-validated certificate will be created for the load balancer's specified domain name if a domain name and domain zone are specified.
1413
+ :param circuit_breaker: Whether to enable the deployment circuit breaker. If this property is defined, circuit breaker will be implicitly enabled. Default: - disabled
1414
+ :param cloud_map_options: The options for configuring an Amazon ECS service to use service discovery. Default: - AWS Cloud Map service discovery is not enabled.
1415
+ :param cluster: The name of the cluster that hosts the service. If a cluster is specified, the vpc construct should be omitted. Alternatively, you can omit both cluster and vpc. Default: - create a new cluster; if both cluster and vpc are omitted, a new VPC will be created for you.
1416
+ :param deployment_controller: Specifies which deployment controller to use for the service. For more information, see `Amazon ECS Deployment Types <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html>`_ Default: - Rolling update (ECS)
1417
+ :param desired_count: The desired number of instantiations of the task definition to keep running on the service. The minimum value is 1 Default: - The default is 1 for all new services and uses the existing service's desired count when updating an existing service.
1418
+ :param domain_name: The domain name for the service, e.g. "api.example.com.". Default: - No domain name.
1419
+ :param domain_zone: The Route53 hosted zone for the domain, e.g. "example.com.". Default: - No Route53 hosted domain zone.
1420
+ :param enable_ecs_managed_tags: Specifies whether to enable Amazon ECS managed tags for the tasks within the service. For more information, see `Tagging Your Amazon ECS Resources <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-using-tags.html>`_ Default: false
1421
+ :param enable_execute_command: Whether ECS Exec should be enabled. Default: - false
1422
+ :param health_check_grace_period: The period of time, in seconds, that the Amazon ECS service scheduler ignores unhealthy Elastic Load Balancing target health checks after a task has first started. Default: - defaults to 60 seconds if at least one load balancer is in-use and it is not already set
1423
+ :param idle_timeout: The load balancer idle timeout, in seconds. Can be between 1 and 4000 seconds Default: - CloudFormation sets idle timeout to 60 seconds
1424
+ :param ip_address_type: The type of IP address to use. Default: - IpAddressType.IPV4
1425
+ :param listener_port: Listener port of the application load balancer that will serve traffic to the service. Default: - The default listener port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). A domain name and zone must be also be specified if using HTTPS.
1426
+ :param load_balancer: The application load balancer that will serve traffic to the service. The VPC attribute of a load balancer must be specified for it to be used to create a new service with this pattern. [disable-awslint:ref-via-interface] Default: - a new load balancer will be created.
1427
+ :param load_balancer_name: Name of the load balancer. Default: - Automatically generated name.
1428
+ :param max_healthy_percent: The maximum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that can run in a service during a deployment. Default: - 100 if daemon, otherwise 200
1429
+ :param min_healthy_percent: The minimum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that must continue to run and remain healthy during a deployment. Default: - 0 if daemon, otherwise 50
1430
+ :param open_listener: Determines whether or not the Security Group for the Load Balancer's Listener will be open to all traffic by default. Default: true -- The security group allows ingress from all IP addresses.
1431
+ :param propagate_tags: Specifies whether to propagate the tags from the task definition or the service to the tasks in the service. Tags can only be propagated to the tasks within the service during service creation. Default: - none
1432
+ :param protocol: The protocol for connections from clients to the load balancer. The load balancer port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). If HTTPS, either a certificate or domain name and domain zone must also be specified. Default: HTTP. If a certificate is specified, the protocol will be set by default to HTTPS.
1433
+ :param protocol_version: The protocol version to use. Default: ApplicationProtocolVersion.HTTP1
1434
+ :param public_load_balancer: Determines whether the Load Balancer will be internet-facing. Default: true
1435
+ :param record_type: Specifies whether the Route53 record should be a CNAME, an A record using the Alias feature or no record at all. This is useful if you need to work with DNS systems that do not support alias records. Default: ApplicationLoadBalancedServiceRecordType.ALIAS
1436
+ :param redirect_http: Specifies whether the load balancer should redirect traffic on port 80 to the {@link listenerPort} to support HTTP->HTTPS redirects. This is only valid if the protocol of the ALB is HTTPS. Default: false
1437
+ :param service_name: The name of the service. Default: - CloudFormation-generated name.
1438
+ :param ssl_policy: The security policy that defines which ciphers and protocols are supported by the ALB Listener. Default: - The recommended elastic load balancing security policy
1439
+ :param target_protocol: The protocol for connections from the load balancer to the ECS tasks. The default target port is determined from the protocol (port 80 for HTTP, port 443 for HTTPS). Default: HTTP.
1440
+ :param task_image_options: The properties required to create a new task definition. TaskDefinition or TaskImageOptions must be specified, but not both. Default: none
1441
+ :param vpc: The VPC where the container instances will be launched or the elastic network interfaces (ENIs) will be deployed. If a vpc is specified, the cluster construct should be omitted. Alternatively, you can omit both vpc and cluster. Default: - uses the VPC defined in the cluster or creates a new VPC.
1442
+ :param cpu: The number of cpu units used by the task. Valid values, which determines your range of valid values for the memory parameter: 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB increments 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB increments 8192 (8 vCPU) - Available memory values: Between 16GB and 60GB in 4GB increments 16384 (16 vCPU) - Available memory values: Between 32GB and 120GB in 8GB increments This default is set in the underlying FargateTaskDefinition construct. Default: 256
1443
+ :param ephemeral_storage_gib: The amount (in GiB) of ephemeral storage to be allocated to the task. The minimum supported value is ``21`` GiB and the maximum supported value is ``200`` GiB. Only supported in Fargate platform version 1.4.0 or later. Default: Undefined, in which case, the task will receive 20GiB ephemeral storage.
1444
+ :param memory_limit_mib: The amount (in MiB) of memory used by the task. This field is required and you must use one of the following values, which determines your range of valid values for the cpu parameter: 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 vCPU) 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: 512 (.5 vCPU) 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU) Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - Available cpu values: 2048 (2 vCPU) Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - Available cpu values: 4096 (4 vCPU) Between 16384 (16 GB) and 61440 (60 GB) in increments of 4096 (4 GB) - Available cpu values: 8192 (8 vCPU) Between 32768 (32 GB) and 122880 (120 GB) in increments of 8192 (8 GB) - Available cpu values: 16384 (16 vCPU) This default is set in the underlying FargateTaskDefinition construct. Default: 512
1445
+ :param platform_version: The platform version on which to run your service. If one is not specified, the LATEST platform version is used by default. For more information, see `AWS Fargate Platform Versions <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html>`_ in the Amazon Elastic Container Service Developer Guide. Default: Latest
1446
+ :param runtime_platform: The runtime platform of the task definition. Default: - If the property is undefined, ``operatingSystemFamily`` is LINUX and ``cpuArchitecture`` is X86_64
1447
+ :param task_definition: The task definition to use for tasks in the service. TaskDefinition or TaskImageOptions must be specified, but not both. [disable-awslint:ref-via-interface] Default: - none
1448
+ :param assign_public_ip: Determines whether the service will be assigned a public IP address. Default: false
1449
+ :param container_cpu: The minimum number of CPU units to reserve for the container. Default: - No minimum CPU units reserved.
1450
+ :param container_memory_limit_mib: The amount (in MiB) of memory to present to the container. If your container attempts to exceed the allocated memory, the container is terminated. Default: - No memory limit.
1451
+ :param health_check: The health check command and associated configuration parameters for the container. Default: - Health check configuration from container.
1452
+ :param security_groups: The security groups to associate with the service. If you do not specify a security group, a new security group is created. Default: - A new security group is created.
1453
+ :param task_subnets: The subnets to associate with the service. Default: - Public subnets if ``assignPublicIp`` is set, otherwise the first available one of Private, Isolated, Public, in that order.
1454
+ :param access_log_bucket: The bucket to use for access logs from the Application Load Balancer. Default: - a new S3 bucket will be created
1455
+ :param access_log_prefix: The prefix to use for access logs from the Application Load Balancer. Default: - none
1456
+ :param api_canary_schedule: The frequency for running the api canaries. Default: - 5 minutes
1457
+ :param api_canary_thread_count: The number of threads to run concurrently for the synthetic test. Default: - 20
1458
+ :param api_canary_timeout: The threshold for how long a api canary can take to run. Default: - no alarm is created for test duration
1459
+ :param api_test_steps: The steps to run in the canary. Default: - no synthetic test will be created
1460
+ :param application_name: The physical, human-readable name of the CodeDeploy Application. Default: an auto-generated name will be used
1461
+ :param deployment_config: The deployment configuration to use for the deployment group. Default: - EcsDeploymentConfig.ALL_AT_ONCE
1462
+ :param deployment_group_name: The physical, human-readable name of the CodeDeploy Deployment Group. Default: An auto-generated name will be used.
1463
+ :param deployment_timeout: The timeout for a CodeDeploy deployment. Default: - 60 minutes
1464
+ :param deregistration_delay: The amount of time for ELB to wait before changing the state of a deregistering target from 'draining' to 'unused'. Default: - 300 seconds
1465
+ :param hooks: Optional lifecycle hooks. Default: - no lifecycle hooks
1466
+ :param response_time_alarm_threshold: The threshold for response time alarm. Default: - no alarm will be created
1467
+ :param target_health_check: The healthcheck to configure on the Application Load Balancer target groups. Default: - no health check is configured
1468
+ :param termination_wait_time: The time to wait before terminating the original (blue) task set. Default: - 10 minutes
1469
+ :param test_port: The port to use for test traffic on the listener. Default: - listenerPort + 1
1470
+ '''
1471
+ if isinstance(circuit_breaker, dict):
1472
+ circuit_breaker = _aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker(**circuit_breaker)
1473
+ if isinstance(cloud_map_options, dict):
1474
+ cloud_map_options = _aws_cdk_aws_ecs_ceddda9d.CloudMapOptions(**cloud_map_options)
1475
+ if isinstance(deployment_controller, dict):
1476
+ deployment_controller = _aws_cdk_aws_ecs_ceddda9d.DeploymentController(**deployment_controller)
1477
+ if isinstance(task_image_options, dict):
1478
+ task_image_options = _aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions(**task_image_options)
1479
+ if isinstance(runtime_platform, dict):
1480
+ runtime_platform = _aws_cdk_aws_ecs_ceddda9d.RuntimePlatform(**runtime_platform)
1481
+ if isinstance(health_check, dict):
1482
+ health_check = _aws_cdk_aws_ecs_ceddda9d.HealthCheck(**health_check)
1483
+ if isinstance(task_subnets, dict):
1484
+ task_subnets = _aws_cdk_aws_ec2_ceddda9d.SubnetSelection(**task_subnets)
1485
+ if isinstance(hooks, dict):
1486
+ hooks = AppSpecHooks(**hooks)
1487
+ if isinstance(target_health_check, dict):
1488
+ target_health_check = _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck(**target_health_check)
1489
+ if __debug__:
1490
+ type_hints = typing.get_type_hints(_typecheckingstub__62e1bd800b9cb43a4625242d7d85bd0154676bc19e69266aeb4ac5bdfd4d476f)
1491
+ check_type(argname="argument capacity_provider_strategies", value=capacity_provider_strategies, expected_type=type_hints["capacity_provider_strategies"])
1492
+ check_type(argname="argument certificate", value=certificate, expected_type=type_hints["certificate"])
1493
+ check_type(argname="argument circuit_breaker", value=circuit_breaker, expected_type=type_hints["circuit_breaker"])
1494
+ check_type(argname="argument cloud_map_options", value=cloud_map_options, expected_type=type_hints["cloud_map_options"])
1495
+ check_type(argname="argument cluster", value=cluster, expected_type=type_hints["cluster"])
1496
+ check_type(argname="argument deployment_controller", value=deployment_controller, expected_type=type_hints["deployment_controller"])
1497
+ check_type(argname="argument desired_count", value=desired_count, expected_type=type_hints["desired_count"])
1498
+ check_type(argname="argument domain_name", value=domain_name, expected_type=type_hints["domain_name"])
1499
+ check_type(argname="argument domain_zone", value=domain_zone, expected_type=type_hints["domain_zone"])
1500
+ check_type(argname="argument enable_ecs_managed_tags", value=enable_ecs_managed_tags, expected_type=type_hints["enable_ecs_managed_tags"])
1501
+ check_type(argname="argument enable_execute_command", value=enable_execute_command, expected_type=type_hints["enable_execute_command"])
1502
+ check_type(argname="argument health_check_grace_period", value=health_check_grace_period, expected_type=type_hints["health_check_grace_period"])
1503
+ check_type(argname="argument idle_timeout", value=idle_timeout, expected_type=type_hints["idle_timeout"])
1504
+ check_type(argname="argument ip_address_type", value=ip_address_type, expected_type=type_hints["ip_address_type"])
1505
+ check_type(argname="argument listener_port", value=listener_port, expected_type=type_hints["listener_port"])
1506
+ check_type(argname="argument load_balancer", value=load_balancer, expected_type=type_hints["load_balancer"])
1507
+ check_type(argname="argument load_balancer_name", value=load_balancer_name, expected_type=type_hints["load_balancer_name"])
1508
+ check_type(argname="argument max_healthy_percent", value=max_healthy_percent, expected_type=type_hints["max_healthy_percent"])
1509
+ check_type(argname="argument min_healthy_percent", value=min_healthy_percent, expected_type=type_hints["min_healthy_percent"])
1510
+ check_type(argname="argument open_listener", value=open_listener, expected_type=type_hints["open_listener"])
1511
+ check_type(argname="argument propagate_tags", value=propagate_tags, expected_type=type_hints["propagate_tags"])
1512
+ check_type(argname="argument protocol", value=protocol, expected_type=type_hints["protocol"])
1513
+ check_type(argname="argument protocol_version", value=protocol_version, expected_type=type_hints["protocol_version"])
1514
+ check_type(argname="argument public_load_balancer", value=public_load_balancer, expected_type=type_hints["public_load_balancer"])
1515
+ check_type(argname="argument record_type", value=record_type, expected_type=type_hints["record_type"])
1516
+ check_type(argname="argument redirect_http", value=redirect_http, expected_type=type_hints["redirect_http"])
1517
+ check_type(argname="argument service_name", value=service_name, expected_type=type_hints["service_name"])
1518
+ check_type(argname="argument ssl_policy", value=ssl_policy, expected_type=type_hints["ssl_policy"])
1519
+ check_type(argname="argument target_protocol", value=target_protocol, expected_type=type_hints["target_protocol"])
1520
+ check_type(argname="argument task_image_options", value=task_image_options, expected_type=type_hints["task_image_options"])
1521
+ check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
1522
+ check_type(argname="argument cpu", value=cpu, expected_type=type_hints["cpu"])
1523
+ check_type(argname="argument ephemeral_storage_gib", value=ephemeral_storage_gib, expected_type=type_hints["ephemeral_storage_gib"])
1524
+ check_type(argname="argument memory_limit_mib", value=memory_limit_mib, expected_type=type_hints["memory_limit_mib"])
1525
+ check_type(argname="argument platform_version", value=platform_version, expected_type=type_hints["platform_version"])
1526
+ check_type(argname="argument runtime_platform", value=runtime_platform, expected_type=type_hints["runtime_platform"])
1527
+ check_type(argname="argument task_definition", value=task_definition, expected_type=type_hints["task_definition"])
1528
+ check_type(argname="argument assign_public_ip", value=assign_public_ip, expected_type=type_hints["assign_public_ip"])
1529
+ check_type(argname="argument container_cpu", value=container_cpu, expected_type=type_hints["container_cpu"])
1530
+ check_type(argname="argument container_memory_limit_mib", value=container_memory_limit_mib, expected_type=type_hints["container_memory_limit_mib"])
1531
+ check_type(argname="argument health_check", value=health_check, expected_type=type_hints["health_check"])
1532
+ check_type(argname="argument security_groups", value=security_groups, expected_type=type_hints["security_groups"])
1533
+ check_type(argname="argument task_subnets", value=task_subnets, expected_type=type_hints["task_subnets"])
1534
+ check_type(argname="argument access_log_bucket", value=access_log_bucket, expected_type=type_hints["access_log_bucket"])
1535
+ check_type(argname="argument access_log_prefix", value=access_log_prefix, expected_type=type_hints["access_log_prefix"])
1536
+ check_type(argname="argument api_canary_schedule", value=api_canary_schedule, expected_type=type_hints["api_canary_schedule"])
1537
+ check_type(argname="argument api_canary_thread_count", value=api_canary_thread_count, expected_type=type_hints["api_canary_thread_count"])
1538
+ check_type(argname="argument api_canary_timeout", value=api_canary_timeout, expected_type=type_hints["api_canary_timeout"])
1539
+ check_type(argname="argument api_test_steps", value=api_test_steps, expected_type=type_hints["api_test_steps"])
1540
+ check_type(argname="argument application_name", value=application_name, expected_type=type_hints["application_name"])
1541
+ check_type(argname="argument deployment_config", value=deployment_config, expected_type=type_hints["deployment_config"])
1542
+ check_type(argname="argument deployment_group_name", value=deployment_group_name, expected_type=type_hints["deployment_group_name"])
1543
+ check_type(argname="argument deployment_timeout", value=deployment_timeout, expected_type=type_hints["deployment_timeout"])
1544
+ check_type(argname="argument deregistration_delay", value=deregistration_delay, expected_type=type_hints["deregistration_delay"])
1545
+ check_type(argname="argument hooks", value=hooks, expected_type=type_hints["hooks"])
1546
+ check_type(argname="argument response_time_alarm_threshold", value=response_time_alarm_threshold, expected_type=type_hints["response_time_alarm_threshold"])
1547
+ check_type(argname="argument target_health_check", value=target_health_check, expected_type=type_hints["target_health_check"])
1548
+ check_type(argname="argument termination_wait_time", value=termination_wait_time, expected_type=type_hints["termination_wait_time"])
1549
+ check_type(argname="argument test_port", value=test_port, expected_type=type_hints["test_port"])
1550
+ self._values: typing.Dict[builtins.str, typing.Any] = {}
1551
+ if capacity_provider_strategies is not None:
1552
+ self._values["capacity_provider_strategies"] = capacity_provider_strategies
1553
+ if certificate is not None:
1554
+ self._values["certificate"] = certificate
1555
+ if circuit_breaker is not None:
1556
+ self._values["circuit_breaker"] = circuit_breaker
1557
+ if cloud_map_options is not None:
1558
+ self._values["cloud_map_options"] = cloud_map_options
1559
+ if cluster is not None:
1560
+ self._values["cluster"] = cluster
1561
+ if deployment_controller is not None:
1562
+ self._values["deployment_controller"] = deployment_controller
1563
+ if desired_count is not None:
1564
+ self._values["desired_count"] = desired_count
1565
+ if domain_name is not None:
1566
+ self._values["domain_name"] = domain_name
1567
+ if domain_zone is not None:
1568
+ self._values["domain_zone"] = domain_zone
1569
+ if enable_ecs_managed_tags is not None:
1570
+ self._values["enable_ecs_managed_tags"] = enable_ecs_managed_tags
1571
+ if enable_execute_command is not None:
1572
+ self._values["enable_execute_command"] = enable_execute_command
1573
+ if health_check_grace_period is not None:
1574
+ self._values["health_check_grace_period"] = health_check_grace_period
1575
+ if idle_timeout is not None:
1576
+ self._values["idle_timeout"] = idle_timeout
1577
+ if ip_address_type is not None:
1578
+ self._values["ip_address_type"] = ip_address_type
1579
+ if listener_port is not None:
1580
+ self._values["listener_port"] = listener_port
1581
+ if load_balancer is not None:
1582
+ self._values["load_balancer"] = load_balancer
1583
+ if load_balancer_name is not None:
1584
+ self._values["load_balancer_name"] = load_balancer_name
1585
+ if max_healthy_percent is not None:
1586
+ self._values["max_healthy_percent"] = max_healthy_percent
1587
+ if min_healthy_percent is not None:
1588
+ self._values["min_healthy_percent"] = min_healthy_percent
1589
+ if open_listener is not None:
1590
+ self._values["open_listener"] = open_listener
1591
+ if propagate_tags is not None:
1592
+ self._values["propagate_tags"] = propagate_tags
1593
+ if protocol is not None:
1594
+ self._values["protocol"] = protocol
1595
+ if protocol_version is not None:
1596
+ self._values["protocol_version"] = protocol_version
1597
+ if public_load_balancer is not None:
1598
+ self._values["public_load_balancer"] = public_load_balancer
1599
+ if record_type is not None:
1600
+ self._values["record_type"] = record_type
1601
+ if redirect_http is not None:
1602
+ self._values["redirect_http"] = redirect_http
1603
+ if service_name is not None:
1604
+ self._values["service_name"] = service_name
1605
+ if ssl_policy is not None:
1606
+ self._values["ssl_policy"] = ssl_policy
1607
+ if target_protocol is not None:
1608
+ self._values["target_protocol"] = target_protocol
1609
+ if task_image_options is not None:
1610
+ self._values["task_image_options"] = task_image_options
1611
+ if vpc is not None:
1612
+ self._values["vpc"] = vpc
1613
+ if cpu is not None:
1614
+ self._values["cpu"] = cpu
1615
+ if ephemeral_storage_gib is not None:
1616
+ self._values["ephemeral_storage_gib"] = ephemeral_storage_gib
1617
+ if memory_limit_mib is not None:
1618
+ self._values["memory_limit_mib"] = memory_limit_mib
1619
+ if platform_version is not None:
1620
+ self._values["platform_version"] = platform_version
1621
+ if runtime_platform is not None:
1622
+ self._values["runtime_platform"] = runtime_platform
1623
+ if task_definition is not None:
1624
+ self._values["task_definition"] = task_definition
1625
+ if assign_public_ip is not None:
1626
+ self._values["assign_public_ip"] = assign_public_ip
1627
+ if container_cpu is not None:
1628
+ self._values["container_cpu"] = container_cpu
1629
+ if container_memory_limit_mib is not None:
1630
+ self._values["container_memory_limit_mib"] = container_memory_limit_mib
1631
+ if health_check is not None:
1632
+ self._values["health_check"] = health_check
1633
+ if security_groups is not None:
1634
+ self._values["security_groups"] = security_groups
1635
+ if task_subnets is not None:
1636
+ self._values["task_subnets"] = task_subnets
1637
+ if access_log_bucket is not None:
1638
+ self._values["access_log_bucket"] = access_log_bucket
1639
+ if access_log_prefix is not None:
1640
+ self._values["access_log_prefix"] = access_log_prefix
1641
+ if api_canary_schedule is not None:
1642
+ self._values["api_canary_schedule"] = api_canary_schedule
1643
+ if api_canary_thread_count is not None:
1644
+ self._values["api_canary_thread_count"] = api_canary_thread_count
1645
+ if api_canary_timeout is not None:
1646
+ self._values["api_canary_timeout"] = api_canary_timeout
1647
+ if api_test_steps is not None:
1648
+ self._values["api_test_steps"] = api_test_steps
1649
+ if application_name is not None:
1650
+ self._values["application_name"] = application_name
1651
+ if deployment_config is not None:
1652
+ self._values["deployment_config"] = deployment_config
1653
+ if deployment_group_name is not None:
1654
+ self._values["deployment_group_name"] = deployment_group_name
1655
+ if deployment_timeout is not None:
1656
+ self._values["deployment_timeout"] = deployment_timeout
1657
+ if deregistration_delay is not None:
1658
+ self._values["deregistration_delay"] = deregistration_delay
1659
+ if hooks is not None:
1660
+ self._values["hooks"] = hooks
1661
+ if response_time_alarm_threshold is not None:
1662
+ self._values["response_time_alarm_threshold"] = response_time_alarm_threshold
1663
+ if target_health_check is not None:
1664
+ self._values["target_health_check"] = target_health_check
1665
+ if termination_wait_time is not None:
1666
+ self._values["termination_wait_time"] = termination_wait_time
1667
+ if test_port is not None:
1668
+ self._values["test_port"] = test_port
1669
+
1670
+ @builtins.property
1671
+ def capacity_provider_strategies(
1672
+ self,
1673
+ ) -> typing.Optional[typing.List[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy]]:
1674
+ '''A list of Capacity Provider strategies used to place a service.
1675
+
1676
+ :default: - undefined
1677
+ '''
1678
+ result = self._values.get("capacity_provider_strategies")
1679
+ return typing.cast(typing.Optional[typing.List[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy]], result)
1680
+
1681
+ @builtins.property
1682
+ def certificate(
1683
+ self,
1684
+ ) -> typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate]:
1685
+ '''Certificate Manager certificate to associate with the load balancer.
1686
+
1687
+ Setting this option will set the load balancer protocol to HTTPS.
1688
+
1689
+ :default:
1690
+
1691
+ - No certificate associated with the load balancer, if using
1692
+ the HTTP protocol. For HTTPS, a DNS-validated certificate will be
1693
+ created for the load balancer's specified domain name if a domain name
1694
+ and domain zone are specified.
1695
+ '''
1696
+ result = self._values.get("certificate")
1697
+ return typing.cast(typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate], result)
1698
+
1699
+ @builtins.property
1700
+ def circuit_breaker(
1701
+ self,
1702
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker]:
1703
+ '''Whether to enable the deployment circuit breaker.
1704
+
1705
+ If this property is defined, circuit breaker will be implicitly
1706
+ enabled.
1707
+
1708
+ :default: - disabled
1709
+ '''
1710
+ result = self._values.get("circuit_breaker")
1711
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker], result)
1712
+
1713
+ @builtins.property
1714
+ def cloud_map_options(
1715
+ self,
1716
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions]:
1717
+ '''The options for configuring an Amazon ECS service to use service discovery.
1718
+
1719
+ :default: - AWS Cloud Map service discovery is not enabled.
1720
+ '''
1721
+ result = self._values.get("cloud_map_options")
1722
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions], result)
1723
+
1724
+ @builtins.property
1725
+ def cluster(self) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster]:
1726
+ '''The name of the cluster that hosts the service.
1727
+
1728
+ If a cluster is specified, the vpc construct should be omitted. Alternatively, you can omit both cluster and vpc.
1729
+
1730
+ :default: - create a new cluster; if both cluster and vpc are omitted, a new VPC will be created for you.
1731
+ '''
1732
+ result = self._values.get("cluster")
1733
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster], result)
1734
+
1735
+ @builtins.property
1736
+ def deployment_controller(
1737
+ self,
1738
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.DeploymentController]:
1739
+ '''Specifies which deployment controller to use for the service.
1740
+
1741
+ For more information, see
1742
+ `Amazon ECS Deployment Types <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/deployment-types.html>`_
1743
+
1744
+ :default: - Rolling update (ECS)
1745
+ '''
1746
+ result = self._values.get("deployment_controller")
1747
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.DeploymentController], result)
1748
+
1749
+ @builtins.property
1750
+ def desired_count(self) -> typing.Optional[jsii.Number]:
1751
+ '''The desired number of instantiations of the task definition to keep running on the service.
1752
+
1753
+ The minimum value is 1
1754
+
1755
+ :default:
1756
+
1757
+ - The default is 1 for all new services and uses the existing service's desired count
1758
+ when updating an existing service.
1759
+ '''
1760
+ result = self._values.get("desired_count")
1761
+ return typing.cast(typing.Optional[jsii.Number], result)
1762
+
1763
+ @builtins.property
1764
+ def domain_name(self) -> typing.Optional[builtins.str]:
1765
+ '''The domain name for the service, e.g. "api.example.com.".
1766
+
1767
+ :default: - No domain name.
1768
+ '''
1769
+ result = self._values.get("domain_name")
1770
+ return typing.cast(typing.Optional[builtins.str], result)
1771
+
1772
+ @builtins.property
1773
+ def domain_zone(self) -> typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone]:
1774
+ '''The Route53 hosted zone for the domain, e.g. "example.com.".
1775
+
1776
+ :default: - No Route53 hosted domain zone.
1777
+ '''
1778
+ result = self._values.get("domain_zone")
1779
+ return typing.cast(typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone], result)
1780
+
1781
+ @builtins.property
1782
+ def enable_ecs_managed_tags(self) -> typing.Optional[builtins.bool]:
1783
+ '''Specifies whether to enable Amazon ECS managed tags for the tasks within the service.
1784
+
1785
+ For more information, see
1786
+ `Tagging Your Amazon ECS Resources <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-using-tags.html>`_
1787
+
1788
+ :default: false
1789
+ '''
1790
+ result = self._values.get("enable_ecs_managed_tags")
1791
+ return typing.cast(typing.Optional[builtins.bool], result)
1792
+
1793
+ @builtins.property
1794
+ def enable_execute_command(self) -> typing.Optional[builtins.bool]:
1795
+ '''Whether ECS Exec should be enabled.
1796
+
1797
+ :default: - false
1798
+ '''
1799
+ result = self._values.get("enable_execute_command")
1800
+ return typing.cast(typing.Optional[builtins.bool], result)
1801
+
1802
+ @builtins.property
1803
+ def health_check_grace_period(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
1804
+ '''The period of time, in seconds, that the Amazon ECS service scheduler ignores unhealthy Elastic Load Balancing target health checks after a task has first started.
1805
+
1806
+ :default: - defaults to 60 seconds if at least one load balancer is in-use and it is not already set
1807
+ '''
1808
+ result = self._values.get("health_check_grace_period")
1809
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
1810
+
1811
+ @builtins.property
1812
+ def idle_timeout(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
1813
+ '''The load balancer idle timeout, in seconds.
1814
+
1815
+ Can be between 1 and 4000 seconds
1816
+
1817
+ :default: - CloudFormation sets idle timeout to 60 seconds
1818
+ '''
1819
+ result = self._values.get("idle_timeout")
1820
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
1821
+
1822
+ @builtins.property
1823
+ def ip_address_type(
1824
+ self,
1825
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType]:
1826
+ '''The type of IP address to use.
1827
+
1828
+ :default: - IpAddressType.IPV4
1829
+ '''
1830
+ result = self._values.get("ip_address_type")
1831
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType], result)
1832
+
1833
+ @builtins.property
1834
+ def listener_port(self) -> typing.Optional[jsii.Number]:
1835
+ '''Listener port of the application load balancer that will serve traffic to the service.
1836
+
1837
+ :default:
1838
+
1839
+ - The default listener port is determined from the protocol (port 80 for HTTP,
1840
+ port 443 for HTTPS). A domain name and zone must be also be specified if using HTTPS.
1841
+ '''
1842
+ result = self._values.get("listener_port")
1843
+ return typing.cast(typing.Optional[jsii.Number], result)
1844
+
1845
+ @builtins.property
1846
+ def load_balancer(
1847
+ self,
1848
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer]:
1849
+ '''The application load balancer that will serve traffic to the service.
1850
+
1851
+ The VPC attribute of a load balancer must be specified for it to be used
1852
+ to create a new service with this pattern.
1853
+
1854
+ [disable-awslint:ref-via-interface]
1855
+
1856
+ :default: - a new load balancer will be created.
1857
+ '''
1858
+ result = self._values.get("load_balancer")
1859
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer], result)
1860
+
1861
+ @builtins.property
1862
+ def load_balancer_name(self) -> typing.Optional[builtins.str]:
1863
+ '''Name of the load balancer.
1864
+
1865
+ :default: - Automatically generated name.
1866
+ '''
1867
+ result = self._values.get("load_balancer_name")
1868
+ return typing.cast(typing.Optional[builtins.str], result)
1869
+
1870
+ @builtins.property
1871
+ def max_healthy_percent(self) -> typing.Optional[jsii.Number]:
1872
+ '''The maximum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that can run in a service during a deployment.
1873
+
1874
+ :default: - 100 if daemon, otherwise 200
1875
+ '''
1876
+ result = self._values.get("max_healthy_percent")
1877
+ return typing.cast(typing.Optional[jsii.Number], result)
1878
+
1879
+ @builtins.property
1880
+ def min_healthy_percent(self) -> typing.Optional[jsii.Number]:
1881
+ '''The minimum number of tasks, specified as a percentage of the Amazon ECS service's DesiredCount value, that must continue to run and remain healthy during a deployment.
1882
+
1883
+ :default: - 0 if daemon, otherwise 50
1884
+ '''
1885
+ result = self._values.get("min_healthy_percent")
1886
+ return typing.cast(typing.Optional[jsii.Number], result)
1887
+
1888
+ @builtins.property
1889
+ def open_listener(self) -> typing.Optional[builtins.bool]:
1890
+ '''Determines whether or not the Security Group for the Load Balancer's Listener will be open to all traffic by default.
1891
+
1892
+ :default: true -- The security group allows ingress from all IP addresses.
1893
+ '''
1894
+ result = self._values.get("open_listener")
1895
+ return typing.cast(typing.Optional[builtins.bool], result)
1896
+
1897
+ @builtins.property
1898
+ def propagate_tags(
1899
+ self,
1900
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource]:
1901
+ '''Specifies whether to propagate the tags from the task definition or the service to the tasks in the service.
1902
+
1903
+ Tags can only be propagated to the tasks within the service during service creation.
1904
+
1905
+ :default: - none
1906
+ '''
1907
+ result = self._values.get("propagate_tags")
1908
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource], result)
1909
+
1910
+ @builtins.property
1911
+ def protocol(
1912
+ self,
1913
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol]:
1914
+ '''The protocol for connections from clients to the load balancer.
1915
+
1916
+ The load balancer port is determined from the protocol (port 80 for
1917
+ HTTP, port 443 for HTTPS). If HTTPS, either a certificate or domain
1918
+ name and domain zone must also be specified.
1919
+
1920
+ :default:
1921
+
1922
+ HTTP. If a certificate is specified, the protocol will be
1923
+ set by default to HTTPS.
1924
+ '''
1925
+ result = self._values.get("protocol")
1926
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol], result)
1927
+
1928
+ @builtins.property
1929
+ def protocol_version(
1930
+ self,
1931
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion]:
1932
+ '''The protocol version to use.
1933
+
1934
+ :default: ApplicationProtocolVersion.HTTP1
1935
+ '''
1936
+ result = self._values.get("protocol_version")
1937
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion], result)
1938
+
1939
+ @builtins.property
1940
+ def public_load_balancer(self) -> typing.Optional[builtins.bool]:
1941
+ '''Determines whether the Load Balancer will be internet-facing.
1942
+
1943
+ :default: true
1944
+ '''
1945
+ result = self._values.get("public_load_balancer")
1946
+ return typing.cast(typing.Optional[builtins.bool], result)
1947
+
1948
+ @builtins.property
1949
+ def record_type(
1950
+ self,
1951
+ ) -> typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType]:
1952
+ '''Specifies whether the Route53 record should be a CNAME, an A record using the Alias feature or no record at all.
1953
+
1954
+ This is useful if you need to work with DNS systems that do not support alias records.
1955
+
1956
+ :default: ApplicationLoadBalancedServiceRecordType.ALIAS
1957
+ '''
1958
+ result = self._values.get("record_type")
1959
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType], result)
1960
+
1961
+ @builtins.property
1962
+ def redirect_http(self) -> typing.Optional[builtins.bool]:
1963
+ '''Specifies whether the load balancer should redirect traffic on port 80 to the {@link listenerPort} to support HTTP->HTTPS redirects.
1964
+
1965
+ This is only valid if the protocol of the ALB is HTTPS.
1966
+
1967
+ :default: false
1968
+ '''
1969
+ result = self._values.get("redirect_http")
1970
+ return typing.cast(typing.Optional[builtins.bool], result)
1971
+
1972
+ @builtins.property
1973
+ def service_name(self) -> typing.Optional[builtins.str]:
1974
+ '''The name of the service.
1975
+
1976
+ :default: - CloudFormation-generated name.
1977
+ '''
1978
+ result = self._values.get("service_name")
1979
+ return typing.cast(typing.Optional[builtins.str], result)
1980
+
1981
+ @builtins.property
1982
+ def ssl_policy(
1983
+ self,
1984
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy]:
1985
+ '''The security policy that defines which ciphers and protocols are supported by the ALB Listener.
1986
+
1987
+ :default: - The recommended elastic load balancing security policy
1988
+ '''
1989
+ result = self._values.get("ssl_policy")
1990
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy], result)
1991
+
1992
+ @builtins.property
1993
+ def target_protocol(
1994
+ self,
1995
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol]:
1996
+ '''The protocol for connections from the load balancer to the ECS tasks.
1997
+
1998
+ The default target port is determined from the protocol (port 80 for
1999
+ HTTP, port 443 for HTTPS).
2000
+
2001
+ :default: HTTP.
2002
+ '''
2003
+ result = self._values.get("target_protocol")
2004
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol], result)
2005
+
2006
+ @builtins.property
2007
+ def task_image_options(
2008
+ self,
2009
+ ) -> typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions]:
2010
+ '''The properties required to create a new task definition.
2011
+
2012
+ TaskDefinition or TaskImageOptions must be specified, but not both.
2013
+
2014
+ :default: none
2015
+ '''
2016
+ result = self._values.get("task_image_options")
2017
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions], result)
2018
+
2019
+ @builtins.property
2020
+ def vpc(self) -> typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc]:
2021
+ '''The VPC where the container instances will be launched or the elastic network interfaces (ENIs) will be deployed.
2022
+
2023
+ If a vpc is specified, the cluster construct should be omitted. Alternatively, you can omit both vpc and cluster.
2024
+
2025
+ :default: - uses the VPC defined in the cluster or creates a new VPC.
2026
+ '''
2027
+ result = self._values.get("vpc")
2028
+ return typing.cast(typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc], result)
2029
+
2030
+ @builtins.property
2031
+ def cpu(self) -> typing.Optional[jsii.Number]:
2032
+ '''The number of cpu units used by the task.
2033
+
2034
+ Valid values, which determines your range of valid values for the memory parameter:
2035
+
2036
+ 256 (.25 vCPU) - Available memory values: 0.5GB, 1GB, 2GB
2037
+
2038
+ 512 (.5 vCPU) - Available memory values: 1GB, 2GB, 3GB, 4GB
2039
+
2040
+ 1024 (1 vCPU) - Available memory values: 2GB, 3GB, 4GB, 5GB, 6GB, 7GB, 8GB
2041
+
2042
+ 2048 (2 vCPU) - Available memory values: Between 4GB and 16GB in 1GB increments
2043
+
2044
+ 4096 (4 vCPU) - Available memory values: Between 8GB and 30GB in 1GB increments
2045
+
2046
+ 8192 (8 vCPU) - Available memory values: Between 16GB and 60GB in 4GB increments
2047
+
2048
+ 16384 (16 vCPU) - Available memory values: Between 32GB and 120GB in 8GB increments
2049
+
2050
+ This default is set in the underlying FargateTaskDefinition construct.
2051
+
2052
+ :default: 256
2053
+ '''
2054
+ result = self._values.get("cpu")
2055
+ return typing.cast(typing.Optional[jsii.Number], result)
2056
+
2057
+ @builtins.property
2058
+ def ephemeral_storage_gib(self) -> typing.Optional[jsii.Number]:
2059
+ '''The amount (in GiB) of ephemeral storage to be allocated to the task.
2060
+
2061
+ The minimum supported value is ``21`` GiB and the maximum supported value is ``200`` GiB.
2062
+
2063
+ Only supported in Fargate platform version 1.4.0 or later.
2064
+
2065
+ :default: Undefined, in which case, the task will receive 20GiB ephemeral storage.
2066
+ '''
2067
+ result = self._values.get("ephemeral_storage_gib")
2068
+ return typing.cast(typing.Optional[jsii.Number], result)
2069
+
2070
+ @builtins.property
2071
+ def memory_limit_mib(self) -> typing.Optional[jsii.Number]:
2072
+ '''The amount (in MiB) of memory used by the task.
2073
+
2074
+ This field is required and you must use one of the following values, which determines your range of valid values
2075
+ for the cpu parameter:
2076
+
2077
+ 512 (0.5 GB), 1024 (1 GB), 2048 (2 GB) - Available cpu values: 256 (.25 vCPU)
2078
+
2079
+ 1024 (1 GB), 2048 (2 GB), 3072 (3 GB), 4096 (4 GB) - Available cpu values: 512 (.5 vCPU)
2080
+
2081
+ 2048 (2 GB), 3072 (3 GB), 4096 (4 GB), 5120 (5 GB), 6144 (6 GB), 7168 (7 GB), 8192 (8 GB) - Available cpu values: 1024 (1 vCPU)
2082
+
2083
+ Between 4096 (4 GB) and 16384 (16 GB) in increments of 1024 (1 GB) - Available cpu values: 2048 (2 vCPU)
2084
+
2085
+ Between 8192 (8 GB) and 30720 (30 GB) in increments of 1024 (1 GB) - Available cpu values: 4096 (4 vCPU)
2086
+
2087
+ Between 16384 (16 GB) and 61440 (60 GB) in increments of 4096 (4 GB) - Available cpu values: 8192 (8 vCPU)
2088
+
2089
+ Between 32768 (32 GB) and 122880 (120 GB) in increments of 8192 (8 GB) - Available cpu values: 16384 (16 vCPU)
2090
+
2091
+ This default is set in the underlying FargateTaskDefinition construct.
2092
+
2093
+ :default: 512
2094
+ '''
2095
+ result = self._values.get("memory_limit_mib")
2096
+ return typing.cast(typing.Optional[jsii.Number], result)
2097
+
2098
+ @builtins.property
2099
+ def platform_version(
2100
+ self,
2101
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion]:
2102
+ '''The platform version on which to run your service.
2103
+
2104
+ If one is not specified, the LATEST platform version is used by default. For more information, see
2105
+ `AWS Fargate Platform Versions <https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html>`_
2106
+ in the Amazon Elastic Container Service Developer Guide.
2107
+
2108
+ :default: Latest
2109
+ '''
2110
+ result = self._values.get("platform_version")
2111
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion], result)
2112
+
2113
+ @builtins.property
2114
+ def runtime_platform(
2115
+ self,
2116
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform]:
2117
+ '''The runtime platform of the task definition.
2118
+
2119
+ :default: - If the property is undefined, ``operatingSystemFamily`` is LINUX and ``cpuArchitecture`` is X86_64
2120
+ '''
2121
+ result = self._values.get("runtime_platform")
2122
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform], result)
2123
+
2124
+ @builtins.property
2125
+ def task_definition(
2126
+ self,
2127
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition]:
2128
+ '''The task definition to use for tasks in the service. TaskDefinition or TaskImageOptions must be specified, but not both.
2129
+
2130
+ [disable-awslint:ref-via-interface]
2131
+
2132
+ :default: - none
2133
+ '''
2134
+ result = self._values.get("task_definition")
2135
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition], result)
2136
+
2137
+ @builtins.property
2138
+ def assign_public_ip(self) -> typing.Optional[builtins.bool]:
2139
+ '''Determines whether the service will be assigned a public IP address.
2140
+
2141
+ :default: false
2142
+ '''
2143
+ result = self._values.get("assign_public_ip")
2144
+ return typing.cast(typing.Optional[builtins.bool], result)
2145
+
2146
+ @builtins.property
2147
+ def container_cpu(self) -> typing.Optional[jsii.Number]:
2148
+ '''The minimum number of CPU units to reserve for the container.
2149
+
2150
+ :default: - No minimum CPU units reserved.
2151
+ '''
2152
+ result = self._values.get("container_cpu")
2153
+ return typing.cast(typing.Optional[jsii.Number], result)
2154
+
2155
+ @builtins.property
2156
+ def container_memory_limit_mib(self) -> typing.Optional[jsii.Number]:
2157
+ '''The amount (in MiB) of memory to present to the container.
2158
+
2159
+ If your container attempts to exceed the allocated memory, the container
2160
+ is terminated.
2161
+
2162
+ :default: - No memory limit.
2163
+ '''
2164
+ result = self._values.get("container_memory_limit_mib")
2165
+ return typing.cast(typing.Optional[jsii.Number], result)
2166
+
2167
+ @builtins.property
2168
+ def health_check(self) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.HealthCheck]:
2169
+ '''The health check command and associated configuration parameters for the container.
2170
+
2171
+ :default: - Health check configuration from container.
2172
+ '''
2173
+ result = self._values.get("health_check")
2174
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.HealthCheck], result)
2175
+
2176
+ @builtins.property
2177
+ def security_groups(
2178
+ self,
2179
+ ) -> typing.Optional[typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]]:
2180
+ '''The security groups to associate with the service.
2181
+
2182
+ If you do not specify a security group, a new security group is created.
2183
+
2184
+ :default: - A new security group is created.
2185
+ '''
2186
+ result = self._values.get("security_groups")
2187
+ return typing.cast(typing.Optional[typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]], result)
2188
+
2189
+ @builtins.property
2190
+ def task_subnets(
2191
+ self,
2192
+ ) -> typing.Optional[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection]:
2193
+ '''The subnets to associate with the service.
2194
+
2195
+ :default: - Public subnets if ``assignPublicIp`` is set, otherwise the first available one of Private, Isolated, Public, in that order.
2196
+ '''
2197
+ result = self._values.get("task_subnets")
2198
+ return typing.cast(typing.Optional[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection], result)
2199
+
2200
+ @builtins.property
2201
+ def access_log_bucket(self) -> typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket]:
2202
+ '''The bucket to use for access logs from the Application Load Balancer.
2203
+
2204
+ :default: - a new S3 bucket will be created
2205
+ '''
2206
+ result = self._values.get("access_log_bucket")
2207
+ return typing.cast(typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket], result)
2208
+
2209
+ @builtins.property
2210
+ def access_log_prefix(self) -> typing.Optional[builtins.str]:
2211
+ '''The prefix to use for access logs from the Application Load Balancer.
2212
+
2213
+ :default: - none
2214
+ '''
2215
+ result = self._values.get("access_log_prefix")
2216
+ return typing.cast(typing.Optional[builtins.str], result)
2217
+
2218
+ @builtins.property
2219
+ def api_canary_schedule(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2220
+ '''The frequency for running the api canaries.
2221
+
2222
+ :default: - 5 minutes
2223
+ '''
2224
+ result = self._values.get("api_canary_schedule")
2225
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
2226
+
2227
+ @builtins.property
2228
+ def api_canary_thread_count(self) -> typing.Optional[jsii.Number]:
2229
+ '''The number of threads to run concurrently for the synthetic test.
2230
+
2231
+ :default: - 20
2232
+ '''
2233
+ result = self._values.get("api_canary_thread_count")
2234
+ return typing.cast(typing.Optional[jsii.Number], result)
2235
+
2236
+ @builtins.property
2237
+ def api_canary_timeout(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2238
+ '''The threshold for how long a api canary can take to run.
2239
+
2240
+ :default: - no alarm is created for test duration
2241
+ '''
2242
+ result = self._values.get("api_canary_timeout")
2243
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
2244
+
2245
+ @builtins.property
2246
+ def api_test_steps(self) -> typing.Optional[typing.List[ApiTestStep]]:
2247
+ '''The steps to run in the canary.
2248
+
2249
+ :default: - no synthetic test will be created
2250
+ '''
2251
+ result = self._values.get("api_test_steps")
2252
+ return typing.cast(typing.Optional[typing.List[ApiTestStep]], result)
2253
+
2254
+ @builtins.property
2255
+ def application_name(self) -> typing.Optional[builtins.str]:
2256
+ '''The physical, human-readable name of the CodeDeploy Application.
2257
+
2258
+ :default: an auto-generated name will be used
2259
+ '''
2260
+ result = self._values.get("application_name")
2261
+ return typing.cast(typing.Optional[builtins.str], result)
2262
+
2263
+ @builtins.property
2264
+ def deployment_config(
2265
+ self,
2266
+ ) -> typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig]:
2267
+ '''The deployment configuration to use for the deployment group.
2268
+
2269
+ :default: - EcsDeploymentConfig.ALL_AT_ONCE
2270
+ '''
2271
+ result = self._values.get("deployment_config")
2272
+ return typing.cast(typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig], result)
2273
+
2274
+ @builtins.property
2275
+ def deployment_group_name(self) -> typing.Optional[builtins.str]:
2276
+ '''The physical, human-readable name of the CodeDeploy Deployment Group.
2277
+
2278
+ :default: An auto-generated name will be used.
2279
+ '''
2280
+ result = self._values.get("deployment_group_name")
2281
+ return typing.cast(typing.Optional[builtins.str], result)
2282
+
2283
+ @builtins.property
2284
+ def deployment_timeout(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2285
+ '''The timeout for a CodeDeploy deployment.
2286
+
2287
+ :default: - 60 minutes
2288
+ '''
2289
+ result = self._values.get("deployment_timeout")
2290
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
2291
+
2292
+ @builtins.property
2293
+ def deregistration_delay(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2294
+ '''The amount of time for ELB to wait before changing the state of a deregistering target from 'draining' to 'unused'.
2295
+
2296
+ :default: - 300 seconds
2297
+ '''
2298
+ result = self._values.get("deregistration_delay")
2299
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
2300
+
2301
+ @builtins.property
2302
+ def hooks(self) -> typing.Optional[AppSpecHooks]:
2303
+ '''Optional lifecycle hooks.
2304
+
2305
+ :default: - no lifecycle hooks
2306
+ '''
2307
+ result = self._values.get("hooks")
2308
+ return typing.cast(typing.Optional[AppSpecHooks], result)
2309
+
2310
+ @builtins.property
2311
+ def response_time_alarm_threshold(
2312
+ self,
2313
+ ) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2314
+ '''The threshold for response time alarm.
2315
+
2316
+ :default: - no alarm will be created
2317
+ '''
2318
+ result = self._values.get("response_time_alarm_threshold")
2319
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
224
2320
 
225
2321
  @builtins.property
226
- def existing_lambda_obj(
2322
+ def target_health_check(
227
2323
  self,
228
- ) -> typing.Optional[_aws_cdk_aws_lambda_ceddda9d.Function]:
229
- '''Existing instance of Lambda Function object, providing both this and ``lambdaFunctionProps`` will cause an error.
2324
+ ) -> typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck]:
2325
+ '''The healthcheck to configure on the Application Load Balancer target groups.
230
2326
 
231
- :default: - None
2327
+ :default: - no health check is configured
232
2328
  '''
233
- result = self._values.get("existing_lambda_obj")
234
- return typing.cast(typing.Optional[_aws_cdk_aws_lambda_ceddda9d.Function], result)
2329
+ result = self._values.get("target_health_check")
2330
+ return typing.cast(typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck], result)
235
2331
 
236
2332
  @builtins.property
237
- def hosted_zone(self) -> typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone]:
238
- '''Optional Route53 hosted zone to create alias record for the custom domain.
2333
+ def termination_wait_time(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2334
+ '''The time to wait before terminating the original (blue) task set.
239
2335
 
240
- :default: - no Route53 alias record created
2336
+ :default: - 10 minutes
241
2337
  '''
242
- result = self._values.get("hosted_zone")
243
- return typing.cast(typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone], result)
2338
+ result = self._values.get("termination_wait_time")
2339
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
244
2340
 
245
2341
  @builtins.property
246
- def lambda_function_props(
247
- self,
248
- ) -> typing.Optional[_aws_cdk_aws_lambda_ceddda9d.FunctionProps]:
249
- '''User provided props to override the default props for the Lambda function.'''
250
- result = self._values.get("lambda_function_props")
251
- return typing.cast(typing.Optional[_aws_cdk_aws_lambda_ceddda9d.FunctionProps], result)
2342
+ def test_port(self) -> typing.Optional[jsii.Number]:
2343
+ '''The port to use for test traffic on the listener.
252
2344
 
253
- @builtins.property
254
- def log_group_props(
255
- self,
256
- ) -> typing.Optional[_aws_cdk_aws_logs_ceddda9d.LogGroupProps]:
257
- result = self._values.get("log_group_props")
258
- return typing.cast(typing.Optional[_aws_cdk_aws_logs_ceddda9d.LogGroupProps], result)
2345
+ :default: - listenerPort + 1
2346
+ '''
2347
+ result = self._values.get("test_port")
2348
+ return typing.cast(typing.Optional[jsii.Number], result)
259
2349
 
260
2350
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
261
2351
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -264,89 +2354,79 @@ class ApiGatewayToLambdaProps:
264
2354
  return not (rhs == self)
265
2355
 
266
2356
  def __repr__(self) -> str:
267
- return "ApiGatewayToLambdaProps(%s)" % ", ".join(
2357
+ return "ApplicationLoadBalancedCodeDeployedFargateServiceProps(%s)" % ", ".join(
268
2358
  k + "=" + repr(v) for k, v in self._values.items()
269
2359
  )
270
2360
 
271
2361
 
272
2362
  @jsii.data_type(
273
- jsii_type="must-cdk.AutoScalingProps",
2363
+ jsii_type="must-cdk.AwsvpcConfiguration",
274
2364
  jsii_struct_bases=[],
275
2365
  name_mapping={
276
- "max_capacity": "maxCapacity",
277
- "min_capacity": "minCapacity",
278
- "target_cpu_utilization_percent": "targetCpuUtilizationPercent",
279
- "scale_in_cooldown_sec": "scaleInCooldownSec",
280
- "scale_out_cooldown_sec": "scaleOutCooldownSec",
2366
+ "assign_public_ip": "assignPublicIp",
2367
+ "security_groups": "securityGroups",
2368
+ "vpc": "vpc",
2369
+ "vpc_subnets": "vpcSubnets",
281
2370
  },
282
2371
  )
283
- class AutoScalingProps:
2372
+ class AwsvpcConfiguration:
284
2373
  def __init__(
285
2374
  self,
286
2375
  *,
287
- max_capacity: jsii.Number,
288
- min_capacity: jsii.Number,
289
- target_cpu_utilization_percent: jsii.Number,
290
- scale_in_cooldown_sec: typing.Optional[jsii.Number] = None,
291
- scale_out_cooldown_sec: typing.Optional[jsii.Number] = None,
2376
+ assign_public_ip: builtins.bool,
2377
+ security_groups: typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup],
2378
+ vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
2379
+ vpc_subnets: typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]],
292
2380
  ) -> None:
293
- '''Configuration for ECS service autoscaling.
2381
+ '''Network configuration for ECS services that have a network type of ``awsvpc``.
294
2382
 
295
- :param max_capacity: Maximum number of tasks.
296
- :param min_capacity: Minimum number of tasks.
297
- :param target_cpu_utilization_percent: Target CPU utilization percentage.
298
- :param scale_in_cooldown_sec: Cooldown time in seconds after scale-in.
299
- :param scale_out_cooldown_sec: Cooldown time in seconds after scale-out.
2383
+ :param assign_public_ip: Assign a public IP address to the task.
2384
+ :param security_groups: The Security Groups to use for the task.
2385
+ :param vpc: The VPC to use for the task.
2386
+ :param vpc_subnets: The Subnets to use for the task.
300
2387
  '''
2388
+ if isinstance(vpc_subnets, dict):
2389
+ vpc_subnets = _aws_cdk_aws_ec2_ceddda9d.SubnetSelection(**vpc_subnets)
301
2390
  if __debug__:
302
- type_hints = typing.get_type_hints(_typecheckingstub__d0ea30b15daf73de785b4991457443ee0ca220224fbd08155a17d86c67413930)
303
- check_type(argname="argument max_capacity", value=max_capacity, expected_type=type_hints["max_capacity"])
304
- check_type(argname="argument min_capacity", value=min_capacity, expected_type=type_hints["min_capacity"])
305
- check_type(argname="argument target_cpu_utilization_percent", value=target_cpu_utilization_percent, expected_type=type_hints["target_cpu_utilization_percent"])
306
- check_type(argname="argument scale_in_cooldown_sec", value=scale_in_cooldown_sec, expected_type=type_hints["scale_in_cooldown_sec"])
307
- check_type(argname="argument scale_out_cooldown_sec", value=scale_out_cooldown_sec, expected_type=type_hints["scale_out_cooldown_sec"])
2391
+ type_hints = typing.get_type_hints(_typecheckingstub__118fc20114c4ef938b334440fbc2357c4fa373cddf068764a9bcfcda49fe2c32)
2392
+ check_type(argname="argument assign_public_ip", value=assign_public_ip, expected_type=type_hints["assign_public_ip"])
2393
+ check_type(argname="argument security_groups", value=security_groups, expected_type=type_hints["security_groups"])
2394
+ check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
2395
+ check_type(argname="argument vpc_subnets", value=vpc_subnets, expected_type=type_hints["vpc_subnets"])
308
2396
  self._values: typing.Dict[builtins.str, typing.Any] = {
309
- "max_capacity": max_capacity,
310
- "min_capacity": min_capacity,
311
- "target_cpu_utilization_percent": target_cpu_utilization_percent,
2397
+ "assign_public_ip": assign_public_ip,
2398
+ "security_groups": security_groups,
2399
+ "vpc": vpc,
2400
+ "vpc_subnets": vpc_subnets,
312
2401
  }
313
- if scale_in_cooldown_sec is not None:
314
- self._values["scale_in_cooldown_sec"] = scale_in_cooldown_sec
315
- if scale_out_cooldown_sec is not None:
316
- self._values["scale_out_cooldown_sec"] = scale_out_cooldown_sec
317
2402
 
318
2403
  @builtins.property
319
- def max_capacity(self) -> jsii.Number:
320
- '''Maximum number of tasks.'''
321
- result = self._values.get("max_capacity")
322
- assert result is not None, "Required property 'max_capacity' is missing"
323
- return typing.cast(jsii.Number, result)
324
-
325
- @builtins.property
326
- def min_capacity(self) -> jsii.Number:
327
- '''Minimum number of tasks.'''
328
- result = self._values.get("min_capacity")
329
- assert result is not None, "Required property 'min_capacity' is missing"
330
- return typing.cast(jsii.Number, result)
2404
+ def assign_public_ip(self) -> builtins.bool:
2405
+ '''Assign a public IP address to the task.'''
2406
+ result = self._values.get("assign_public_ip")
2407
+ assert result is not None, "Required property 'assign_public_ip' is missing"
2408
+ return typing.cast(builtins.bool, result)
331
2409
 
332
2410
  @builtins.property
333
- def target_cpu_utilization_percent(self) -> jsii.Number:
334
- '''Target CPU utilization percentage.'''
335
- result = self._values.get("target_cpu_utilization_percent")
336
- assert result is not None, "Required property 'target_cpu_utilization_percent' is missing"
337
- return typing.cast(jsii.Number, result)
2411
+ def security_groups(self) -> typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]:
2412
+ '''The Security Groups to use for the task.'''
2413
+ result = self._values.get("security_groups")
2414
+ assert result is not None, "Required property 'security_groups' is missing"
2415
+ return typing.cast(typing.List[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup], result)
338
2416
 
339
2417
  @builtins.property
340
- def scale_in_cooldown_sec(self) -> typing.Optional[jsii.Number]:
341
- '''Cooldown time in seconds after scale-in.'''
342
- result = self._values.get("scale_in_cooldown_sec")
343
- return typing.cast(typing.Optional[jsii.Number], result)
2418
+ def vpc(self) -> _aws_cdk_aws_ec2_ceddda9d.IVpc:
2419
+ '''The VPC to use for the task.'''
2420
+ result = self._values.get("vpc")
2421
+ assert result is not None, "Required property 'vpc' is missing"
2422
+ return typing.cast(_aws_cdk_aws_ec2_ceddda9d.IVpc, result)
344
2423
 
345
2424
  @builtins.property
346
- def scale_out_cooldown_sec(self) -> typing.Optional[jsii.Number]:
347
- '''Cooldown time in seconds after scale-out.'''
348
- result = self._values.get("scale_out_cooldown_sec")
349
- return typing.cast(typing.Optional[jsii.Number], result)
2425
+ def vpc_subnets(self) -> _aws_cdk_aws_ec2_ceddda9d.SubnetSelection:
2426
+ '''The Subnets to use for the task.'''
2427
+ result = self._values.get("vpc_subnets")
2428
+ assert result is not None, "Required property 'vpc_subnets' is missing"
2429
+ return typing.cast(_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, result)
350
2430
 
351
2431
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
352
2432
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -355,221 +2435,352 @@ class AutoScalingProps:
355
2435
  return not (rhs == self)
356
2436
 
357
2437
  def __repr__(self) -> str:
358
- return "AutoScalingProps(%s)" % ", ".join(
2438
+ return "AwsvpcConfiguration(%s)" % ", ".join(
359
2439
  k + "=" + repr(v) for k, v in self._values.items()
360
2440
  )
361
2441
 
362
2442
 
363
- class EcsCodeDeploy(
2443
+ class EcsAppSpec(metaclass=jsii.JSIIMeta, jsii_type="must-cdk.EcsAppSpec"):
2444
+ '''Represents an AppSpec to be used for ECS services.
2445
+
2446
+ see: https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-resources.html#reference-appspec-file-structure-resources-ecs
2447
+ '''
2448
+
2449
+ def __init__(
2450
+ self,
2451
+ target_service: typing.Union["TargetService", typing.Dict[builtins.str, typing.Any]],
2452
+ *,
2453
+ after_allow_test_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
2454
+ after_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
2455
+ after_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
2456
+ before_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
2457
+ before_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
2458
+ ) -> None:
2459
+ '''
2460
+ :param target_service: -
2461
+ :param after_allow_test_traffic: Lambda or ARN of a lambda to run tasks after the test listener serves traffic to the replacement task set.
2462
+ :param after_allow_traffic: Lambda or ARN of a lambda to run tasks after the second target group serves traffic to the replacement task set.
2463
+ :param after_install: Lambda or ARN of a lambda to run tasks after the replacement task set is created and one of the target groups is associated with it.
2464
+ :param before_allow_traffic: Lambda or ARN of a lambda to run tasks after the second target group is associated with the replacement task set, but before traffic is shifted to the replacement task set.
2465
+ :param before_install: Lambda or ARN of a lambda to run tasks before the replacement task set is created.
2466
+ '''
2467
+ if __debug__:
2468
+ type_hints = typing.get_type_hints(_typecheckingstub__488a8c9ea1d87bab23875ab658b9bdf8db1aab92975455fe1eac82c979bbf1f2)
2469
+ check_type(argname="argument target_service", value=target_service, expected_type=type_hints["target_service"])
2470
+ hooks = AppSpecHooks(
2471
+ after_allow_test_traffic=after_allow_test_traffic,
2472
+ after_allow_traffic=after_allow_traffic,
2473
+ after_install=after_install,
2474
+ before_allow_traffic=before_allow_traffic,
2475
+ before_install=before_install,
2476
+ )
2477
+
2478
+ jsii.create(self.__class__, self, [target_service, hooks])
2479
+
2480
+ @jsii.member(jsii_name="toString")
2481
+ def to_string(self) -> builtins.str:
2482
+ '''Render JSON string for this AppSpec to be used.
2483
+
2484
+ :return: string representation of this AppSpec
2485
+ '''
2486
+ return typing.cast(builtins.str, jsii.invoke(self, "toString", []))
2487
+
2488
+
2489
+ class EcsDeployment(
364
2490
  _constructs_77d1e7e8.Construct,
365
2491
  metaclass=jsii.JSIIMeta,
366
- jsii_type="must-cdk.EcsCodeDeploy",
2492
+ jsii_type="must-cdk.EcsDeployment",
367
2493
  ):
2494
+ '''A CodeDeploy Deployment for a Amazon ECS service DeploymentGroup.
2495
+
2496
+ An EcsDeploymentGroup
2497
+ must only have 1 EcsDeployment. This limit is enforced by removing the scope and id
2498
+ from the constructor. The scope will always be set to the EcsDeploymentGroup
2499
+ and the id will always be set to the string 'Deployment' to force an error if mulitiple
2500
+ EcsDeployment constructs are created for a single EcsDeploymentGroup.
2501
+ '''
2502
+
368
2503
  def __init__(
369
2504
  self,
370
- scope: _constructs_77d1e7e8.Construct,
371
- id: builtins.str,
372
2505
  *,
373
- certificate_arn: builtins.str,
374
- cluster: _aws_cdk_aws_ecs_ceddda9d.ICluster,
375
- container_port: jsii.Number,
376
- environment: builtins.str,
377
- image_uri: builtins.str,
378
- service_name: builtins.str,
379
- vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
380
- auto_scaling: typing.Optional[typing.Union[AutoScalingProps, typing.Dict[builtins.str, typing.Any]]] = None,
381
- enable_public_load_balancer: typing.Optional[builtins.bool] = None,
382
- health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
2506
+ deployment_group: _aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentGroup,
2507
+ target_service: typing.Union["TargetService", typing.Dict[builtins.str, typing.Any]],
2508
+ auto_rollback: typing.Optional[typing.Union[_aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig, typing.Dict[builtins.str, typing.Any]]] = None,
2509
+ description: typing.Optional[builtins.str] = None,
2510
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
2511
+ timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
383
2512
  ) -> None:
384
2513
  '''
385
- :param scope: -
386
- :param id: -
387
- :param certificate_arn:
388
- :param cluster:
389
- :param container_port:
390
- :param environment:
391
- :param image_uri:
392
- :param service_name:
393
- :param vpc:
394
- :param auto_scaling:
395
- :param enable_public_load_balancer:
396
- :param health_check:
2514
+ :param deployment_group: The deployment group to target for this deployment.
2515
+ :param target_service: The ECS service to target for the deployment. see: https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-resources.html#reference-appspec-file-structure-resources-ecs
2516
+ :param auto_rollback: The configuration for rollback in the event that a deployment fails. Default: : no automatic rollback triggered
2517
+ :param description: The description for the deployment. Default: no description
2518
+ :param hooks: Optional lifecycle hooks. Default: - no lifecycle hooks
2519
+ :param timeout: The timeout for the deployment. If the timeout is reached, it will trigger a rollback of the stack. Default: 30 minutes
397
2520
  '''
398
- if __debug__:
399
- type_hints = typing.get_type_hints(_typecheckingstub__19ac4f77d3bba1391929b87d2d23b70fe61e21aa6809f43ed4283d6ecf350909)
400
- check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
401
- check_type(argname="argument id", value=id, expected_type=type_hints["id"])
402
- props = EcsCodeDeployProps(
403
- certificate_arn=certificate_arn,
404
- cluster=cluster,
405
- container_port=container_port,
406
- environment=environment,
407
- image_uri=image_uri,
408
- service_name=service_name,
409
- vpc=vpc,
410
- auto_scaling=auto_scaling,
411
- enable_public_load_balancer=enable_public_load_balancer,
412
- health_check=health_check,
2521
+ props = EcsDeploymentProps(
2522
+ deployment_group=deployment_group,
2523
+ target_service=target_service,
2524
+ auto_rollback=auto_rollback,
2525
+ description=description,
2526
+ hooks=hooks,
2527
+ timeout=timeout,
413
2528
  )
414
2529
 
415
- jsii.create(self.__class__, self, [scope, id, props])
2530
+ jsii.create(self.__class__, self, [props])
416
2531
 
417
2532
  @builtins.property
418
- @jsii.member(jsii_name="loadBalancer")
419
- def load_balancer(
2533
+ @jsii.member(jsii_name="deploymentId")
2534
+ def deployment_id(self) -> builtins.str:
2535
+ '''The id of the deployment that was created.'''
2536
+ return typing.cast(builtins.str, jsii.get(self, "deploymentId"))
2537
+
2538
+ @deployment_id.setter
2539
+ def deployment_id(self, value: builtins.str) -> None:
2540
+ if __debug__:
2541
+ type_hints = typing.get_type_hints(_typecheckingstub__28e8902615907bdb53576907b6cdb76c47c97856f7ea9ce53d222e02a06cc4ca)
2542
+ check_type(argname="argument value", value=value, expected_type=type_hints["value"])
2543
+ jsii.set(self, "deploymentId", value) # pyright: ignore[reportArgumentType]
2544
+
2545
+
2546
+ @jsii.data_type(
2547
+ jsii_type="must-cdk.EcsDeploymentProps",
2548
+ jsii_struct_bases=[],
2549
+ name_mapping={
2550
+ "deployment_group": "deploymentGroup",
2551
+ "target_service": "targetService",
2552
+ "auto_rollback": "autoRollback",
2553
+ "description": "description",
2554
+ "hooks": "hooks",
2555
+ "timeout": "timeout",
2556
+ },
2557
+ )
2558
+ class EcsDeploymentProps:
2559
+ def __init__(
2560
+ self,
2561
+ *,
2562
+ deployment_group: _aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentGroup,
2563
+ target_service: typing.Union["TargetService", typing.Dict[builtins.str, typing.Any]],
2564
+ auto_rollback: typing.Optional[typing.Union[_aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig, typing.Dict[builtins.str, typing.Any]]] = None,
2565
+ description: typing.Optional[builtins.str] = None,
2566
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
2567
+ timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
2568
+ ) -> None:
2569
+ '''Construction properties of EcsDeployment.
2570
+
2571
+ :param deployment_group: The deployment group to target for this deployment.
2572
+ :param target_service: The ECS service to target for the deployment. see: https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-resources.html#reference-appspec-file-structure-resources-ecs
2573
+ :param auto_rollback: The configuration for rollback in the event that a deployment fails. Default: : no automatic rollback triggered
2574
+ :param description: The description for the deployment. Default: no description
2575
+ :param hooks: Optional lifecycle hooks. Default: - no lifecycle hooks
2576
+ :param timeout: The timeout for the deployment. If the timeout is reached, it will trigger a rollback of the stack. Default: 30 minutes
2577
+ '''
2578
+ if isinstance(target_service, dict):
2579
+ target_service = TargetService(**target_service)
2580
+ if isinstance(auto_rollback, dict):
2581
+ auto_rollback = _aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig(**auto_rollback)
2582
+ if isinstance(hooks, dict):
2583
+ hooks = AppSpecHooks(**hooks)
2584
+ if __debug__:
2585
+ type_hints = typing.get_type_hints(_typecheckingstub__e121135b1d585b3e9510378a53b6a2461e246ab5696337264b1a36d29e1a99eb)
2586
+ check_type(argname="argument deployment_group", value=deployment_group, expected_type=type_hints["deployment_group"])
2587
+ check_type(argname="argument target_service", value=target_service, expected_type=type_hints["target_service"])
2588
+ check_type(argname="argument auto_rollback", value=auto_rollback, expected_type=type_hints["auto_rollback"])
2589
+ check_type(argname="argument description", value=description, expected_type=type_hints["description"])
2590
+ check_type(argname="argument hooks", value=hooks, expected_type=type_hints["hooks"])
2591
+ check_type(argname="argument timeout", value=timeout, expected_type=type_hints["timeout"])
2592
+ self._values: typing.Dict[builtins.str, typing.Any] = {
2593
+ "deployment_group": deployment_group,
2594
+ "target_service": target_service,
2595
+ }
2596
+ if auto_rollback is not None:
2597
+ self._values["auto_rollback"] = auto_rollback
2598
+ if description is not None:
2599
+ self._values["description"] = description
2600
+ if hooks is not None:
2601
+ self._values["hooks"] = hooks
2602
+ if timeout is not None:
2603
+ self._values["timeout"] = timeout
2604
+
2605
+ @builtins.property
2606
+ def deployment_group(self) -> _aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentGroup:
2607
+ '''The deployment group to target for this deployment.'''
2608
+ result = self._values.get("deployment_group")
2609
+ assert result is not None, "Required property 'deployment_group' is missing"
2610
+ return typing.cast(_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentGroup, result)
2611
+
2612
+ @builtins.property
2613
+ def target_service(self) -> "TargetService":
2614
+ '''The ECS service to target for the deployment.
2615
+
2616
+ see: https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-resources.html#reference-appspec-file-structure-resources-ecs
2617
+ '''
2618
+ result = self._values.get("target_service")
2619
+ assert result is not None, "Required property 'target_service' is missing"
2620
+ return typing.cast("TargetService", result)
2621
+
2622
+ @builtins.property
2623
+ def auto_rollback(
420
2624
  self,
421
- ) -> _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationLoadBalancer:
422
- return typing.cast(_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationLoadBalancer, jsii.get(self, "loadBalancer"))
2625
+ ) -> typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig]:
2626
+ '''The configuration for rollback in the event that a deployment fails.
2627
+
2628
+ :default: : no automatic rollback triggered
2629
+ '''
2630
+ result = self._values.get("auto_rollback")
2631
+ return typing.cast(typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig], result)
423
2632
 
424
2633
  @builtins.property
425
- @jsii.member(jsii_name="service")
426
- def service(self) -> _aws_cdk_aws_ecs_ceddda9d.FargateService:
427
- return typing.cast(_aws_cdk_aws_ecs_ceddda9d.FargateService, jsii.get(self, "service"))
2634
+ def description(self) -> typing.Optional[builtins.str]:
2635
+ '''The description for the deployment.
2636
+
2637
+ :default: no description
2638
+ '''
2639
+ result = self._values.get("description")
2640
+ return typing.cast(typing.Optional[builtins.str], result)
428
2641
 
429
2642
  @builtins.property
430
- @jsii.member(jsii_name="taskRole")
431
- def task_role(self) -> _aws_cdk_aws_iam_ceddda9d.Role:
432
- return typing.cast(_aws_cdk_aws_iam_ceddda9d.Role, jsii.get(self, "taskRole"))
2643
+ def hooks(self) -> typing.Optional[AppSpecHooks]:
2644
+ '''Optional lifecycle hooks.
433
2645
 
434
- @task_role.setter
435
- def task_role(self, value: _aws_cdk_aws_iam_ceddda9d.Role) -> None:
436
- if __debug__:
437
- type_hints = typing.get_type_hints(_typecheckingstub__60923688f982908f977f559dbd1295485a3b0547df3c45291a862130dede0c3e)
438
- check_type(argname="argument value", value=value, expected_type=type_hints["value"])
439
- jsii.set(self, "taskRole", value) # pyright: ignore[reportArgumentType]
2646
+ :default: - no lifecycle hooks
2647
+ '''
2648
+ result = self._values.get("hooks")
2649
+ return typing.cast(typing.Optional[AppSpecHooks], result)
2650
+
2651
+ @builtins.property
2652
+ def timeout(self) -> typing.Optional[_aws_cdk_ceddda9d.Duration]:
2653
+ '''The timeout for the deployment.
2654
+
2655
+ If the timeout is reached, it will trigger a rollback of the stack.
2656
+
2657
+ :default: 30 minutes
2658
+ '''
2659
+ result = self._values.get("timeout")
2660
+ return typing.cast(typing.Optional[_aws_cdk_ceddda9d.Duration], result)
2661
+
2662
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
2663
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
2664
+
2665
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
2666
+ return not (rhs == self)
2667
+
2668
+ def __repr__(self) -> str:
2669
+ return "EcsDeploymentProps(%s)" % ", ".join(
2670
+ k + "=" + repr(v) for k, v in self._values.items()
2671
+ )
440
2672
 
441
2673
 
442
2674
  @jsii.data_type(
443
- jsii_type="must-cdk.EcsCodeDeployProps",
2675
+ jsii_type="must-cdk.TargetService",
444
2676
  jsii_struct_bases=[],
445
2677
  name_mapping={
446
- "certificate_arn": "certificateArn",
447
- "cluster": "cluster",
2678
+ "container_name": "containerName",
448
2679
  "container_port": "containerPort",
449
- "environment": "environment",
450
- "image_uri": "imageUri",
451
- "service_name": "serviceName",
452
- "vpc": "vpc",
453
- "auto_scaling": "autoScaling",
454
- "enable_public_load_balancer": "enablePublicLoadBalancer",
455
- "health_check": "healthCheck",
2680
+ "task_definition": "taskDefinition",
2681
+ "awsvpc_configuration": "awsvpcConfiguration",
2682
+ "capacity_provider_strategy": "capacityProviderStrategy",
2683
+ "platform_version": "platformVersion",
456
2684
  },
457
2685
  )
458
- class EcsCodeDeployProps:
2686
+ class TargetService:
459
2687
  def __init__(
460
2688
  self,
461
2689
  *,
462
- certificate_arn: builtins.str,
463
- cluster: _aws_cdk_aws_ecs_ceddda9d.ICluster,
2690
+ container_name: builtins.str,
464
2691
  container_port: jsii.Number,
465
- environment: builtins.str,
466
- image_uri: builtins.str,
467
- service_name: builtins.str,
468
- vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
469
- auto_scaling: typing.Optional[typing.Union[AutoScalingProps, typing.Dict[builtins.str, typing.Any]]] = None,
470
- enable_public_load_balancer: typing.Optional[builtins.bool] = None,
471
- health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
2692
+ task_definition: _aws_cdk_aws_ecs_ceddda9d.ITaskDefinition,
2693
+ awsvpc_configuration: typing.Optional[typing.Union[AwsvpcConfiguration, typing.Dict[builtins.str, typing.Any]]] = None,
2694
+ capacity_provider_strategy: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
2695
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
472
2696
  ) -> None:
2697
+ '''Describe the target for CodeDeploy to use when creating a deployment for an ecs.EcsDeploymentGroup.
2698
+
2699
+ :param container_name: The name of the Amazon ECS container that contains your Amazon ECS application. It must be a container specified in your Amazon ECS task definition.
2700
+ :param container_port: The port on the container where traffic will be routed to.
2701
+ :param task_definition: The TaskDefintion to deploy to the target services.
2702
+ :param awsvpc_configuration: Network configuration for ECS services that have a network type of ``awsvpc``. Default: reuse current network settings for ECS service.
2703
+ :param capacity_provider_strategy: A list of Amazon ECS capacity providers to use for the deployment. Default: reuse current capcity provider strategy for ECS service.
2704
+ :param platform_version: The platform version of the Fargate tasks in the deployed Amazon ECS service. see: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html Default: LATEST
473
2705
  '''
474
- :param certificate_arn:
475
- :param cluster:
476
- :param container_port:
477
- :param environment:
478
- :param image_uri:
479
- :param service_name:
480
- :param vpc:
481
- :param auto_scaling:
482
- :param enable_public_load_balancer:
483
- :param health_check:
484
- '''
485
- if isinstance(auto_scaling, dict):
486
- auto_scaling = AutoScalingProps(**auto_scaling)
487
- if isinstance(health_check, dict):
488
- health_check = _aws_cdk_aws_ecs_ceddda9d.HealthCheck(**health_check)
2706
+ if isinstance(awsvpc_configuration, dict):
2707
+ awsvpc_configuration = AwsvpcConfiguration(**awsvpc_configuration)
489
2708
  if __debug__:
490
- type_hints = typing.get_type_hints(_typecheckingstub__0e1edfc306738ea99e0bd03a55876d7f75a063970dd3103fc1bbb766dff014b1)
491
- check_type(argname="argument certificate_arn", value=certificate_arn, expected_type=type_hints["certificate_arn"])
492
- check_type(argname="argument cluster", value=cluster, expected_type=type_hints["cluster"])
2709
+ type_hints = typing.get_type_hints(_typecheckingstub__eb8c14516b2286bf2acba8700d5b4bce897297c7f7cc3991153665908d8eff67)
2710
+ check_type(argname="argument container_name", value=container_name, expected_type=type_hints["container_name"])
493
2711
  check_type(argname="argument container_port", value=container_port, expected_type=type_hints["container_port"])
494
- check_type(argname="argument environment", value=environment, expected_type=type_hints["environment"])
495
- check_type(argname="argument image_uri", value=image_uri, expected_type=type_hints["image_uri"])
496
- check_type(argname="argument service_name", value=service_name, expected_type=type_hints["service_name"])
497
- check_type(argname="argument vpc", value=vpc, expected_type=type_hints["vpc"])
498
- check_type(argname="argument auto_scaling", value=auto_scaling, expected_type=type_hints["auto_scaling"])
499
- check_type(argname="argument enable_public_load_balancer", value=enable_public_load_balancer, expected_type=type_hints["enable_public_load_balancer"])
500
- check_type(argname="argument health_check", value=health_check, expected_type=type_hints["health_check"])
2712
+ check_type(argname="argument task_definition", value=task_definition, expected_type=type_hints["task_definition"])
2713
+ check_type(argname="argument awsvpc_configuration", value=awsvpc_configuration, expected_type=type_hints["awsvpc_configuration"])
2714
+ check_type(argname="argument capacity_provider_strategy", value=capacity_provider_strategy, expected_type=type_hints["capacity_provider_strategy"])
2715
+ check_type(argname="argument platform_version", value=platform_version, expected_type=type_hints["platform_version"])
501
2716
  self._values: typing.Dict[builtins.str, typing.Any] = {
502
- "certificate_arn": certificate_arn,
503
- "cluster": cluster,
2717
+ "container_name": container_name,
504
2718
  "container_port": container_port,
505
- "environment": environment,
506
- "image_uri": image_uri,
507
- "service_name": service_name,
508
- "vpc": vpc,
2719
+ "task_definition": task_definition,
509
2720
  }
510
- if auto_scaling is not None:
511
- self._values["auto_scaling"] = auto_scaling
512
- if enable_public_load_balancer is not None:
513
- self._values["enable_public_load_balancer"] = enable_public_load_balancer
514
- if health_check is not None:
515
- self._values["health_check"] = health_check
2721
+ if awsvpc_configuration is not None:
2722
+ self._values["awsvpc_configuration"] = awsvpc_configuration
2723
+ if capacity_provider_strategy is not None:
2724
+ self._values["capacity_provider_strategy"] = capacity_provider_strategy
2725
+ if platform_version is not None:
2726
+ self._values["platform_version"] = platform_version
516
2727
 
517
2728
  @builtins.property
518
- def certificate_arn(self) -> builtins.str:
519
- result = self._values.get("certificate_arn")
520
- assert result is not None, "Required property 'certificate_arn' is missing"
521
- return typing.cast(builtins.str, result)
2729
+ def container_name(self) -> builtins.str:
2730
+ '''The name of the Amazon ECS container that contains your Amazon ECS application.
522
2731
 
523
- @builtins.property
524
- def cluster(self) -> _aws_cdk_aws_ecs_ceddda9d.ICluster:
525
- result = self._values.get("cluster")
526
- assert result is not None, "Required property 'cluster' is missing"
527
- return typing.cast(_aws_cdk_aws_ecs_ceddda9d.ICluster, result)
2732
+ It must be a container specified in your Amazon ECS task definition.
2733
+ '''
2734
+ result = self._values.get("container_name")
2735
+ assert result is not None, "Required property 'container_name' is missing"
2736
+ return typing.cast(builtins.str, result)
528
2737
 
529
2738
  @builtins.property
530
2739
  def container_port(self) -> jsii.Number:
2740
+ '''The port on the container where traffic will be routed to.'''
531
2741
  result = self._values.get("container_port")
532
2742
  assert result is not None, "Required property 'container_port' is missing"
533
2743
  return typing.cast(jsii.Number, result)
534
2744
 
535
2745
  @builtins.property
536
- def environment(self) -> builtins.str:
537
- result = self._values.get("environment")
538
- assert result is not None, "Required property 'environment' is missing"
539
- return typing.cast(builtins.str, result)
2746
+ def task_definition(self) -> _aws_cdk_aws_ecs_ceddda9d.ITaskDefinition:
2747
+ '''The TaskDefintion to deploy to the target services.'''
2748
+ result = self._values.get("task_definition")
2749
+ assert result is not None, "Required property 'task_definition' is missing"
2750
+ return typing.cast(_aws_cdk_aws_ecs_ceddda9d.ITaskDefinition, result)
540
2751
 
541
2752
  @builtins.property
542
- def image_uri(self) -> builtins.str:
543
- result = self._values.get("image_uri")
544
- assert result is not None, "Required property 'image_uri' is missing"
545
- return typing.cast(builtins.str, result)
2753
+ def awsvpc_configuration(self) -> typing.Optional[AwsvpcConfiguration]:
2754
+ '''Network configuration for ECS services that have a network type of ``awsvpc``.
546
2755
 
547
- @builtins.property
548
- def service_name(self) -> builtins.str:
549
- result = self._values.get("service_name")
550
- assert result is not None, "Required property 'service_name' is missing"
551
- return typing.cast(builtins.str, result)
2756
+ :default: reuse current network settings for ECS service.
2757
+ '''
2758
+ result = self._values.get("awsvpc_configuration")
2759
+ return typing.cast(typing.Optional[AwsvpcConfiguration], result)
552
2760
 
553
2761
  @builtins.property
554
- def vpc(self) -> _aws_cdk_aws_ec2_ceddda9d.IVpc:
555
- result = self._values.get("vpc")
556
- assert result is not None, "Required property 'vpc' is missing"
557
- return typing.cast(_aws_cdk_aws_ec2_ceddda9d.IVpc, result)
2762
+ def capacity_provider_strategy(
2763
+ self,
2764
+ ) -> typing.Optional[typing.List[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy]]:
2765
+ '''A list of Amazon ECS capacity providers to use for the deployment.
558
2766
 
559
- @builtins.property
560
- def auto_scaling(self) -> typing.Optional[AutoScalingProps]:
561
- result = self._values.get("auto_scaling")
562
- return typing.cast(typing.Optional[AutoScalingProps], result)
2767
+ :default: reuse current capcity provider strategy for ECS service.
2768
+ '''
2769
+ result = self._values.get("capacity_provider_strategy")
2770
+ return typing.cast(typing.Optional[typing.List[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy]], result)
563
2771
 
564
2772
  @builtins.property
565
- def enable_public_load_balancer(self) -> typing.Optional[builtins.bool]:
566
- result = self._values.get("enable_public_load_balancer")
567
- return typing.cast(typing.Optional[builtins.bool], result)
2773
+ def platform_version(
2774
+ self,
2775
+ ) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion]:
2776
+ '''The platform version of the Fargate tasks in the deployed Amazon ECS service.
568
2777
 
569
- @builtins.property
570
- def health_check(self) -> typing.Optional[_aws_cdk_aws_ecs_ceddda9d.HealthCheck]:
571
- result = self._values.get("health_check")
572
- return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.HealthCheck], result)
2778
+ see: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/platform_versions.html
2779
+
2780
+ :default: LATEST
2781
+ '''
2782
+ result = self._values.get("platform_version")
2783
+ return typing.cast(typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion], result)
573
2784
 
574
2785
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
575
2786
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -578,7 +2789,7 @@ class EcsCodeDeployProps:
578
2789
  return not (rhs == self)
579
2790
 
580
2791
  def __repr__(self) -> str:
581
- return "EcsCodeDeployProps(%s)" % ", ".join(
2792
+ return "TargetService(%s)" % ", ".join(
582
2793
  k + "=" + repr(v) for k, v in self._values.items()
583
2794
  )
584
2795
 
@@ -808,17 +3019,81 @@ class WebsocketApiGatewayToLambdaProps:
808
3019
 
809
3020
 
810
3021
  __all__ = [
3022
+ "ApiCanary",
3023
+ "ApiCanaryProps",
811
3024
  "ApiGatewayToLambdaCustomDomain",
812
3025
  "ApiGatewayToLambdaProps",
813
- "AutoScalingProps",
814
- "EcsCodeDeploy",
815
- "EcsCodeDeployProps",
3026
+ "ApiTestStep",
3027
+ "AppSpecHooks",
3028
+ "ApplicationLoadBalancedCodeDeployedFargateService",
3029
+ "ApplicationLoadBalancedCodeDeployedFargateServiceProps",
3030
+ "AwsvpcConfiguration",
3031
+ "EcsAppSpec",
3032
+ "EcsDeployment",
3033
+ "EcsDeploymentProps",
3034
+ "TargetService",
816
3035
  "WebsocketApiGatewayToLambdaCustomDomain",
817
3036
  "WebsocketApiGatewayToLambdaProps",
818
3037
  ]
819
3038
 
820
3039
  publication.publish()
821
3040
 
3041
+ def _typecheckingstub__09d06c1c95daaaf23d076abac602f3a69682f6d183c18d319586c4a3ad15e539(
3042
+ scope: _constructs_77d1e7e8.Construct,
3043
+ id: builtins.str,
3044
+ *,
3045
+ base_url: builtins.str,
3046
+ artifacts_bucket_location: typing.Optional[typing.Union[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation, typing.Dict[builtins.str, typing.Any]]] = None,
3047
+ canary_name: typing.Optional[builtins.str] = None,
3048
+ duration_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3049
+ failure_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3050
+ role: typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole] = None,
3051
+ schedule: typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule] = None,
3052
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
3053
+ start_after_creation: typing.Optional[builtins.bool] = None,
3054
+ steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
3055
+ success_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3056
+ thread_count: typing.Optional[jsii.Number] = None,
3057
+ time_to_live: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3058
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
3059
+ vpc_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
3060
+ ) -> None:
3061
+ """Type checking stubs"""
3062
+ pass
3063
+
3064
+ def _typecheckingstub__8725a15a28149bfb608a400e26cfbe5e4841d0766e308d94bd820bae8ef15018(
3065
+ value: _aws_cdk_aws_cloudwatch_ceddda9d.Alarm,
3066
+ ) -> None:
3067
+ """Type checking stubs"""
3068
+ pass
3069
+
3070
+ def _typecheckingstub__5e693bebe82a00de7c7762fadb1e226601529313a62b3e1a2a8527584ea39940(
3071
+ value: typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.Alarm],
3072
+ ) -> None:
3073
+ """Type checking stubs"""
3074
+ pass
3075
+
3076
+ def _typecheckingstub__b52b092204732a9d7b4031c2682b2facb0ffa90d719105c9d03ed168de7472f0(
3077
+ *,
3078
+ base_url: builtins.str,
3079
+ artifacts_bucket_location: typing.Optional[typing.Union[_aws_cdk_aws_synthetics_ceddda9d.ArtifactsBucketLocation, typing.Dict[builtins.str, typing.Any]]] = None,
3080
+ canary_name: typing.Optional[builtins.str] = None,
3081
+ duration_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3082
+ failure_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3083
+ role: typing.Optional[_aws_cdk_aws_iam_ceddda9d.IRole] = None,
3084
+ schedule: typing.Optional[_aws_cdk_aws_synthetics_ceddda9d.Schedule] = None,
3085
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
3086
+ start_after_creation: typing.Optional[builtins.bool] = None,
3087
+ steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
3088
+ success_retention_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3089
+ thread_count: typing.Optional[jsii.Number] = None,
3090
+ time_to_live: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3091
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
3092
+ vpc_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
3093
+ ) -> None:
3094
+ """Type checking stubs"""
3095
+ pass
3096
+
822
3097
  def _typecheckingstub__d7036b176aa7b446813bdbc7672055bba27972db6a947684b57c6f8f02e0f9b6(
823
3098
  scope: _constructs_77d1e7e8.Construct,
824
3099
  id: builtins.str,
@@ -847,53 +3122,264 @@ def _typecheckingstub__7c51143b7da8fc50ffd3240aae88642c332f9ccc1136e275abf9d1065
847
3122
  """Type checking stubs"""
848
3123
  pass
849
3124
 
850
- def _typecheckingstub__d0ea30b15daf73de785b4991457443ee0ca220224fbd08155a17d86c67413930(
3125
+ def _typecheckingstub__171a53d32e45dddc3d74e9b9e98d60f757ac6028bcc531de07738ff4251515ed(
3126
+ *,
3127
+ name: builtins.str,
3128
+ path: builtins.str,
3129
+ body: typing.Optional[builtins.str] = None,
3130
+ expected_value: typing.Any = None,
3131
+ headers: typing.Optional[typing.Mapping[builtins.str, builtins.str]] = None,
3132
+ jmes_path: typing.Optional[builtins.str] = None,
3133
+ method: typing.Optional[builtins.str] = None,
3134
+ ) -> None:
3135
+ """Type checking stubs"""
3136
+ pass
3137
+
3138
+ def _typecheckingstub__ff5030e61a5fd08fabf54e34ff261d6fa3b0a899cf455b923b66273d671d18f9(
851
3139
  *,
852
- max_capacity: jsii.Number,
853
- min_capacity: jsii.Number,
854
- target_cpu_utilization_percent: jsii.Number,
855
- scale_in_cooldown_sec: typing.Optional[jsii.Number] = None,
856
- scale_out_cooldown_sec: typing.Optional[jsii.Number] = None,
3140
+ after_allow_test_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3141
+ after_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3142
+ after_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3143
+ before_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3144
+ before_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
857
3145
  ) -> None:
858
3146
  """Type checking stubs"""
859
3147
  pass
860
3148
 
861
- def _typecheckingstub__19ac4f77d3bba1391929b87d2d23b70fe61e21aa6809f43ed4283d6ecf350909(
3149
+ def _typecheckingstub__cdc591d3fee959d6fc3e921fd142a865c9095fcaa7afe54cfab63ad9654b3069(
862
3150
  scope: _constructs_77d1e7e8.Construct,
863
3151
  id: builtins.str,
864
3152
  *,
865
- certificate_arn: builtins.str,
866
- cluster: _aws_cdk_aws_ecs_ceddda9d.ICluster,
867
- container_port: jsii.Number,
868
- environment: builtins.str,
869
- image_uri: builtins.str,
870
- service_name: builtins.str,
871
- vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
872
- auto_scaling: typing.Optional[typing.Union[AutoScalingProps, typing.Dict[builtins.str, typing.Any]]] = None,
873
- enable_public_load_balancer: typing.Optional[builtins.bool] = None,
3153
+ access_log_bucket: typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket] = None,
3154
+ access_log_prefix: typing.Optional[builtins.str] = None,
3155
+ api_canary_schedule: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3156
+ api_canary_thread_count: typing.Optional[jsii.Number] = None,
3157
+ api_canary_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3158
+ api_test_steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
3159
+ application_name: typing.Optional[builtins.str] = None,
3160
+ deployment_config: typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig] = None,
3161
+ deployment_group_name: typing.Optional[builtins.str] = None,
3162
+ deployment_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3163
+ deregistration_delay: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3164
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
3165
+ response_time_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3166
+ target_health_check: typing.Optional[typing.Union[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
3167
+ termination_wait_time: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3168
+ test_port: typing.Optional[jsii.Number] = None,
3169
+ assign_public_ip: typing.Optional[builtins.bool] = None,
3170
+ container_cpu: typing.Optional[jsii.Number] = None,
3171
+ container_memory_limit_mib: typing.Optional[jsii.Number] = None,
3172
+ health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
3173
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
3174
+ task_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
3175
+ capacity_provider_strategies: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
3176
+ certificate: typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate] = None,
3177
+ circuit_breaker: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker, typing.Dict[builtins.str, typing.Any]]] = None,
3178
+ cloud_map_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions, typing.Dict[builtins.str, typing.Any]]] = None,
3179
+ cluster: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster] = None,
3180
+ deployment_controller: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentController, typing.Dict[builtins.str, typing.Any]]] = None,
3181
+ desired_count: typing.Optional[jsii.Number] = None,
3182
+ domain_name: typing.Optional[builtins.str] = None,
3183
+ domain_zone: typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone] = None,
3184
+ enable_ecs_managed_tags: typing.Optional[builtins.bool] = None,
3185
+ enable_execute_command: typing.Optional[builtins.bool] = None,
3186
+ health_check_grace_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3187
+ idle_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3188
+ ip_address_type: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType] = None,
3189
+ listener_port: typing.Optional[jsii.Number] = None,
3190
+ load_balancer: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer] = None,
3191
+ load_balancer_name: typing.Optional[builtins.str] = None,
3192
+ max_healthy_percent: typing.Optional[jsii.Number] = None,
3193
+ min_healthy_percent: typing.Optional[jsii.Number] = None,
3194
+ open_listener: typing.Optional[builtins.bool] = None,
3195
+ propagate_tags: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource] = None,
3196
+ protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
3197
+ protocol_version: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion] = None,
3198
+ public_load_balancer: typing.Optional[builtins.bool] = None,
3199
+ record_type: typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType] = None,
3200
+ redirect_http: typing.Optional[builtins.bool] = None,
3201
+ service_name: typing.Optional[builtins.str] = None,
3202
+ ssl_policy: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy] = None,
3203
+ target_protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
3204
+ task_image_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions, typing.Dict[builtins.str, typing.Any]]] = None,
3205
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
3206
+ cpu: typing.Optional[jsii.Number] = None,
3207
+ ephemeral_storage_gib: typing.Optional[jsii.Number] = None,
3208
+ memory_limit_mib: typing.Optional[jsii.Number] = None,
3209
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
3210
+ runtime_platform: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform, typing.Dict[builtins.str, typing.Any]]] = None,
3211
+ task_definition: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition] = None,
3212
+ ) -> None:
3213
+ """Type checking stubs"""
3214
+ pass
3215
+
3216
+ def _typecheckingstub__2e9ebe4d64205e08ed6953e0bfeed401797c431625ac1359c850bea7289fd3bd(
3217
+ service: _aws_cdk_aws_ecs_ceddda9d.BaseService,
3218
+ ) -> None:
3219
+ """Type checking stubs"""
3220
+ pass
3221
+
3222
+ def _typecheckingstub__04c27870fbc63c85094d295b9f732c20ae2ea852010c4ad421bcde70ea6317b9(
3223
+ value: _aws_cdk_aws_s3_ceddda9d.IBucket,
3224
+ ) -> None:
3225
+ """Type checking stubs"""
3226
+ pass
3227
+
3228
+ def _typecheckingstub__d9fc5156a1b8cf5bbc9b35e9b6746bb1f8400e7a99432fae8b3c01d42f18cf4f(
3229
+ value: _aws_cdk_aws_codedeploy_ceddda9d.EcsApplication,
3230
+ ) -> None:
3231
+ """Type checking stubs"""
3232
+ pass
3233
+
3234
+ def _typecheckingstub__272d02dc1b0a56f7951e43174a9099ef41f00eb05cc85b8c8467dfffa4c7b575(
3235
+ value: EcsDeployment,
3236
+ ) -> None:
3237
+ """Type checking stubs"""
3238
+ pass
3239
+
3240
+ def _typecheckingstub__447b00dfcf799fcb98a028b408aa3d1099e3032ff90cdfbf5edb60629924fa4f(
3241
+ value: _aws_cdk_aws_codedeploy_ceddda9d.EcsDeploymentGroup,
3242
+ ) -> None:
3243
+ """Type checking stubs"""
3244
+ pass
3245
+
3246
+ def _typecheckingstub__aa3a26b4b04d4908d2ea2109d2b4d87bedc95a0fe8cd0a8d0540b8791158781c(
3247
+ value: _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationTargetGroup,
3248
+ ) -> None:
3249
+ """Type checking stubs"""
3250
+ pass
3251
+
3252
+ def _typecheckingstub__a2ed1861141868939832c87d220366d1440d0ef23114460879e579d0433e3a14(
3253
+ value: _aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationListener,
3254
+ ) -> None:
3255
+ """Type checking stubs"""
3256
+ pass
3257
+
3258
+ def _typecheckingstub__627a57fa5d3bba90628c374262020d7d1795c5bf62770ef75633f192fd5753d9(
3259
+ value: typing.Optional[ApiCanary],
3260
+ ) -> None:
3261
+ """Type checking stubs"""
3262
+ pass
3263
+
3264
+ def _typecheckingstub__e070ffcc3fb27284424c9fd4af0ef70d9a50ac85df05cd34a1127edefb90d397(
3265
+ value: typing.Optional[_aws_cdk_aws_cloudwatch_ceddda9d.IAlarm],
3266
+ ) -> None:
3267
+ """Type checking stubs"""
3268
+ pass
3269
+
3270
+ def _typecheckingstub__62e1bd800b9cb43a4625242d7d85bd0154676bc19e69266aeb4ac5bdfd4d476f(
3271
+ *,
3272
+ capacity_provider_strategies: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
3273
+ certificate: typing.Optional[_aws_cdk_aws_certificatemanager_ceddda9d.ICertificate] = None,
3274
+ circuit_breaker: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentCircuitBreaker, typing.Dict[builtins.str, typing.Any]]] = None,
3275
+ cloud_map_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CloudMapOptions, typing.Dict[builtins.str, typing.Any]]] = None,
3276
+ cluster: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.ICluster] = None,
3277
+ deployment_controller: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.DeploymentController, typing.Dict[builtins.str, typing.Any]]] = None,
3278
+ desired_count: typing.Optional[jsii.Number] = None,
3279
+ domain_name: typing.Optional[builtins.str] = None,
3280
+ domain_zone: typing.Optional[_aws_cdk_aws_route53_ceddda9d.IHostedZone] = None,
3281
+ enable_ecs_managed_tags: typing.Optional[builtins.bool] = None,
3282
+ enable_execute_command: typing.Optional[builtins.bool] = None,
3283
+ health_check_grace_period: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3284
+ idle_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3285
+ ip_address_type: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IpAddressType] = None,
3286
+ listener_port: typing.Optional[jsii.Number] = None,
3287
+ load_balancer: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.IApplicationLoadBalancer] = None,
3288
+ load_balancer_name: typing.Optional[builtins.str] = None,
3289
+ max_healthy_percent: typing.Optional[jsii.Number] = None,
3290
+ min_healthy_percent: typing.Optional[jsii.Number] = None,
3291
+ open_listener: typing.Optional[builtins.bool] = None,
3292
+ propagate_tags: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.PropagatedTagSource] = None,
3293
+ protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
3294
+ protocol_version: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocolVersion] = None,
3295
+ public_load_balancer: typing.Optional[builtins.bool] = None,
3296
+ record_type: typing.Optional[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedServiceRecordType] = None,
3297
+ redirect_http: typing.Optional[builtins.bool] = None,
3298
+ service_name: typing.Optional[builtins.str] = None,
3299
+ ssl_policy: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.SslPolicy] = None,
3300
+ target_protocol: typing.Optional[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.ApplicationProtocol] = None,
3301
+ task_image_options: typing.Optional[typing.Union[_aws_cdk_aws_ecs_patterns_ceddda9d.ApplicationLoadBalancedTaskImageOptions, typing.Dict[builtins.str, typing.Any]]] = None,
3302
+ vpc: typing.Optional[_aws_cdk_aws_ec2_ceddda9d.IVpc] = None,
3303
+ cpu: typing.Optional[jsii.Number] = None,
3304
+ ephemeral_storage_gib: typing.Optional[jsii.Number] = None,
3305
+ memory_limit_mib: typing.Optional[jsii.Number] = None,
3306
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
3307
+ runtime_platform: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.RuntimePlatform, typing.Dict[builtins.str, typing.Any]]] = None,
3308
+ task_definition: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargateTaskDefinition] = None,
3309
+ assign_public_ip: typing.Optional[builtins.bool] = None,
3310
+ container_cpu: typing.Optional[jsii.Number] = None,
3311
+ container_memory_limit_mib: typing.Optional[jsii.Number] = None,
874
3312
  health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
3313
+ security_groups: typing.Optional[typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup]] = None,
3314
+ task_subnets: typing.Optional[typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]]] = None,
3315
+ access_log_bucket: typing.Optional[_aws_cdk_aws_s3_ceddda9d.IBucket] = None,
3316
+ access_log_prefix: typing.Optional[builtins.str] = None,
3317
+ api_canary_schedule: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3318
+ api_canary_thread_count: typing.Optional[jsii.Number] = None,
3319
+ api_canary_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3320
+ api_test_steps: typing.Optional[typing.Sequence[typing.Union[ApiTestStep, typing.Dict[builtins.str, typing.Any]]]] = None,
3321
+ application_name: typing.Optional[builtins.str] = None,
3322
+ deployment_config: typing.Optional[_aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentConfig] = None,
3323
+ deployment_group_name: typing.Optional[builtins.str] = None,
3324
+ deployment_timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3325
+ deregistration_delay: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3326
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
3327
+ response_time_alarm_threshold: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3328
+ target_health_check: typing.Optional[typing.Union[_aws_cdk_aws_elasticloadbalancingv2_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
3329
+ termination_wait_time: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
3330
+ test_port: typing.Optional[jsii.Number] = None,
3331
+ ) -> None:
3332
+ """Type checking stubs"""
3333
+ pass
3334
+
3335
+ def _typecheckingstub__118fc20114c4ef938b334440fbc2357c4fa373cddf068764a9bcfcda49fe2c32(
3336
+ *,
3337
+ assign_public_ip: builtins.bool,
3338
+ security_groups: typing.Sequence[_aws_cdk_aws_ec2_ceddda9d.ISecurityGroup],
3339
+ vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
3340
+ vpc_subnets: typing.Union[_aws_cdk_aws_ec2_ceddda9d.SubnetSelection, typing.Dict[builtins.str, typing.Any]],
3341
+ ) -> None:
3342
+ """Type checking stubs"""
3343
+ pass
3344
+
3345
+ def _typecheckingstub__488a8c9ea1d87bab23875ab658b9bdf8db1aab92975455fe1eac82c979bbf1f2(
3346
+ target_service: typing.Union[TargetService, typing.Dict[builtins.str, typing.Any]],
3347
+ *,
3348
+ after_allow_test_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3349
+ after_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3350
+ after_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3351
+ before_allow_traffic: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3352
+ before_install: typing.Optional[typing.Union[builtins.str, _aws_cdk_aws_lambda_ceddda9d.IFunction]] = None,
3353
+ ) -> None:
3354
+ """Type checking stubs"""
3355
+ pass
3356
+
3357
+ def _typecheckingstub__28e8902615907bdb53576907b6cdb76c47c97856f7ea9ce53d222e02a06cc4ca(
3358
+ value: builtins.str,
875
3359
  ) -> None:
876
3360
  """Type checking stubs"""
877
3361
  pass
878
3362
 
879
- def _typecheckingstub__60923688f982908f977f559dbd1295485a3b0547df3c45291a862130dede0c3e(
880
- value: _aws_cdk_aws_iam_ceddda9d.Role,
3363
+ def _typecheckingstub__e121135b1d585b3e9510378a53b6a2461e246ab5696337264b1a36d29e1a99eb(
3364
+ *,
3365
+ deployment_group: _aws_cdk_aws_codedeploy_ceddda9d.IEcsDeploymentGroup,
3366
+ target_service: typing.Union[TargetService, typing.Dict[builtins.str, typing.Any]],
3367
+ auto_rollback: typing.Optional[typing.Union[_aws_cdk_aws_codedeploy_ceddda9d.AutoRollbackConfig, typing.Dict[builtins.str, typing.Any]]] = None,
3368
+ description: typing.Optional[builtins.str] = None,
3369
+ hooks: typing.Optional[typing.Union[AppSpecHooks, typing.Dict[builtins.str, typing.Any]]] = None,
3370
+ timeout: typing.Optional[_aws_cdk_ceddda9d.Duration] = None,
881
3371
  ) -> None:
882
3372
  """Type checking stubs"""
883
3373
  pass
884
3374
 
885
- def _typecheckingstub__0e1edfc306738ea99e0bd03a55876d7f75a063970dd3103fc1bbb766dff014b1(
3375
+ def _typecheckingstub__eb8c14516b2286bf2acba8700d5b4bce897297c7f7cc3991153665908d8eff67(
886
3376
  *,
887
- certificate_arn: builtins.str,
888
- cluster: _aws_cdk_aws_ecs_ceddda9d.ICluster,
3377
+ container_name: builtins.str,
889
3378
  container_port: jsii.Number,
890
- environment: builtins.str,
891
- image_uri: builtins.str,
892
- service_name: builtins.str,
893
- vpc: _aws_cdk_aws_ec2_ceddda9d.IVpc,
894
- auto_scaling: typing.Optional[typing.Union[AutoScalingProps, typing.Dict[builtins.str, typing.Any]]] = None,
895
- enable_public_load_balancer: typing.Optional[builtins.bool] = None,
896
- health_check: typing.Optional[typing.Union[_aws_cdk_aws_ecs_ceddda9d.HealthCheck, typing.Dict[builtins.str, typing.Any]]] = None,
3379
+ task_definition: _aws_cdk_aws_ecs_ceddda9d.ITaskDefinition,
3380
+ awsvpc_configuration: typing.Optional[typing.Union[AwsvpcConfiguration, typing.Dict[builtins.str, typing.Any]]] = None,
3381
+ capacity_provider_strategy: typing.Optional[typing.Sequence[typing.Union[_aws_cdk_aws_ecs_ceddda9d.CapacityProviderStrategy, typing.Dict[builtins.str, typing.Any]]]] = None,
3382
+ platform_version: typing.Optional[_aws_cdk_aws_ecs_ceddda9d.FargatePlatformVersion] = None,
897
3383
  ) -> None:
898
3384
  """Type checking stubs"""
899
3385
  pass