aws-cdk-lib 2.187.0__py3-none-any.whl → 2.188.0__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.

Potentially problematic release.


This version of aws-cdk-lib might be problematic. Click here for more details.

Files changed (53) hide show
  1. aws_cdk/__init__.py +22 -3
  2. aws_cdk/_jsii/__init__.py +1 -1
  3. aws_cdk/_jsii/{aws-cdk-lib@2.187.0.jsii.tgz → aws-cdk-lib@2.188.0.jsii.tgz} +0 -0
  4. aws_cdk/aws_amplify/__init__.py +21 -9
  5. aws_cdk/aws_apigateway/__init__.py +25 -19
  6. aws_cdk/aws_apigatewayv2/__init__.py +88 -0
  7. aws_cdk/aws_appconfig/__init__.py +30 -14
  8. aws_cdk/aws_arczonalshift/__init__.py +4 -4
  9. aws_cdk/aws_bedrock/__init__.py +605 -10
  10. aws_cdk/aws_budgets/__init__.py +8 -8
  11. aws_cdk/aws_cassandra/__init__.py +3 -1
  12. aws_cdk/aws_ce/__init__.py +2 -2
  13. aws_cdk/aws_cloudformation/__init__.py +3 -3
  14. aws_cdk/aws_codebuild/__init__.py +23 -1
  15. aws_cdk/aws_codepipeline/__init__.py +47 -32
  16. aws_cdk/aws_codepipeline_actions/__init__.py +2786 -1042
  17. aws_cdk/aws_codestarnotifications/__init__.py +16 -16
  18. aws_cdk/aws_cognito/__init__.py +8 -2
  19. aws_cdk/aws_ec2/__init__.py +2091 -227
  20. aws_cdk/aws_eks/__init__.py +112 -10
  21. aws_cdk/aws_events_targets/__init__.py +136 -0
  22. aws_cdk/aws_gamelift/__init__.py +5 -5
  23. aws_cdk/aws_iam/__init__.py +6 -4
  24. aws_cdk/aws_identitystore/__init__.py +15 -13
  25. aws_cdk/aws_kinesisfirehose/__init__.py +38 -0
  26. aws_cdk/aws_lambda_event_sources/__init__.py +22 -22
  27. aws_cdk/aws_lex/__init__.py +21 -17
  28. aws_cdk/aws_logs/__init__.py +18 -0
  29. aws_cdk/aws_logs_destinations/__init__.py +146 -0
  30. aws_cdk/aws_notifications/__init__.py +4 -4
  31. aws_cdk/aws_omics/__init__.py +9 -1
  32. aws_cdk/aws_opensearchserverless/__init__.py +31 -23
  33. aws_cdk/aws_organizations/__init__.py +1 -1
  34. aws_cdk/aws_pcaconnectorad/__init__.py +3 -2
  35. aws_cdk/aws_quicksight/__init__.py +35 -22
  36. aws_cdk/aws_rds/__init__.py +84 -0
  37. aws_cdk/aws_route53/__init__.py +3 -3
  38. aws_cdk/aws_route53recoverycontrol/__init__.py +4 -6
  39. aws_cdk/aws_rum/__init__.py +13 -10
  40. aws_cdk/aws_s3/__init__.py +3 -6
  41. aws_cdk/aws_sagemaker/__init__.py +41 -0
  42. aws_cdk/aws_ssmincidents/__init__.py +10 -10
  43. aws_cdk/aws_systemsmanagersap/__init__.py +17 -7
  44. aws_cdk/aws_transfer/__init__.py +19 -10
  45. aws_cdk/aws_wafv2/__init__.py +80 -35
  46. aws_cdk/cx_api/__init__.py +23 -2
  47. aws_cdk/pipelines/__init__.py +32 -0
  48. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/METADATA +1 -1
  49. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/RECORD +53 -53
  50. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/LICENSE +0 -0
  51. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/NOTICE +0 -0
  52. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/WHEEL +0 -0
  53. {aws_cdk_lib-2.187.0.dist-info → aws_cdk_lib-2.188.0.dist-info}/top_level.txt +0 -0
@@ -608,6 +608,55 @@ build_action = codepipeline_actions.JenkinsAction(
608
608
  )
609
609
  ```
610
610
 
611
+ ## Build
612
+
613
+ ### ECR Build And Publish
614
+
615
+ This build action `ECRBuildAndPublish` allows you to automate building and pushing a new image when a change occurs in your source.
616
+
617
+ This action builds based on a specified Docker file location and pushes the image. This build action is not the
618
+ same as the Amazon ECR source action in CodePipeline, which triggers pipeline when a change occurs in your
619
+ Amazon ECR source repository.
620
+
621
+ For information about the `ECRBuildAndPublish` build action,
622
+ see [ECRBuildAndPublish build action reference](https://docs.aws.amazon.com/codepipeline/latest/userguide/action-reference-ECRBuildAndPublish.html).
623
+
624
+ ```python
625
+ import aws_cdk.aws_ecr as ecr
626
+
627
+ # pipeline: codepipeline.Pipeline
628
+ # repository: ecr.IRepository
629
+
630
+
631
+ source_output = codepipeline.Artifact()
632
+ # your source repository
633
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
634
+ action_name="CodeStarConnectionsSourceAction",
635
+ output=source_output,
636
+ connection_arn="your-connection-arn",
637
+ owner="your-owner",
638
+ repo="your-repo"
639
+ )
640
+
641
+ build_action = codepipeline_actions.EcrBuildAndPublishAction(
642
+ action_name="EcrBuildAndPublishAction",
643
+ repository_name=repository.repository_name,
644
+ registry_type=codepipeline_actions.RegistryType.PRIVATE,
645
+ dockerfile_directory_path="./my-dir", # The path indicates ./my-dir/Dockerfile in the source repository
646
+ image_tags=["my-tag-1", "my-tag-2"],
647
+ input=source_output
648
+ )
649
+
650
+ pipeline.add_stage(
651
+ stage_name="Source",
652
+ actions=[source_action]
653
+ )
654
+ pipeline.add_stage(
655
+ stage_name="Build",
656
+ actions=[build_action]
657
+ )
658
+ ```
659
+
611
660
  ## Deploy
612
661
 
613
662
  ### AWS CloudFormation
@@ -1580,6 +1629,78 @@ pipeline.add_stage(
1580
1629
  See [the AWS documentation](https://docs.aws.amazon.com/codepipeline/latest/userguide/action-reference-StepFunctions.html)
1581
1630
  for information on Action structure reference.
1582
1631
 
1632
+ ## Invoke
1633
+
1634
+ ### Inspector
1635
+
1636
+ Amazon Inspector is a vulnerability management service that automatically discovers workloads and continually scans them
1637
+ for software vulnerabilities and unintended network exposure.
1638
+
1639
+ The actions `InspectorSourceCodeScanAction` and `InspectorEcrImageScanAction` automate detecting and fixing security
1640
+ vulnerabilities in your open source code. The actions are managed compute actions with security scanning capabilities.
1641
+ You can use the actions with application source code in your third-party repository, such as GitHub or Bitbucket Cloud,
1642
+ or with images for container applications.
1643
+
1644
+ Your actions will scan and report on vulnerability levels and alerts that you configure.
1645
+
1646
+ #### Inspector Source Code Scan
1647
+
1648
+ The `InspectorSourceCodeScanAction` allows you to scan the application source code for vulnerabilities in your repository.
1649
+
1650
+ ```python
1651
+ # pipeline: codepipeline.Pipeline
1652
+
1653
+
1654
+ source_output = codepipeline.Artifact()
1655
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
1656
+ action_name="CodeStarConnectionsSourceAction",
1657
+ output=source_output,
1658
+ connection_arn="your-connection-arn",
1659
+ owner="your-owner",
1660
+ repo="your-repo"
1661
+ )
1662
+
1663
+ scan_output = codepipeline.Artifact()
1664
+ scan_action = codepipeline_actions.InspectorSourceCodeScanAction(
1665
+ action_name="InspectorSourceCodeScanAction",
1666
+ input=source_output,
1667
+ output=scan_output
1668
+ )
1669
+
1670
+ pipeline.add_stage(
1671
+ stage_name="Source",
1672
+ actions=[source_action]
1673
+ )
1674
+ pipeline.add_stage(
1675
+ stage_name="Scan",
1676
+ actions=[scan_action]
1677
+ )
1678
+ ```
1679
+
1680
+ #### Inspector ECR Image Scan
1681
+
1682
+ The `InspectorEcrImageScanAction` allows you to scan the image for vulnerabilities in your container applications.
1683
+
1684
+ ```python
1685
+ import aws_cdk.aws_ecr as ecr
1686
+
1687
+ # pipeline: codepipeline.Pipeline
1688
+ # repository: ecr.IRepository
1689
+
1690
+
1691
+ scan_output = codepipeline.Artifact()
1692
+ scan_action = codepipeline_actions.InspectorEcrImageScanAction(
1693
+ action_name="InspectorEcrImageScanAction",
1694
+ output=scan_output,
1695
+ repository=repository
1696
+ )
1697
+
1698
+ pipeline.add_stage(
1699
+ stage_name="Scan",
1700
+ actions=[scan_action]
1701
+ )
1702
+ ```
1703
+
1583
1704
  ## Compute
1584
1705
 
1585
1706
  ### Commands
@@ -6381,13 +6502,30 @@ class CodeStarConnectionsSourceAction(
6381
6502
 
6382
6503
  Example::
6383
6504
 
6505
+ # project: codebuild.Project
6506
+
6507
+
6384
6508
  source_output = codepipeline.Artifact()
6385
6509
  source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
6386
6510
  action_name="BitBucket_Source",
6387
6511
  owner="aws",
6388
6512
  repo="aws-cdk",
6389
6513
  output=source_output,
6390
- connection_arn="arn:aws:codestar-connections:us-east-1:123456789012:connection/12345678-abcd-12ab-34cdef5678gh"
6514
+ connection_arn="arn:aws:codestar-connections:us-east-1:123456789012:connection/12345678-abcd-12ab-34cdef5678gh",
6515
+ variables_namespace="SomeSpace"
6516
+ )
6517
+
6518
+ # later:
6519
+
6520
+ codepipeline_actions.CodeBuildAction(
6521
+ action_name="CodeBuild",
6522
+ project=project,
6523
+ input=source_output,
6524
+ environment_variables={
6525
+ "COMMIT_ID": codebuild.BuildEnvironmentVariable(
6526
+ value=source_action.variables.commit_id
6527
+ )
6528
+ }
6391
6529
  )
6392
6530
  '''
6393
6531
 
@@ -6517,13 +6655,30 @@ class CodeStarConnectionsSourceActionProps(_CommonAwsActionProps_8b809bb6):
6517
6655
 
6518
6656
  Example::
6519
6657
 
6658
+ # project: codebuild.Project
6659
+
6660
+
6520
6661
  source_output = codepipeline.Artifact()
6521
6662
  source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
6522
6663
  action_name="BitBucket_Source",
6523
6664
  owner="aws",
6524
6665
  repo="aws-cdk",
6525
6666
  output=source_output,
6526
- connection_arn="arn:aws:codestar-connections:us-east-1:123456789012:connection/12345678-abcd-12ab-34cdef5678gh"
6667
+ connection_arn="arn:aws:codestar-connections:us-east-1:123456789012:connection/12345678-abcd-12ab-34cdef5678gh",
6668
+ variables_namespace="SomeSpace"
6669
+ )
6670
+
6671
+ # later:
6672
+
6673
+ codepipeline_actions.CodeBuildAction(
6674
+ action_name="CodeBuild",
6675
+ project=project,
6676
+ input=source_output,
6677
+ environment_variables={
6678
+ "COMMIT_ID": codebuild.BuildEnvironmentVariable(
6679
+ value=source_action.variables.commit_id
6680
+ )
6681
+ }
6527
6682
  )
6528
6683
  '''
6529
6684
  if __debug__:
@@ -7256,16 +7411,12 @@ class CommonCloudFormationStackSetOptions:
7256
7411
  )
7257
7412
 
7258
7413
 
7259
- class EcrSourceAction(
7414
+ class EcrBuildAndPublishAction(
7260
7415
  Action,
7261
7416
  metaclass=jsii.JSIIMeta,
7262
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceAction",
7417
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrBuildAndPublishAction",
7263
7418
  ):
7264
- '''The ECR Repository source CodePipeline Action.
7265
-
7266
- Will trigger the pipeline as soon as the target tag in the repository
7267
- changes, but only if there is a CloudTrail Trail in the account that
7268
- captures the ECR event.
7419
+ '''CodePipeline build action that uses AWS EcrBuildAndPublish.
7269
7420
 
7270
7421
  :exampleMetadata: infused
7271
7422
 
@@ -7273,46 +7424,69 @@ class EcrSourceAction(
7273
7424
 
7274
7425
  import aws_cdk.aws_ecr as ecr
7275
7426
 
7276
- # ecr_repository: ecr.Repository
7427
+ # pipeline: codepipeline.Pipeline
7428
+ # repository: ecr.IRepository
7429
+
7277
7430
 
7278
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
7279
7431
  source_output = codepipeline.Artifact()
7280
- source_action = codepipeline_actions.EcrSourceAction(
7281
- action_name="ECR",
7282
- repository=ecr_repository,
7283
- image_tag="some-tag", # optional, default: 'latest'
7284
- output=source_output
7432
+ # your source repository
7433
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
7434
+ action_name="CodeStarConnectionsSourceAction",
7435
+ output=source_output,
7436
+ connection_arn="your-connection-arn",
7437
+ owner="your-owner",
7438
+ repo="your-repo"
7285
7439
  )
7440
+
7441
+ build_action = codepipeline_actions.EcrBuildAndPublishAction(
7442
+ action_name="EcrBuildAndPublishAction",
7443
+ repository_name=repository.repository_name,
7444
+ registry_type=codepipeline_actions.RegistryType.PRIVATE,
7445
+ dockerfile_directory_path="./my-dir", # The path indicates ./my-dir/Dockerfile in the source repository
7446
+ image_tags=["my-tag-1", "my-tag-2"],
7447
+ input=source_output
7448
+ )
7449
+
7286
7450
  pipeline.add_stage(
7287
7451
  stage_name="Source",
7288
7452
  actions=[source_action]
7289
7453
  )
7454
+ pipeline.add_stage(
7455
+ stage_name="Build",
7456
+ actions=[build_action]
7457
+ )
7290
7458
  '''
7291
7459
 
7292
7460
  def __init__(
7293
7461
  self,
7294
7462
  *,
7295
- output: _Artifact_0cb05964,
7296
- repository: _IRepository_e6004aa6,
7297
- image_tag: typing.Optional[builtins.str] = None,
7463
+ input: _Artifact_0cb05964,
7464
+ repository_name: builtins.str,
7465
+ dockerfile_directory_path: typing.Optional[builtins.str] = None,
7466
+ image_tags: typing.Optional[typing.Sequence[builtins.str]] = None,
7467
+ registry_type: typing.Optional["RegistryType"] = None,
7298
7468
  role: typing.Optional[_IRole_235f5d8e] = None,
7299
7469
  action_name: builtins.str,
7300
7470
  run_order: typing.Optional[jsii.Number] = None,
7301
7471
  variables_namespace: typing.Optional[builtins.str] = None,
7302
7472
  ) -> None:
7303
7473
  '''
7304
- :param output:
7305
- :param repository: The repository that will be watched for changes.
7306
- :param image_tag: The image tag that will be checked for changes. It is not possible to trigger on changes to more than one tag. Default: 'latest'
7474
+ :param input: The artifact produced by the source action that contains the Dockerfile needed to build the image.
7475
+ :param repository_name: The name of the ECR repository where the image is pushed.
7476
+ :param dockerfile_directory_path: The directory path of Dockerfile used to build the image. Optionally, you can provide an alternate directory path if Dockerfile is not at the root level. Default: - the source repository root level
7477
+ :param image_tags: The tags used for the image. Default: - latest
7478
+ :param registry_type: Specifies whether the repository is public or private. Default: - RegistryType.PRIVATE
7307
7479
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
7308
7480
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
7309
7481
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
7310
7482
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
7311
7483
  '''
7312
- props = EcrSourceActionProps(
7313
- output=output,
7314
- repository=repository,
7315
- image_tag=image_tag,
7484
+ props = EcrBuildAndPublishActionProps(
7485
+ input=input,
7486
+ repository_name=repository_name,
7487
+ dockerfile_directory_path=dockerfile_directory_path,
7488
+ image_tags=image_tags,
7489
+ registry_type=registry_type,
7316
7490
  role=role,
7317
7491
  action_name=action_name,
7318
7492
  run_order=run_order,
@@ -7338,7 +7512,7 @@ class EcrSourceAction(
7338
7512
  :param role:
7339
7513
  '''
7340
7514
  if __debug__:
7341
- type_hints = typing.get_type_hints(_typecheckingstub__d95f17ce1dc91ce862a33fcb114ba70ca493fdcf80aba4bd2b33da0283823b94)
7515
+ type_hints = typing.get_type_hints(_typecheckingstub__29d16187e06f9d23101e6955f383d38368a5309fb4f73cf04c52e7a739830b33)
7342
7516
  check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
7343
7517
  check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
7344
7518
  options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
@@ -7347,25 +7521,27 @@ class EcrSourceAction(
7347
7521
 
7348
7522
  @builtins.property
7349
7523
  @jsii.member(jsii_name="variables")
7350
- def variables(self) -> "EcrSourceVariables":
7524
+ def variables(self) -> "EcrBuildAndPublishVariables":
7351
7525
  '''The variables emitted by this action.'''
7352
- return typing.cast("EcrSourceVariables", jsii.get(self, "variables"))
7526
+ return typing.cast("EcrBuildAndPublishVariables", jsii.get(self, "variables"))
7353
7527
 
7354
7528
 
7355
7529
  @jsii.data_type(
7356
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceActionProps",
7530
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrBuildAndPublishActionProps",
7357
7531
  jsii_struct_bases=[_CommonAwsActionProps_8b809bb6],
7358
7532
  name_mapping={
7359
7533
  "action_name": "actionName",
7360
7534
  "run_order": "runOrder",
7361
7535
  "variables_namespace": "variablesNamespace",
7362
7536
  "role": "role",
7363
- "output": "output",
7364
- "repository": "repository",
7365
- "image_tag": "imageTag",
7537
+ "input": "input",
7538
+ "repository_name": "repositoryName",
7539
+ "dockerfile_directory_path": "dockerfileDirectoryPath",
7540
+ "image_tags": "imageTags",
7541
+ "registry_type": "registryType",
7366
7542
  },
7367
7543
  )
7368
- class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7544
+ class EcrBuildAndPublishActionProps(_CommonAwsActionProps_8b809bb6):
7369
7545
  def __init__(
7370
7546
  self,
7371
7547
  *,
@@ -7373,19 +7549,23 @@ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7373
7549
  run_order: typing.Optional[jsii.Number] = None,
7374
7550
  variables_namespace: typing.Optional[builtins.str] = None,
7375
7551
  role: typing.Optional[_IRole_235f5d8e] = None,
7376
- output: _Artifact_0cb05964,
7377
- repository: _IRepository_e6004aa6,
7378
- image_tag: typing.Optional[builtins.str] = None,
7552
+ input: _Artifact_0cb05964,
7553
+ repository_name: builtins.str,
7554
+ dockerfile_directory_path: typing.Optional[builtins.str] = None,
7555
+ image_tags: typing.Optional[typing.Sequence[builtins.str]] = None,
7556
+ registry_type: typing.Optional["RegistryType"] = None,
7379
7557
  ) -> None:
7380
- '''Construction properties of ``EcrSourceAction``.
7558
+ '''Construction properties of the ``EcrBuildAndPublishAction``.
7381
7559
 
7382
7560
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
7383
7561
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
7384
7562
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
7385
7563
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
7386
- :param output:
7387
- :param repository: The repository that will be watched for changes.
7388
- :param image_tag: The image tag that will be checked for changes. It is not possible to trigger on changes to more than one tag. Default: 'latest'
7564
+ :param input: The artifact produced by the source action that contains the Dockerfile needed to build the image.
7565
+ :param repository_name: The name of the ECR repository where the image is pushed.
7566
+ :param dockerfile_directory_path: The directory path of Dockerfile used to build the image. Optionally, you can provide an alternate directory path if Dockerfile is not at the root level. Default: - the source repository root level
7567
+ :param image_tags: The tags used for the image. Default: - latest
7568
+ :param registry_type: Specifies whether the repository is public or private. Default: - RegistryType.PRIVATE
7389
7569
 
7390
7570
  :exampleMetadata: infused
7391
7571
 
@@ -7393,34 +7573,53 @@ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7393
7573
 
7394
7574
  import aws_cdk.aws_ecr as ecr
7395
7575
 
7396
- # ecr_repository: ecr.Repository
7576
+ # pipeline: codepipeline.Pipeline
7577
+ # repository: ecr.IRepository
7578
+
7397
7579
 
7398
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
7399
7580
  source_output = codepipeline.Artifact()
7400
- source_action = codepipeline_actions.EcrSourceAction(
7401
- action_name="ECR",
7402
- repository=ecr_repository,
7403
- image_tag="some-tag", # optional, default: 'latest'
7404
- output=source_output
7581
+ # your source repository
7582
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
7583
+ action_name="CodeStarConnectionsSourceAction",
7584
+ output=source_output,
7585
+ connection_arn="your-connection-arn",
7586
+ owner="your-owner",
7587
+ repo="your-repo"
7405
7588
  )
7589
+
7590
+ build_action = codepipeline_actions.EcrBuildAndPublishAction(
7591
+ action_name="EcrBuildAndPublishAction",
7592
+ repository_name=repository.repository_name,
7593
+ registry_type=codepipeline_actions.RegistryType.PRIVATE,
7594
+ dockerfile_directory_path="./my-dir", # The path indicates ./my-dir/Dockerfile in the source repository
7595
+ image_tags=["my-tag-1", "my-tag-2"],
7596
+ input=source_output
7597
+ )
7598
+
7406
7599
  pipeline.add_stage(
7407
7600
  stage_name="Source",
7408
7601
  actions=[source_action]
7409
7602
  )
7603
+ pipeline.add_stage(
7604
+ stage_name="Build",
7605
+ actions=[build_action]
7606
+ )
7410
7607
  '''
7411
7608
  if __debug__:
7412
- type_hints = typing.get_type_hints(_typecheckingstub__8ba2cd26256aa79e321d4f53bd1f303945241d77de68904ac98b7a536a387ca2)
7609
+ type_hints = typing.get_type_hints(_typecheckingstub__1b13d08d881a39c394898fc7c83d74e8f65d5c1bdabde058e6bb0d10e57ec00f)
7413
7610
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
7414
7611
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
7415
7612
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
7416
7613
  check_type(argname="argument role", value=role, expected_type=type_hints["role"])
7417
- check_type(argname="argument output", value=output, expected_type=type_hints["output"])
7418
- check_type(argname="argument repository", value=repository, expected_type=type_hints["repository"])
7419
- check_type(argname="argument image_tag", value=image_tag, expected_type=type_hints["image_tag"])
7614
+ check_type(argname="argument input", value=input, expected_type=type_hints["input"])
7615
+ check_type(argname="argument repository_name", value=repository_name, expected_type=type_hints["repository_name"])
7616
+ check_type(argname="argument dockerfile_directory_path", value=dockerfile_directory_path, expected_type=type_hints["dockerfile_directory_path"])
7617
+ check_type(argname="argument image_tags", value=image_tags, expected_type=type_hints["image_tags"])
7618
+ check_type(argname="argument registry_type", value=registry_type, expected_type=type_hints["registry_type"])
7420
7619
  self._values: typing.Dict[builtins.str, typing.Any] = {
7421
7620
  "action_name": action_name,
7422
- "output": output,
7423
- "repository": repository,
7621
+ "input": input,
7622
+ "repository_name": repository_name,
7424
7623
  }
7425
7624
  if run_order is not None:
7426
7625
  self._values["run_order"] = run_order
@@ -7428,8 +7627,12 @@ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7428
7627
  self._values["variables_namespace"] = variables_namespace
7429
7628
  if role is not None:
7430
7629
  self._values["role"] = role
7431
- if image_tag is not None:
7432
- self._values["image_tag"] = image_tag
7630
+ if dockerfile_directory_path is not None:
7631
+ self._values["dockerfile_directory_path"] = dockerfile_directory_path
7632
+ if image_tags is not None:
7633
+ self._values["image_tags"] = image_tags
7634
+ if registry_type is not None:
7635
+ self._values["registry_type"] = registry_type
7433
7636
 
7434
7637
  @builtins.property
7435
7638
  def action_name(self) -> builtins.str:
@@ -7483,29 +7686,48 @@ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7483
7686
  return typing.cast(typing.Optional[_IRole_235f5d8e], result)
7484
7687
 
7485
7688
  @builtins.property
7486
- def output(self) -> _Artifact_0cb05964:
7487
- result = self._values.get("output")
7488
- assert result is not None, "Required property 'output' is missing"
7689
+ def input(self) -> _Artifact_0cb05964:
7690
+ '''The artifact produced by the source action that contains the Dockerfile needed to build the image.'''
7691
+ result = self._values.get("input")
7692
+ assert result is not None, "Required property 'input' is missing"
7489
7693
  return typing.cast(_Artifact_0cb05964, result)
7490
7694
 
7491
7695
  @builtins.property
7492
- def repository(self) -> _IRepository_e6004aa6:
7493
- '''The repository that will be watched for changes.'''
7494
- result = self._values.get("repository")
7495
- assert result is not None, "Required property 'repository' is missing"
7496
- return typing.cast(_IRepository_e6004aa6, result)
7696
+ def repository_name(self) -> builtins.str:
7697
+ '''The name of the ECR repository where the image is pushed.'''
7698
+ result = self._values.get("repository_name")
7699
+ assert result is not None, "Required property 'repository_name' is missing"
7700
+ return typing.cast(builtins.str, result)
7497
7701
 
7498
7702
  @builtins.property
7499
- def image_tag(self) -> typing.Optional[builtins.str]:
7500
- '''The image tag that will be checked for changes.
7703
+ def dockerfile_directory_path(self) -> typing.Optional[builtins.str]:
7704
+ '''The directory path of Dockerfile used to build the image.
7501
7705
 
7502
- It is not possible to trigger on changes to more than one tag.
7706
+ Optionally, you can provide an alternate directory path if Dockerfile is not at the root level.
7503
7707
 
7504
- :default: 'latest'
7708
+ :default: - the source repository root level
7505
7709
  '''
7506
- result = self._values.get("image_tag")
7710
+ result = self._values.get("dockerfile_directory_path")
7507
7711
  return typing.cast(typing.Optional[builtins.str], result)
7508
7712
 
7713
+ @builtins.property
7714
+ def image_tags(self) -> typing.Optional[typing.List[builtins.str]]:
7715
+ '''The tags used for the image.
7716
+
7717
+ :default: - latest
7718
+ '''
7719
+ result = self._values.get("image_tags")
7720
+ return typing.cast(typing.Optional[typing.List[builtins.str]], result)
7721
+
7722
+ @builtins.property
7723
+ def registry_type(self) -> typing.Optional["RegistryType"]:
7724
+ '''Specifies whether the repository is public or private.
7725
+
7726
+ :default: - RegistryType.PRIVATE
7727
+ '''
7728
+ result = self._values.get("registry_type")
7729
+ return typing.cast(typing.Optional["RegistryType"], result)
7730
+
7509
7731
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
7510
7732
  return isinstance(rhs, self.__class__) and rhs._values == self._values
7511
7733
 
@@ -7513,39 +7735,30 @@ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7513
7735
  return not (rhs == self)
7514
7736
 
7515
7737
  def __repr__(self) -> str:
7516
- return "EcrSourceActionProps(%s)" % ", ".join(
7738
+ return "EcrBuildAndPublishActionProps(%s)" % ", ".join(
7517
7739
  k + "=" + repr(v) for k, v in self._values.items()
7518
7740
  )
7519
7741
 
7520
7742
 
7521
7743
  @jsii.data_type(
7522
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceVariables",
7744
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrBuildAndPublishVariables",
7523
7745
  jsii_struct_bases=[],
7524
7746
  name_mapping={
7525
- "image_digest": "imageDigest",
7526
- "image_tag": "imageTag",
7527
- "image_uri": "imageUri",
7528
- "registry_id": "registryId",
7529
- "repository_name": "repositoryName",
7747
+ "ecr_image_digest_id": "ecrImageDigestId",
7748
+ "ecr_repository_name": "ecrRepositoryName",
7530
7749
  },
7531
7750
  )
7532
- class EcrSourceVariables:
7751
+ class EcrBuildAndPublishVariables:
7533
7752
  def __init__(
7534
7753
  self,
7535
7754
  *,
7536
- image_digest: builtins.str,
7537
- image_tag: builtins.str,
7538
- image_uri: builtins.str,
7539
- registry_id: builtins.str,
7540
- repository_name: builtins.str,
7755
+ ecr_image_digest_id: builtins.str,
7756
+ ecr_repository_name: builtins.str,
7541
7757
  ) -> None:
7542
- '''The CodePipeline variables emitted by the ECR source Action.
7758
+ '''The CodePipeline variables emitted by the ECR build and publish Action.
7543
7759
 
7544
- :param image_digest: The digest of the current image, in the form ':'.
7545
- :param image_tag: The Docker tag of the current image.
7546
- :param image_uri: The full ECR Docker URI of the current image.
7547
- :param registry_id: The identifier of the registry. In ECR, this is usually the ID of the AWS account owning it.
7548
- :param repository_name: The physical name of the repository that this action tracks.
7760
+ :param ecr_image_digest_id: The sha256 digest of the image manifest.
7761
+ :param ecr_repository_name: The name of the Amazon ECR repository where the image was pushed.
7549
7762
 
7550
7763
  :exampleMetadata: fixture=_generated
7551
7764
 
@@ -7555,65 +7768,32 @@ class EcrSourceVariables:
7555
7768
  # The values are placeholders you should change.
7556
7769
  from aws_cdk import aws_codepipeline_actions as codepipeline_actions
7557
7770
 
7558
- ecr_source_variables = codepipeline_actions.EcrSourceVariables(
7559
- image_digest="imageDigest",
7560
- image_tag="imageTag",
7561
- image_uri="imageUri",
7562
- registry_id="registryId",
7563
- repository_name="repositoryName"
7771
+ ecr_build_and_publish_variables = codepipeline_actions.EcrBuildAndPublishVariables(
7772
+ ecr_image_digest_id="ecrImageDigestId",
7773
+ ecr_repository_name="ecrRepositoryName"
7564
7774
  )
7565
7775
  '''
7566
7776
  if __debug__:
7567
- type_hints = typing.get_type_hints(_typecheckingstub__2f3d2afe9ce2a85b2adf5373670c98f28d033d6c9016a1eb341ffa79450e6869)
7568
- check_type(argname="argument image_digest", value=image_digest, expected_type=type_hints["image_digest"])
7569
- check_type(argname="argument image_tag", value=image_tag, expected_type=type_hints["image_tag"])
7570
- check_type(argname="argument image_uri", value=image_uri, expected_type=type_hints["image_uri"])
7571
- check_type(argname="argument registry_id", value=registry_id, expected_type=type_hints["registry_id"])
7572
- check_type(argname="argument repository_name", value=repository_name, expected_type=type_hints["repository_name"])
7777
+ type_hints = typing.get_type_hints(_typecheckingstub__91516fa8ca0077d312e46c891a6812f3570330144844a5f751633dbd6d3cdef7)
7778
+ check_type(argname="argument ecr_image_digest_id", value=ecr_image_digest_id, expected_type=type_hints["ecr_image_digest_id"])
7779
+ check_type(argname="argument ecr_repository_name", value=ecr_repository_name, expected_type=type_hints["ecr_repository_name"])
7573
7780
  self._values: typing.Dict[builtins.str, typing.Any] = {
7574
- "image_digest": image_digest,
7575
- "image_tag": image_tag,
7576
- "image_uri": image_uri,
7577
- "registry_id": registry_id,
7578
- "repository_name": repository_name,
7781
+ "ecr_image_digest_id": ecr_image_digest_id,
7782
+ "ecr_repository_name": ecr_repository_name,
7579
7783
  }
7580
7784
 
7581
7785
  @builtins.property
7582
- def image_digest(self) -> builtins.str:
7583
- '''The digest of the current image, in the form ':'.'''
7584
- result = self._values.get("image_digest")
7585
- assert result is not None, "Required property 'image_digest' is missing"
7786
+ def ecr_image_digest_id(self) -> builtins.str:
7787
+ '''The sha256 digest of the image manifest.'''
7788
+ result = self._values.get("ecr_image_digest_id")
7789
+ assert result is not None, "Required property 'ecr_image_digest_id' is missing"
7586
7790
  return typing.cast(builtins.str, result)
7587
7791
 
7588
7792
  @builtins.property
7589
- def image_tag(self) -> builtins.str:
7590
- '''The Docker tag of the current image.'''
7591
- result = self._values.get("image_tag")
7592
- assert result is not None, "Required property 'image_tag' is missing"
7593
- return typing.cast(builtins.str, result)
7594
-
7595
- @builtins.property
7596
- def image_uri(self) -> builtins.str:
7597
- '''The full ECR Docker URI of the current image.'''
7598
- result = self._values.get("image_uri")
7599
- assert result is not None, "Required property 'image_uri' is missing"
7600
- return typing.cast(builtins.str, result)
7601
-
7602
- @builtins.property
7603
- def registry_id(self) -> builtins.str:
7604
- '''The identifier of the registry.
7605
-
7606
- In ECR, this is usually the ID of the AWS account owning it.
7607
- '''
7608
- result = self._values.get("registry_id")
7609
- assert result is not None, "Required property 'registry_id' is missing"
7610
- return typing.cast(builtins.str, result)
7611
-
7612
- @builtins.property
7613
- def repository_name(self) -> builtins.str:
7614
- '''The physical name of the repository that this action tracks.'''
7615
- result = self._values.get("repository_name")
7616
- assert result is not None, "Required property 'repository_name' is missing"
7793
+ def ecr_repository_name(self) -> builtins.str:
7794
+ '''The name of the Amazon ECR repository where the image was pushed.'''
7795
+ result = self._values.get("ecr_repository_name")
7796
+ assert result is not None, "Required property 'ecr_repository_name' is missing"
7617
7797
  return typing.cast(builtins.str, result)
7618
7798
 
7619
7799
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
@@ -7623,75 +7803,68 @@ class EcrSourceVariables:
7623
7803
  return not (rhs == self)
7624
7804
 
7625
7805
  def __repr__(self) -> str:
7626
- return "EcrSourceVariables(%s)" % ", ".join(
7806
+ return "EcrBuildAndPublishVariables(%s)" % ", ".join(
7627
7807
  k + "=" + repr(v) for k, v in self._values.items()
7628
7808
  )
7629
7809
 
7630
7810
 
7631
- class EcsDeployAction(
7811
+ class EcrSourceAction(
7632
7812
  Action,
7633
7813
  metaclass=jsii.JSIIMeta,
7634
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcsDeployAction",
7814
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceAction",
7635
7815
  ):
7636
- '''CodePipeline Action to deploy an ECS Service.
7816
+ '''The ECR Repository source CodePipeline Action.
7817
+
7818
+ Will trigger the pipeline as soon as the target tag in the repository
7819
+ changes, but only if there is a CloudTrail Trail in the account that
7820
+ captures the ECR event.
7637
7821
 
7638
7822
  :exampleMetadata: infused
7639
7823
 
7640
7824
  Example::
7641
7825
 
7642
- import aws_cdk.aws_ecs as ecs
7826
+ import aws_cdk.aws_ecr as ecr
7643
7827
 
7644
- # service: ecs.FargateService
7828
+ # ecr_repository: ecr.Repository
7645
7829
 
7646
7830
  pipeline = codepipeline.Pipeline(self, "MyPipeline")
7647
- build_output = codepipeline.Artifact()
7648
- deploy_stage = pipeline.add_stage(
7649
- stage_name="Deploy",
7650
- actions=[
7651
- codepipeline_actions.EcsDeployAction(
7652
- action_name="DeployAction",
7653
- service=service,
7654
- # if your file is called imagedefinitions.json,
7655
- # use the `input` property,
7656
- # and leave out the `imageFile` property
7657
- input=build_output,
7658
- # if your file name is _not_ imagedefinitions.json,
7659
- # use the `imageFile` property,
7660
- # and leave out the `input` property
7661
- image_file=build_output.at_path("imageDef.json"),
7662
- deployment_timeout=Duration.minutes(60)
7663
- )
7664
- ]
7831
+ source_output = codepipeline.Artifact()
7832
+ source_action = codepipeline_actions.EcrSourceAction(
7833
+ action_name="ECR",
7834
+ repository=ecr_repository,
7835
+ image_tag="some-tag", # optional, default: 'latest'
7836
+ output=source_output
7837
+ )
7838
+ pipeline.add_stage(
7839
+ stage_name="Source",
7840
+ actions=[source_action]
7665
7841
  )
7666
7842
  '''
7667
7843
 
7668
7844
  def __init__(
7669
7845
  self,
7670
7846
  *,
7671
- service: _IBaseService_3fcdd913,
7672
- deployment_timeout: typing.Optional[_Duration_4839e8c3] = None,
7673
- image_file: typing.Optional[_ArtifactPath_bf444090] = None,
7674
- input: typing.Optional[_Artifact_0cb05964] = None,
7847
+ output: _Artifact_0cb05964,
7848
+ repository: _IRepository_e6004aa6,
7849
+ image_tag: typing.Optional[builtins.str] = None,
7675
7850
  role: typing.Optional[_IRole_235f5d8e] = None,
7676
7851
  action_name: builtins.str,
7677
7852
  run_order: typing.Optional[jsii.Number] = None,
7678
7853
  variables_namespace: typing.Optional[builtins.str] = None,
7679
7854
  ) -> None:
7680
7855
  '''
7681
- :param service: The ECS Service to deploy.
7682
- :param deployment_timeout: Timeout for the ECS deployment in minutes. Value must be between 1-60. Default: - 60 minutes
7683
- :param image_file: The name of the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'. If you use this property, you don't need to specify the ``input`` property. Default: - one of this property, or ``input``, is required
7684
- :param input: The input artifact that contains the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. If you use this property, it's assumed the file is called 'imagedefinitions.json'. If your build uses a different file, leave this property empty, and use the ``imageFile`` property instead. Default: - one of this property, or ``imageFile``, is required
7856
+ :param output:
7857
+ :param repository: The repository that will be watched for changes.
7858
+ :param image_tag: The image tag that will be checked for changes. It is not possible to trigger on changes to more than one tag. Default: 'latest'
7685
7859
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
7686
7860
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
7687
7861
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
7688
7862
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
7689
7863
  '''
7690
- props = EcsDeployActionProps(
7691
- service=service,
7692
- deployment_timeout=deployment_timeout,
7693
- image_file=image_file,
7694
- input=input,
7864
+ props = EcrSourceActionProps(
7865
+ output=output,
7866
+ repository=repository,
7867
+ image_tag=image_tag,
7695
7868
  role=role,
7696
7869
  action_name=action_name,
7697
7870
  run_order=run_order,
@@ -7703,43 +7876,48 @@ class EcsDeployAction(
7703
7876
  @jsii.member(jsii_name="bound")
7704
7877
  def _bound(
7705
7878
  self,
7706
- _scope: _constructs_77d1e7e8.Construct,
7707
- _stage: _IStage_415fc571,
7879
+ scope: _constructs_77d1e7e8.Construct,
7880
+ stage: _IStage_415fc571,
7708
7881
  *,
7709
7882
  bucket: _IBucket_42e086fd,
7710
7883
  role: _IRole_235f5d8e,
7711
7884
  ) -> _ActionConfig_846fc217:
7712
7885
  '''This is a renamed version of the ``IAction.bind`` method.
7713
7886
 
7714
- :param _scope: -
7715
- :param _stage: -
7887
+ :param scope: -
7888
+ :param stage: -
7716
7889
  :param bucket:
7717
7890
  :param role:
7718
7891
  '''
7719
7892
  if __debug__:
7720
- type_hints = typing.get_type_hints(_typecheckingstub__be96a039b024c460a7c791a692e2aa8519216e3bb3e6afdbbddda461d96791e4)
7721
- check_type(argname="argument _scope", value=_scope, expected_type=type_hints["_scope"])
7722
- check_type(argname="argument _stage", value=_stage, expected_type=type_hints["_stage"])
7893
+ type_hints = typing.get_type_hints(_typecheckingstub__d95f17ce1dc91ce862a33fcb114ba70ca493fdcf80aba4bd2b33da0283823b94)
7894
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
7895
+ check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
7723
7896
  options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
7724
7897
 
7725
- return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [_scope, _stage, options]))
7898
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, options]))
7899
+
7900
+ @builtins.property
7901
+ @jsii.member(jsii_name="variables")
7902
+ def variables(self) -> "EcrSourceVariables":
7903
+ '''The variables emitted by this action.'''
7904
+ return typing.cast("EcrSourceVariables", jsii.get(self, "variables"))
7726
7905
 
7727
7906
 
7728
7907
  @jsii.data_type(
7729
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcsDeployActionProps",
7908
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceActionProps",
7730
7909
  jsii_struct_bases=[_CommonAwsActionProps_8b809bb6],
7731
7910
  name_mapping={
7732
7911
  "action_name": "actionName",
7733
7912
  "run_order": "runOrder",
7734
7913
  "variables_namespace": "variablesNamespace",
7735
7914
  "role": "role",
7736
- "service": "service",
7737
- "deployment_timeout": "deploymentTimeout",
7738
- "image_file": "imageFile",
7739
- "input": "input",
7915
+ "output": "output",
7916
+ "repository": "repository",
7917
+ "image_tag": "imageTag",
7740
7918
  },
7741
7919
  )
7742
- class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
7920
+ class EcrSourceActionProps(_CommonAwsActionProps_8b809bb6):
7743
7921
  def __init__(
7744
7922
  self,
7745
7923
  *,
@@ -7747,64 +7925,54 @@ class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
7747
7925
  run_order: typing.Optional[jsii.Number] = None,
7748
7926
  variables_namespace: typing.Optional[builtins.str] = None,
7749
7927
  role: typing.Optional[_IRole_235f5d8e] = None,
7750
- service: _IBaseService_3fcdd913,
7751
- deployment_timeout: typing.Optional[_Duration_4839e8c3] = None,
7752
- image_file: typing.Optional[_ArtifactPath_bf444090] = None,
7753
- input: typing.Optional[_Artifact_0cb05964] = None,
7928
+ output: _Artifact_0cb05964,
7929
+ repository: _IRepository_e6004aa6,
7930
+ image_tag: typing.Optional[builtins.str] = None,
7754
7931
  ) -> None:
7755
- '''Construction properties of ``EcsDeployAction``.
7932
+ '''Construction properties of ``EcrSourceAction``.
7756
7933
 
7757
7934
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
7758
7935
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
7759
7936
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
7760
7937
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
7761
- :param service: The ECS Service to deploy.
7762
- :param deployment_timeout: Timeout for the ECS deployment in minutes. Value must be between 1-60. Default: - 60 minutes
7763
- :param image_file: The name of the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'. If you use this property, you don't need to specify the ``input`` property. Default: - one of this property, or ``input``, is required
7764
- :param input: The input artifact that contains the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. If you use this property, it's assumed the file is called 'imagedefinitions.json'. If your build uses a different file, leave this property empty, and use the ``imageFile`` property instead. Default: - one of this property, or ``imageFile``, is required
7938
+ :param output:
7939
+ :param repository: The repository that will be watched for changes.
7940
+ :param image_tag: The image tag that will be checked for changes. It is not possible to trigger on changes to more than one tag. Default: 'latest'
7765
7941
 
7766
7942
  :exampleMetadata: infused
7767
7943
 
7768
7944
  Example::
7769
7945
 
7770
- import aws_cdk.aws_ecs as ecs
7946
+ import aws_cdk.aws_ecr as ecr
7771
7947
 
7772
- # service: ecs.FargateService
7948
+ # ecr_repository: ecr.Repository
7773
7949
 
7774
7950
  pipeline = codepipeline.Pipeline(self, "MyPipeline")
7775
- build_output = codepipeline.Artifact()
7776
- deploy_stage = pipeline.add_stage(
7777
- stage_name="Deploy",
7778
- actions=[
7779
- codepipeline_actions.EcsDeployAction(
7780
- action_name="DeployAction",
7781
- service=service,
7782
- # if your file is called imagedefinitions.json,
7783
- # use the `input` property,
7784
- # and leave out the `imageFile` property
7785
- input=build_output,
7786
- # if your file name is _not_ imagedefinitions.json,
7787
- # use the `imageFile` property,
7788
- # and leave out the `input` property
7789
- image_file=build_output.at_path("imageDef.json"),
7790
- deployment_timeout=Duration.minutes(60)
7791
- )
7792
- ]
7951
+ source_output = codepipeline.Artifact()
7952
+ source_action = codepipeline_actions.EcrSourceAction(
7953
+ action_name="ECR",
7954
+ repository=ecr_repository,
7955
+ image_tag="some-tag", # optional, default: 'latest'
7956
+ output=source_output
7957
+ )
7958
+ pipeline.add_stage(
7959
+ stage_name="Source",
7960
+ actions=[source_action]
7793
7961
  )
7794
7962
  '''
7795
7963
  if __debug__:
7796
- type_hints = typing.get_type_hints(_typecheckingstub__052d1a96cb5e98030c631b73844681f696c3084f35bce11c7436ca1e994cb668)
7964
+ type_hints = typing.get_type_hints(_typecheckingstub__8ba2cd26256aa79e321d4f53bd1f303945241d77de68904ac98b7a536a387ca2)
7797
7965
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
7798
7966
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
7799
7967
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
7800
7968
  check_type(argname="argument role", value=role, expected_type=type_hints["role"])
7801
- check_type(argname="argument service", value=service, expected_type=type_hints["service"])
7802
- check_type(argname="argument deployment_timeout", value=deployment_timeout, expected_type=type_hints["deployment_timeout"])
7803
- check_type(argname="argument image_file", value=image_file, expected_type=type_hints["image_file"])
7804
- check_type(argname="argument input", value=input, expected_type=type_hints["input"])
7969
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
7970
+ check_type(argname="argument repository", value=repository, expected_type=type_hints["repository"])
7971
+ check_type(argname="argument image_tag", value=image_tag, expected_type=type_hints["image_tag"])
7805
7972
  self._values: typing.Dict[builtins.str, typing.Any] = {
7806
7973
  "action_name": action_name,
7807
- "service": service,
7974
+ "output": output,
7975
+ "repository": repository,
7808
7976
  }
7809
7977
  if run_order is not None:
7810
7978
  self._values["run_order"] = run_order
@@ -7812,12 +7980,8 @@ class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
7812
7980
  self._values["variables_namespace"] = variables_namespace
7813
7981
  if role is not None:
7814
7982
  self._values["role"] = role
7815
- if deployment_timeout is not None:
7816
- self._values["deployment_timeout"] = deployment_timeout
7817
- if image_file is not None:
7818
- self._values["image_file"] = image_file
7819
- if input is not None:
7820
- self._values["input"] = input
7983
+ if image_tag is not None:
7984
+ self._values["image_tag"] = image_tag
7821
7985
 
7822
7986
  @builtins.property
7823
7987
  def action_name(self) -> builtins.str:
@@ -7871,59 +8035,28 @@ class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
7871
8035
  return typing.cast(typing.Optional[_IRole_235f5d8e], result)
7872
8036
 
7873
8037
  @builtins.property
7874
- def service(self) -> _IBaseService_3fcdd913:
7875
- '''The ECS Service to deploy.'''
7876
- result = self._values.get("service")
7877
- assert result is not None, "Required property 'service' is missing"
7878
- return typing.cast(_IBaseService_3fcdd913, result)
7879
-
7880
- @builtins.property
7881
- def deployment_timeout(self) -> typing.Optional[_Duration_4839e8c3]:
7882
- '''Timeout for the ECS deployment in minutes.
7883
-
7884
- Value must be between 1-60.
7885
-
7886
- :default: - 60 minutes
7887
-
7888
- :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/action-reference-ECS.html
7889
- '''
7890
- result = self._values.get("deployment_timeout")
7891
- return typing.cast(typing.Optional[_Duration_4839e8c3], result)
8038
+ def output(self) -> _Artifact_0cb05964:
8039
+ result = self._values.get("output")
8040
+ assert result is not None, "Required property 'output' is missing"
8041
+ return typing.cast(_Artifact_0cb05964, result)
7892
8042
 
7893
8043
  @builtins.property
7894
- def image_file(self) -> typing.Optional[_ArtifactPath_bf444090]:
7895
- '''The name of the JSON image definitions file to use for deployments.
7896
-
7897
- The JSON file is a list of objects,
7898
- each with 2 keys: ``name`` is the name of the container in the Task Definition,
7899
- and ``imageUri`` is the Docker image URI you want to update your service with.
7900
- Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'.
7901
- If you use this property, you don't need to specify the ``input`` property.
7902
-
7903
- :default: - one of this property, or ``input``, is required
7904
-
7905
- :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/pipelines-create.html#pipelines-create-image-definitions
7906
- '''
7907
- result = self._values.get("image_file")
7908
- return typing.cast(typing.Optional[_ArtifactPath_bf444090], result)
8044
+ def repository(self) -> _IRepository_e6004aa6:
8045
+ '''The repository that will be watched for changes.'''
8046
+ result = self._values.get("repository")
8047
+ assert result is not None, "Required property 'repository' is missing"
8048
+ return typing.cast(_IRepository_e6004aa6, result)
7909
8049
 
7910
8050
  @builtins.property
7911
- def input(self) -> typing.Optional[_Artifact_0cb05964]:
7912
- '''The input artifact that contains the JSON image definitions file to use for deployments.
7913
-
7914
- The JSON file is a list of objects,
7915
- each with 2 keys: ``name`` is the name of the container in the Task Definition,
7916
- and ``imageUri`` is the Docker image URI you want to update your service with.
7917
- If you use this property, it's assumed the file is called 'imagedefinitions.json'.
7918
- If your build uses a different file, leave this property empty,
7919
- and use the ``imageFile`` property instead.
8051
+ def image_tag(self) -> typing.Optional[builtins.str]:
8052
+ '''The image tag that will be checked for changes.
7920
8053
 
7921
- :default: - one of this property, or ``imageFile``, is required
8054
+ It is not possible to trigger on changes to more than one tag.
7922
8055
 
7923
- :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/pipelines-create.html#pipelines-create-image-definitions
8056
+ :default: 'latest'
7924
8057
  '''
7925
- result = self._values.get("input")
7926
- return typing.cast(typing.Optional[_Artifact_0cb05964], result)
8058
+ result = self._values.get("image_tag")
8059
+ return typing.cast(typing.Optional[builtins.str], result)
7927
8060
 
7928
8061
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
7929
8062
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -7932,62 +8065,184 @@ class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
7932
8065
  return not (rhs == self)
7933
8066
 
7934
8067
  def __repr__(self) -> str:
7935
- return "EcsDeployActionProps(%s)" % ", ".join(
8068
+ return "EcrSourceActionProps(%s)" % ", ".join(
7936
8069
  k + "=" + repr(v) for k, v in self._values.items()
7937
8070
  )
7938
8071
 
7939
8072
 
7940
- class ElasticBeanstalkDeployAction(
7941
- Action,
7942
- metaclass=jsii.JSIIMeta,
7943
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.ElasticBeanstalkDeployAction",
7944
- ):
7945
- '''CodePipeline action to deploy an AWS ElasticBeanstalk Application.
7946
-
8073
+ @jsii.data_type(
8074
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcrSourceVariables",
8075
+ jsii_struct_bases=[],
8076
+ name_mapping={
8077
+ "image_digest": "imageDigest",
8078
+ "image_tag": "imageTag",
8079
+ "image_uri": "imageUri",
8080
+ "registry_id": "registryId",
8081
+ "repository_name": "repositoryName",
8082
+ },
8083
+ )
8084
+ class EcrSourceVariables:
8085
+ def __init__(
8086
+ self,
8087
+ *,
8088
+ image_digest: builtins.str,
8089
+ image_tag: builtins.str,
8090
+ image_uri: builtins.str,
8091
+ registry_id: builtins.str,
8092
+ repository_name: builtins.str,
8093
+ ) -> None:
8094
+ '''The CodePipeline variables emitted by the ECR source Action.
8095
+
8096
+ :param image_digest: The digest of the current image, in the form ':'.
8097
+ :param image_tag: The Docker tag of the current image.
8098
+ :param image_uri: The full ECR Docker URI of the current image.
8099
+ :param registry_id: The identifier of the registry. In ECR, this is usually the ID of the AWS account owning it.
8100
+ :param repository_name: The physical name of the repository that this action tracks.
8101
+
8102
+ :exampleMetadata: fixture=_generated
8103
+
8104
+ Example::
8105
+
8106
+ # The code below shows an example of how to instantiate this type.
8107
+ # The values are placeholders you should change.
8108
+ from aws_cdk import aws_codepipeline_actions as codepipeline_actions
8109
+
8110
+ ecr_source_variables = codepipeline_actions.EcrSourceVariables(
8111
+ image_digest="imageDigest",
8112
+ image_tag="imageTag",
8113
+ image_uri="imageUri",
8114
+ registry_id="registryId",
8115
+ repository_name="repositoryName"
8116
+ )
8117
+ '''
8118
+ if __debug__:
8119
+ type_hints = typing.get_type_hints(_typecheckingstub__2f3d2afe9ce2a85b2adf5373670c98f28d033d6c9016a1eb341ffa79450e6869)
8120
+ check_type(argname="argument image_digest", value=image_digest, expected_type=type_hints["image_digest"])
8121
+ check_type(argname="argument image_tag", value=image_tag, expected_type=type_hints["image_tag"])
8122
+ check_type(argname="argument image_uri", value=image_uri, expected_type=type_hints["image_uri"])
8123
+ check_type(argname="argument registry_id", value=registry_id, expected_type=type_hints["registry_id"])
8124
+ check_type(argname="argument repository_name", value=repository_name, expected_type=type_hints["repository_name"])
8125
+ self._values: typing.Dict[builtins.str, typing.Any] = {
8126
+ "image_digest": image_digest,
8127
+ "image_tag": image_tag,
8128
+ "image_uri": image_uri,
8129
+ "registry_id": registry_id,
8130
+ "repository_name": repository_name,
8131
+ }
8132
+
8133
+ @builtins.property
8134
+ def image_digest(self) -> builtins.str:
8135
+ '''The digest of the current image, in the form ':'.'''
8136
+ result = self._values.get("image_digest")
8137
+ assert result is not None, "Required property 'image_digest' is missing"
8138
+ return typing.cast(builtins.str, result)
8139
+
8140
+ @builtins.property
8141
+ def image_tag(self) -> builtins.str:
8142
+ '''The Docker tag of the current image.'''
8143
+ result = self._values.get("image_tag")
8144
+ assert result is not None, "Required property 'image_tag' is missing"
8145
+ return typing.cast(builtins.str, result)
8146
+
8147
+ @builtins.property
8148
+ def image_uri(self) -> builtins.str:
8149
+ '''The full ECR Docker URI of the current image.'''
8150
+ result = self._values.get("image_uri")
8151
+ assert result is not None, "Required property 'image_uri' is missing"
8152
+ return typing.cast(builtins.str, result)
8153
+
8154
+ @builtins.property
8155
+ def registry_id(self) -> builtins.str:
8156
+ '''The identifier of the registry.
8157
+
8158
+ In ECR, this is usually the ID of the AWS account owning it.
8159
+ '''
8160
+ result = self._values.get("registry_id")
8161
+ assert result is not None, "Required property 'registry_id' is missing"
8162
+ return typing.cast(builtins.str, result)
8163
+
8164
+ @builtins.property
8165
+ def repository_name(self) -> builtins.str:
8166
+ '''The physical name of the repository that this action tracks.'''
8167
+ result = self._values.get("repository_name")
8168
+ assert result is not None, "Required property 'repository_name' is missing"
8169
+ return typing.cast(builtins.str, result)
8170
+
8171
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
8172
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
8173
+
8174
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
8175
+ return not (rhs == self)
8176
+
8177
+ def __repr__(self) -> str:
8178
+ return "EcrSourceVariables(%s)" % ", ".join(
8179
+ k + "=" + repr(v) for k, v in self._values.items()
8180
+ )
8181
+
8182
+
8183
+ class EcsDeployAction(
8184
+ Action,
8185
+ metaclass=jsii.JSIIMeta,
8186
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcsDeployAction",
8187
+ ):
8188
+ '''CodePipeline Action to deploy an ECS Service.
8189
+
7947
8190
  :exampleMetadata: infused
7948
8191
 
7949
8192
  Example::
7950
8193
 
7951
- source_output = codepipeline.Artifact()
7952
- target_bucket = s3.Bucket(self, "MyBucket")
8194
+ import aws_cdk.aws_ecs as ecs
7953
8195
 
7954
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
7955
- deploy_action = codepipeline_actions.ElasticBeanstalkDeployAction(
7956
- action_name="ElasticBeanstalkDeploy",
7957
- input=source_output,
7958
- environment_name="envName",
7959
- application_name="appName"
7960
- )
8196
+ # service: ecs.FargateService
7961
8197
 
8198
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8199
+ build_output = codepipeline.Artifact()
7962
8200
  deploy_stage = pipeline.add_stage(
7963
8201
  stage_name="Deploy",
7964
- actions=[deploy_action]
8202
+ actions=[
8203
+ codepipeline_actions.EcsDeployAction(
8204
+ action_name="DeployAction",
8205
+ service=service,
8206
+ # if your file is called imagedefinitions.json,
8207
+ # use the `input` property,
8208
+ # and leave out the `imageFile` property
8209
+ input=build_output,
8210
+ # if your file name is _not_ imagedefinitions.json,
8211
+ # use the `imageFile` property,
8212
+ # and leave out the `input` property
8213
+ image_file=build_output.at_path("imageDef.json"),
8214
+ deployment_timeout=Duration.minutes(60)
8215
+ )
8216
+ ]
7965
8217
  )
7966
8218
  '''
7967
8219
 
7968
8220
  def __init__(
7969
8221
  self,
7970
8222
  *,
7971
- application_name: builtins.str,
7972
- environment_name: builtins.str,
7973
- input: _Artifact_0cb05964,
8223
+ service: _IBaseService_3fcdd913,
8224
+ deployment_timeout: typing.Optional[_Duration_4839e8c3] = None,
8225
+ image_file: typing.Optional[_ArtifactPath_bf444090] = None,
8226
+ input: typing.Optional[_Artifact_0cb05964] = None,
7974
8227
  role: typing.Optional[_IRole_235f5d8e] = None,
7975
8228
  action_name: builtins.str,
7976
8229
  run_order: typing.Optional[jsii.Number] = None,
7977
8230
  variables_namespace: typing.Optional[builtins.str] = None,
7978
8231
  ) -> None:
7979
8232
  '''
7980
- :param application_name: The name of the AWS Elastic Beanstalk application to deploy.
7981
- :param environment_name: The name of the AWS Elastic Beanstalk environment to deploy to.
7982
- :param input: The source to use as input for deployment.
8233
+ :param service: The ECS Service to deploy.
8234
+ :param deployment_timeout: Timeout for the ECS deployment in minutes. Value must be between 1-60. Default: - 60 minutes
8235
+ :param image_file: The name of the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'. If you use this property, you don't need to specify the ``input`` property. Default: - one of this property, or ``input``, is required
8236
+ :param input: The input artifact that contains the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. If you use this property, it's assumed the file is called 'imagedefinitions.json'. If your build uses a different file, leave this property empty, and use the ``imageFile`` property instead. Default: - one of this property, or ``imageFile``, is required
7983
8237
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
7984
8238
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
7985
8239
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
7986
8240
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
7987
8241
  '''
7988
- props = ElasticBeanstalkDeployActionProps(
7989
- application_name=application_name,
7990
- environment_name=environment_name,
8242
+ props = EcsDeployActionProps(
8243
+ service=service,
8244
+ deployment_timeout=deployment_timeout,
8245
+ image_file=image_file,
7991
8246
  input=input,
7992
8247
  role=role,
7993
8248
  action_name=action_name,
@@ -8014,7 +8269,7 @@ class ElasticBeanstalkDeployAction(
8014
8269
  :param role:
8015
8270
  '''
8016
8271
  if __debug__:
8017
- type_hints = typing.get_type_hints(_typecheckingstub__90d15e5a70442fef857b5816004694cfb626f4f582d5c9ed8e730f6c4815b190)
8272
+ type_hints = typing.get_type_hints(_typecheckingstub__be96a039b024c460a7c791a692e2aa8519216e3bb3e6afdbbddda461d96791e4)
8018
8273
  check_type(argname="argument _scope", value=_scope, expected_type=type_hints["_scope"])
8019
8274
  check_type(argname="argument _stage", value=_stage, expected_type=type_hints["_stage"])
8020
8275
  options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
@@ -8023,19 +8278,20 @@ class ElasticBeanstalkDeployAction(
8023
8278
 
8024
8279
 
8025
8280
  @jsii.data_type(
8026
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.ElasticBeanstalkDeployActionProps",
8281
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.EcsDeployActionProps",
8027
8282
  jsii_struct_bases=[_CommonAwsActionProps_8b809bb6],
8028
8283
  name_mapping={
8029
8284
  "action_name": "actionName",
8030
8285
  "run_order": "runOrder",
8031
8286
  "variables_namespace": "variablesNamespace",
8032
8287
  "role": "role",
8033
- "application_name": "applicationName",
8034
- "environment_name": "environmentName",
8288
+ "service": "service",
8289
+ "deployment_timeout": "deploymentTimeout",
8290
+ "image_file": "imageFile",
8035
8291
  "input": "input",
8036
8292
  },
8037
8293
  )
8038
- class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8294
+ class EcsDeployActionProps(_CommonAwsActionProps_8b809bb6):
8039
8295
  def __init__(
8040
8296
  self,
8041
8297
  *,
@@ -8043,54 +8299,64 @@ class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8043
8299
  run_order: typing.Optional[jsii.Number] = None,
8044
8300
  variables_namespace: typing.Optional[builtins.str] = None,
8045
8301
  role: typing.Optional[_IRole_235f5d8e] = None,
8046
- application_name: builtins.str,
8047
- environment_name: builtins.str,
8048
- input: _Artifact_0cb05964,
8302
+ service: _IBaseService_3fcdd913,
8303
+ deployment_timeout: typing.Optional[_Duration_4839e8c3] = None,
8304
+ image_file: typing.Optional[_ArtifactPath_bf444090] = None,
8305
+ input: typing.Optional[_Artifact_0cb05964] = None,
8049
8306
  ) -> None:
8050
- '''Construction properties of the ``ElasticBeanstalkDeployAction Elastic Beanstalk deploy CodePipeline Action``.
8307
+ '''Construction properties of ``EcsDeployAction``.
8051
8308
 
8052
8309
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
8053
8310
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
8054
8311
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
8055
8312
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
8056
- :param application_name: The name of the AWS Elastic Beanstalk application to deploy.
8057
- :param environment_name: The name of the AWS Elastic Beanstalk environment to deploy to.
8058
- :param input: The source to use as input for deployment.
8313
+ :param service: The ECS Service to deploy.
8314
+ :param deployment_timeout: Timeout for the ECS deployment in minutes. Value must be between 1-60. Default: - 60 minutes
8315
+ :param image_file: The name of the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'. If you use this property, you don't need to specify the ``input`` property. Default: - one of this property, or ``input``, is required
8316
+ :param input: The input artifact that contains the JSON image definitions file to use for deployments. The JSON file is a list of objects, each with 2 keys: ``name`` is the name of the container in the Task Definition, and ``imageUri`` is the Docker image URI you want to update your service with. If you use this property, it's assumed the file is called 'imagedefinitions.json'. If your build uses a different file, leave this property empty, and use the ``imageFile`` property instead. Default: - one of this property, or ``imageFile``, is required
8059
8317
 
8060
8318
  :exampleMetadata: infused
8061
8319
 
8062
8320
  Example::
8063
8321
 
8064
- source_output = codepipeline.Artifact()
8065
- target_bucket = s3.Bucket(self, "MyBucket")
8322
+ import aws_cdk.aws_ecs as ecs
8066
8323
 
8067
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
8068
- deploy_action = codepipeline_actions.ElasticBeanstalkDeployAction(
8069
- action_name="ElasticBeanstalkDeploy",
8070
- input=source_output,
8071
- environment_name="envName",
8072
- application_name="appName"
8073
- )
8324
+ # service: ecs.FargateService
8074
8325
 
8326
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8327
+ build_output = codepipeline.Artifact()
8075
8328
  deploy_stage = pipeline.add_stage(
8076
8329
  stage_name="Deploy",
8077
- actions=[deploy_action]
8330
+ actions=[
8331
+ codepipeline_actions.EcsDeployAction(
8332
+ action_name="DeployAction",
8333
+ service=service,
8334
+ # if your file is called imagedefinitions.json,
8335
+ # use the `input` property,
8336
+ # and leave out the `imageFile` property
8337
+ input=build_output,
8338
+ # if your file name is _not_ imagedefinitions.json,
8339
+ # use the `imageFile` property,
8340
+ # and leave out the `input` property
8341
+ image_file=build_output.at_path("imageDef.json"),
8342
+ deployment_timeout=Duration.minutes(60)
8343
+ )
8344
+ ]
8078
8345
  )
8079
8346
  '''
8080
8347
  if __debug__:
8081
- type_hints = typing.get_type_hints(_typecheckingstub__7dfb6eab17a4b9c49e6f29e3d5131f77f2005e43cb0d72bd5908a97cc91ac140)
8348
+ type_hints = typing.get_type_hints(_typecheckingstub__052d1a96cb5e98030c631b73844681f696c3084f35bce11c7436ca1e994cb668)
8082
8349
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
8083
8350
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
8084
8351
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
8085
8352
  check_type(argname="argument role", value=role, expected_type=type_hints["role"])
8086
- check_type(argname="argument application_name", value=application_name, expected_type=type_hints["application_name"])
8087
- check_type(argname="argument environment_name", value=environment_name, expected_type=type_hints["environment_name"])
8353
+ check_type(argname="argument service", value=service, expected_type=type_hints["service"])
8354
+ check_type(argname="argument deployment_timeout", value=deployment_timeout, expected_type=type_hints["deployment_timeout"])
8355
+ check_type(argname="argument image_file", value=image_file, expected_type=type_hints["image_file"])
8088
8356
  check_type(argname="argument input", value=input, expected_type=type_hints["input"])
8089
8357
  self._values: typing.Dict[builtins.str, typing.Any] = {
8090
8358
  "action_name": action_name,
8091
- "application_name": application_name,
8092
- "environment_name": environment_name,
8093
- "input": input,
8359
+ "service": service,
8094
8360
  }
8095
8361
  if run_order is not None:
8096
8362
  self._values["run_order"] = run_order
@@ -8098,6 +8364,12 @@ class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8098
8364
  self._values["variables_namespace"] = variables_namespace
8099
8365
  if role is not None:
8100
8366
  self._values["role"] = role
8367
+ if deployment_timeout is not None:
8368
+ self._values["deployment_timeout"] = deployment_timeout
8369
+ if image_file is not None:
8370
+ self._values["image_file"] = image_file
8371
+ if input is not None:
8372
+ self._values["input"] = input
8101
8373
 
8102
8374
  @builtins.property
8103
8375
  def action_name(self) -> builtins.str:
@@ -8151,25 +8423,59 @@ class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8151
8423
  return typing.cast(typing.Optional[_IRole_235f5d8e], result)
8152
8424
 
8153
8425
  @builtins.property
8154
- def application_name(self) -> builtins.str:
8155
- '''The name of the AWS Elastic Beanstalk application to deploy.'''
8156
- result = self._values.get("application_name")
8157
- assert result is not None, "Required property 'application_name' is missing"
8158
- return typing.cast(builtins.str, result)
8426
+ def service(self) -> _IBaseService_3fcdd913:
8427
+ '''The ECS Service to deploy.'''
8428
+ result = self._values.get("service")
8429
+ assert result is not None, "Required property 'service' is missing"
8430
+ return typing.cast(_IBaseService_3fcdd913, result)
8159
8431
 
8160
8432
  @builtins.property
8161
- def environment_name(self) -> builtins.str:
8162
- '''The name of the AWS Elastic Beanstalk environment to deploy to.'''
8163
- result = self._values.get("environment_name")
8164
- assert result is not None, "Required property 'environment_name' is missing"
8165
- return typing.cast(builtins.str, result)
8166
-
8433
+ def deployment_timeout(self) -> typing.Optional[_Duration_4839e8c3]:
8434
+ '''Timeout for the ECS deployment in minutes.
8435
+
8436
+ Value must be between 1-60.
8437
+
8438
+ :default: - 60 minutes
8439
+
8440
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/action-reference-ECS.html
8441
+ '''
8442
+ result = self._values.get("deployment_timeout")
8443
+ return typing.cast(typing.Optional[_Duration_4839e8c3], result)
8444
+
8167
8445
  @builtins.property
8168
- def input(self) -> _Artifact_0cb05964:
8169
- '''The source to use as input for deployment.'''
8446
+ def image_file(self) -> typing.Optional[_ArtifactPath_bf444090]:
8447
+ '''The name of the JSON image definitions file to use for deployments.
8448
+
8449
+ The JSON file is a list of objects,
8450
+ each with 2 keys: ``name`` is the name of the container in the Task Definition,
8451
+ and ``imageUri`` is the Docker image URI you want to update your service with.
8452
+ Use this property if you want to use a different name for this file than the default 'imagedefinitions.json'.
8453
+ If you use this property, you don't need to specify the ``input`` property.
8454
+
8455
+ :default: - one of this property, or ``input``, is required
8456
+
8457
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/pipelines-create.html#pipelines-create-image-definitions
8458
+ '''
8459
+ result = self._values.get("image_file")
8460
+ return typing.cast(typing.Optional[_ArtifactPath_bf444090], result)
8461
+
8462
+ @builtins.property
8463
+ def input(self) -> typing.Optional[_Artifact_0cb05964]:
8464
+ '''The input artifact that contains the JSON image definitions file to use for deployments.
8465
+
8466
+ The JSON file is a list of objects,
8467
+ each with 2 keys: ``name`` is the name of the container in the Task Definition,
8468
+ and ``imageUri`` is the Docker image URI you want to update your service with.
8469
+ If you use this property, it's assumed the file is called 'imagedefinitions.json'.
8470
+ If your build uses a different file, leave this property empty,
8471
+ and use the ``imageFile`` property instead.
8472
+
8473
+ :default: - one of this property, or ``imageFile``, is required
8474
+
8475
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/pipelines-create.html#pipelines-create-image-definitions
8476
+ '''
8170
8477
  result = self._values.get("input")
8171
- assert result is not None, "Required property 'input' is missing"
8172
- return typing.cast(_Artifact_0cb05964, result)
8478
+ return typing.cast(typing.Optional[_Artifact_0cb05964], result)
8173
8479
 
8174
8480
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
8175
8481
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -8178,70 +8484,64 @@ class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8178
8484
  return not (rhs == self)
8179
8485
 
8180
8486
  def __repr__(self) -> str:
8181
- return "ElasticBeanstalkDeployActionProps(%s)" % ", ".join(
8487
+ return "EcsDeployActionProps(%s)" % ", ".join(
8182
8488
  k + "=" + repr(v) for k, v in self._values.items()
8183
8489
  )
8184
8490
 
8185
8491
 
8186
- class GitHubSourceAction(
8492
+ class ElasticBeanstalkDeployAction(
8187
8493
  Action,
8188
8494
  metaclass=jsii.JSIIMeta,
8189
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceAction",
8495
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.ElasticBeanstalkDeployAction",
8190
8496
  ):
8191
- '''Source that is provided by a GitHub repository.
8497
+ '''CodePipeline action to deploy an AWS ElasticBeanstalk Application.
8192
8498
 
8193
8499
  :exampleMetadata: infused
8194
8500
 
8195
8501
  Example::
8196
8502
 
8197
- # Read the secret from Secrets Manager
8198
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
8199
8503
  source_output = codepipeline.Artifact()
8200
- source_action = codepipeline_actions.GitHubSourceAction(
8201
- action_name="GitHub_Source",
8202
- owner="awslabs",
8203
- repo="aws-cdk",
8204
- oauth_token=SecretValue.secrets_manager("my-github-token"),
8205
- output=source_output,
8206
- branch="develop"
8504
+ target_bucket = s3.Bucket(self, "MyBucket")
8505
+
8506
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8507
+ deploy_action = codepipeline_actions.ElasticBeanstalkDeployAction(
8508
+ action_name="ElasticBeanstalkDeploy",
8509
+ input=source_output,
8510
+ environment_name="envName",
8511
+ application_name="appName"
8207
8512
  )
8208
- pipeline.add_stage(
8209
- stage_name="Source",
8210
- actions=[source_action]
8513
+
8514
+ deploy_stage = pipeline.add_stage(
8515
+ stage_name="Deploy",
8516
+ actions=[deploy_action]
8211
8517
  )
8212
8518
  '''
8213
8519
 
8214
8520
  def __init__(
8215
8521
  self,
8216
8522
  *,
8217
- oauth_token: _SecretValue_3dd0ddae,
8218
- output: _Artifact_0cb05964,
8219
- owner: builtins.str,
8220
- repo: builtins.str,
8221
- branch: typing.Optional[builtins.str] = None,
8222
- trigger: typing.Optional["GitHubTrigger"] = None,
8523
+ application_name: builtins.str,
8524
+ environment_name: builtins.str,
8525
+ input: _Artifact_0cb05964,
8526
+ role: typing.Optional[_IRole_235f5d8e] = None,
8223
8527
  action_name: builtins.str,
8224
8528
  run_order: typing.Optional[jsii.Number] = None,
8225
8529
  variables_namespace: typing.Optional[builtins.str] = None,
8226
8530
  ) -> None:
8227
8531
  '''
8228
- :param oauth_token: A GitHub OAuth token to use for authentication. It is recommended to use a Secrets Manager ``Secret`` to obtain the token: const oauth = cdk.SecretValue.secretsManager('my-github-token'); new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... }); If you rotate the value in the Secret, you must also change at least one property of the CodePipeline to force CloudFormation to re-read the secret. The GitHub Personal Access Token should have these scopes: - **repo** - to read the repository - **admin:repo_hook** - if you plan to use webhooks (true by default)
8229
- :param output:
8230
- :param owner: The GitHub account/user that owns the repo.
8231
- :param repo: The name of the repo, without the username.
8232
- :param branch: The branch to use. Default: "master"
8233
- :param trigger: How AWS CodePipeline should be triggered. With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action With "POLL", CodePipeline periodically checks the source for changes With "None", the action is not triggered through changes in the source To use ``WEBHOOK``, your GitHub Personal Access Token should have **admin:repo_hook** scope (in addition to the regular **repo** scope). Default: GitHubTrigger.WEBHOOK
8532
+ :param application_name: The name of the AWS Elastic Beanstalk application to deploy.
8533
+ :param environment_name: The name of the AWS Elastic Beanstalk environment to deploy to.
8534
+ :param input: The source to use as input for deployment.
8535
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
8234
8536
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
8235
8537
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
8236
8538
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
8237
8539
  '''
8238
- props = GitHubSourceActionProps(
8239
- oauth_token=oauth_token,
8240
- output=output,
8241
- owner=owner,
8242
- repo=repo,
8243
- branch=branch,
8244
- trigger=trigger,
8540
+ props = ElasticBeanstalkDeployActionProps(
8541
+ application_name=application_name,
8542
+ environment_name=environment_name,
8543
+ input=input,
8544
+ role=role,
8245
8545
  action_name=action_name,
8246
8546
  run_order=run_order,
8247
8547
  variables_namespace=variables_namespace,
@@ -8252,121 +8552,104 @@ class GitHubSourceAction(
8252
8552
  @jsii.member(jsii_name="bound")
8253
8553
  def _bound(
8254
8554
  self,
8255
- scope: _constructs_77d1e7e8.Construct,
8256
- stage: _IStage_415fc571,
8555
+ _scope: _constructs_77d1e7e8.Construct,
8556
+ _stage: _IStage_415fc571,
8257
8557
  *,
8258
8558
  bucket: _IBucket_42e086fd,
8259
8559
  role: _IRole_235f5d8e,
8260
8560
  ) -> _ActionConfig_846fc217:
8261
8561
  '''This is a renamed version of the ``IAction.bind`` method.
8262
8562
 
8263
- :param scope: -
8264
- :param stage: -
8563
+ :param _scope: -
8564
+ :param _stage: -
8265
8565
  :param bucket:
8266
8566
  :param role:
8267
8567
  '''
8268
8568
  if __debug__:
8269
- type_hints = typing.get_type_hints(_typecheckingstub__0d8955359f0f5e27f55406175fafdd393ec53543baf2e52d8ee262c5b113fa80)
8270
- check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
8271
- check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
8272
- _options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
8273
-
8274
- return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, _options]))
8569
+ type_hints = typing.get_type_hints(_typecheckingstub__90d15e5a70442fef857b5816004694cfb626f4f582d5c9ed8e730f6c4815b190)
8570
+ check_type(argname="argument _scope", value=_scope, expected_type=type_hints["_scope"])
8571
+ check_type(argname="argument _stage", value=_stage, expected_type=type_hints["_stage"])
8572
+ options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
8275
8573
 
8276
- @builtins.property
8277
- @jsii.member(jsii_name="variables")
8278
- def variables(self) -> "GitHubSourceVariables":
8279
- '''The variables emitted by this action.'''
8280
- return typing.cast("GitHubSourceVariables", jsii.get(self, "variables"))
8574
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [_scope, _stage, options]))
8281
8575
 
8282
8576
 
8283
8577
  @jsii.data_type(
8284
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceActionProps",
8285
- jsii_struct_bases=[_CommonActionProps_e3aaeecb],
8578
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.ElasticBeanstalkDeployActionProps",
8579
+ jsii_struct_bases=[_CommonAwsActionProps_8b809bb6],
8286
8580
  name_mapping={
8287
8581
  "action_name": "actionName",
8288
8582
  "run_order": "runOrder",
8289
8583
  "variables_namespace": "variablesNamespace",
8290
- "oauth_token": "oauthToken",
8291
- "output": "output",
8292
- "owner": "owner",
8293
- "repo": "repo",
8294
- "branch": "branch",
8295
- "trigger": "trigger",
8584
+ "role": "role",
8585
+ "application_name": "applicationName",
8586
+ "environment_name": "environmentName",
8587
+ "input": "input",
8296
8588
  },
8297
8589
  )
8298
- class GitHubSourceActionProps(_CommonActionProps_e3aaeecb):
8590
+ class ElasticBeanstalkDeployActionProps(_CommonAwsActionProps_8b809bb6):
8299
8591
  def __init__(
8300
8592
  self,
8301
8593
  *,
8302
8594
  action_name: builtins.str,
8303
8595
  run_order: typing.Optional[jsii.Number] = None,
8304
8596
  variables_namespace: typing.Optional[builtins.str] = None,
8305
- oauth_token: _SecretValue_3dd0ddae,
8306
- output: _Artifact_0cb05964,
8307
- owner: builtins.str,
8308
- repo: builtins.str,
8309
- branch: typing.Optional[builtins.str] = None,
8310
- trigger: typing.Optional["GitHubTrigger"] = None,
8597
+ role: typing.Optional[_IRole_235f5d8e] = None,
8598
+ application_name: builtins.str,
8599
+ environment_name: builtins.str,
8600
+ input: _Artifact_0cb05964,
8311
8601
  ) -> None:
8312
- '''Construction properties of the ``GitHubSourceAction GitHub source action``.
8602
+ '''Construction properties of the ``ElasticBeanstalkDeployAction Elastic Beanstalk deploy CodePipeline Action``.
8313
8603
 
8314
8604
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
8315
8605
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
8316
8606
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
8317
- :param oauth_token: A GitHub OAuth token to use for authentication. It is recommended to use a Secrets Manager ``Secret`` to obtain the token: const oauth = cdk.SecretValue.secretsManager('my-github-token'); new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... }); If you rotate the value in the Secret, you must also change at least one property of the CodePipeline to force CloudFormation to re-read the secret. The GitHub Personal Access Token should have these scopes: - **repo** - to read the repository - **admin:repo_hook** - if you plan to use webhooks (true by default)
8318
- :param output:
8319
- :param owner: The GitHub account/user that owns the repo.
8320
- :param repo: The name of the repo, without the username.
8321
- :param branch: The branch to use. Default: "master"
8322
- :param trigger: How AWS CodePipeline should be triggered. With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action With "POLL", CodePipeline periodically checks the source for changes With "None", the action is not triggered through changes in the source To use ``WEBHOOK``, your GitHub Personal Access Token should have **admin:repo_hook** scope (in addition to the regular **repo** scope). Default: GitHubTrigger.WEBHOOK
8607
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
8608
+ :param application_name: The name of the AWS Elastic Beanstalk application to deploy.
8609
+ :param environment_name: The name of the AWS Elastic Beanstalk environment to deploy to.
8610
+ :param input: The source to use as input for deployment.
8323
8611
 
8324
8612
  :exampleMetadata: infused
8325
8613
 
8326
8614
  Example::
8327
8615
 
8328
- # Read the secret from Secrets Manager
8329
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
8330
8616
  source_output = codepipeline.Artifact()
8331
- source_action = codepipeline_actions.GitHubSourceAction(
8332
- action_name="GitHub_Source",
8333
- owner="awslabs",
8334
- repo="aws-cdk",
8335
- oauth_token=SecretValue.secrets_manager("my-github-token"),
8336
- output=source_output,
8337
- branch="develop"
8617
+ target_bucket = s3.Bucket(self, "MyBucket")
8618
+
8619
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8620
+ deploy_action = codepipeline_actions.ElasticBeanstalkDeployAction(
8621
+ action_name="ElasticBeanstalkDeploy",
8622
+ input=source_output,
8623
+ environment_name="envName",
8624
+ application_name="appName"
8338
8625
  )
8339
- pipeline.add_stage(
8340
- stage_name="Source",
8341
- actions=[source_action]
8626
+
8627
+ deploy_stage = pipeline.add_stage(
8628
+ stage_name="Deploy",
8629
+ actions=[deploy_action]
8342
8630
  )
8343
8631
  '''
8344
8632
  if __debug__:
8345
- type_hints = typing.get_type_hints(_typecheckingstub__5b86a9f2777055875dffe46f70e2990f3cbd3a06cc388b84510ff390d7dac9fd)
8633
+ type_hints = typing.get_type_hints(_typecheckingstub__7dfb6eab17a4b9c49e6f29e3d5131f77f2005e43cb0d72bd5908a97cc91ac140)
8346
8634
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
8347
8635
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
8348
8636
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
8349
- check_type(argname="argument oauth_token", value=oauth_token, expected_type=type_hints["oauth_token"])
8350
- check_type(argname="argument output", value=output, expected_type=type_hints["output"])
8351
- check_type(argname="argument owner", value=owner, expected_type=type_hints["owner"])
8352
- check_type(argname="argument repo", value=repo, expected_type=type_hints["repo"])
8353
- check_type(argname="argument branch", value=branch, expected_type=type_hints["branch"])
8354
- check_type(argname="argument trigger", value=trigger, expected_type=type_hints["trigger"])
8637
+ check_type(argname="argument role", value=role, expected_type=type_hints["role"])
8638
+ check_type(argname="argument application_name", value=application_name, expected_type=type_hints["application_name"])
8639
+ check_type(argname="argument environment_name", value=environment_name, expected_type=type_hints["environment_name"])
8640
+ check_type(argname="argument input", value=input, expected_type=type_hints["input"])
8355
8641
  self._values: typing.Dict[builtins.str, typing.Any] = {
8356
8642
  "action_name": action_name,
8357
- "oauth_token": oauth_token,
8358
- "output": output,
8359
- "owner": owner,
8360
- "repo": repo,
8643
+ "application_name": application_name,
8644
+ "environment_name": environment_name,
8645
+ "input": input,
8361
8646
  }
8362
8647
  if run_order is not None:
8363
8648
  self._values["run_order"] = run_order
8364
8649
  if variables_namespace is not None:
8365
8650
  self._values["variables_namespace"] = variables_namespace
8366
- if branch is not None:
8367
- self._values["branch"] = branch
8368
- if trigger is not None:
8369
- self._values["trigger"] = trigger
8651
+ if role is not None:
8652
+ self._values["role"] = role
8370
8653
 
8371
8654
  @builtins.property
8372
8655
  def action_name(self) -> builtins.str:
@@ -8405,72 +8688,921 @@ class GitHubSourceActionProps(_CommonActionProps_e3aaeecb):
8405
8688
  return typing.cast(typing.Optional[builtins.str], result)
8406
8689
 
8407
8690
  @builtins.property
8408
- def oauth_token(self) -> _SecretValue_3dd0ddae:
8409
- '''A GitHub OAuth token to use for authentication.
8410
-
8411
- It is recommended to use a Secrets Manager ``Secret`` to obtain the token:
8412
-
8413
- const oauth = cdk.SecretValue.secretsManager('my-github-token');
8414
- new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... });
8415
-
8416
- If you rotate the value in the Secret, you must also change at least one property
8417
- of the CodePipeline to force CloudFormation to re-read the secret.
8418
-
8419
- The GitHub Personal Access Token should have these scopes:
8691
+ def role(self) -> typing.Optional[_IRole_235f5d8e]:
8692
+ '''The Role in which context's this Action will be executing in.
8420
8693
 
8421
- - **repo** - to read the repository
8422
- - **admin:repo_hook** - if you plan to use webhooks (true by default)
8694
+ The Pipeline's Role will assume this Role
8695
+ (the required permissions for that will be granted automatically)
8696
+ right before executing this Action.
8697
+ This Action will be passed into your ``IAction.bind``
8698
+ method in the ``ActionBindOptions.role`` property.
8423
8699
 
8424
- :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/appendix-github-oauth.html#GitHub-create-personal-token-CLI
8700
+ :default: a new Role will be generated
8425
8701
  '''
8426
- result = self._values.get("oauth_token")
8427
- assert result is not None, "Required property 'oauth_token' is missing"
8428
- return typing.cast(_SecretValue_3dd0ddae, result)
8702
+ result = self._values.get("role")
8703
+ return typing.cast(typing.Optional[_IRole_235f5d8e], result)
8429
8704
 
8430
8705
  @builtins.property
8431
- def output(self) -> _Artifact_0cb05964:
8432
- result = self._values.get("output")
8433
- assert result is not None, "Required property 'output' is missing"
8434
- return typing.cast(_Artifact_0cb05964, result)
8435
-
8706
+ def application_name(self) -> builtins.str:
8707
+ '''The name of the AWS Elastic Beanstalk application to deploy.'''
8708
+ result = self._values.get("application_name")
8709
+ assert result is not None, "Required property 'application_name' is missing"
8710
+ return typing.cast(builtins.str, result)
8711
+
8436
8712
  @builtins.property
8437
- def owner(self) -> builtins.str:
8438
- '''The GitHub account/user that owns the repo.'''
8439
- result = self._values.get("owner")
8440
- assert result is not None, "Required property 'owner' is missing"
8713
+ def environment_name(self) -> builtins.str:
8714
+ '''The name of the AWS Elastic Beanstalk environment to deploy to.'''
8715
+ result = self._values.get("environment_name")
8716
+ assert result is not None, "Required property 'environment_name' is missing"
8717
+ return typing.cast(builtins.str, result)
8718
+
8719
+ @builtins.property
8720
+ def input(self) -> _Artifact_0cb05964:
8721
+ '''The source to use as input for deployment.'''
8722
+ result = self._values.get("input")
8723
+ assert result is not None, "Required property 'input' is missing"
8724
+ return typing.cast(_Artifact_0cb05964, result)
8725
+
8726
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
8727
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
8728
+
8729
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
8730
+ return not (rhs == self)
8731
+
8732
+ def __repr__(self) -> str:
8733
+ return "ElasticBeanstalkDeployActionProps(%s)" % ", ".join(
8734
+ k + "=" + repr(v) for k, v in self._values.items()
8735
+ )
8736
+
8737
+
8738
+ class GitHubSourceAction(
8739
+ Action,
8740
+ metaclass=jsii.JSIIMeta,
8741
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceAction",
8742
+ ):
8743
+ '''Source that is provided by a GitHub repository.
8744
+
8745
+ :exampleMetadata: infused
8746
+
8747
+ Example::
8748
+
8749
+ # Read the secret from Secrets Manager
8750
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8751
+ source_output = codepipeline.Artifact()
8752
+ source_action = codepipeline_actions.GitHubSourceAction(
8753
+ action_name="GitHub_Source",
8754
+ owner="awslabs",
8755
+ repo="aws-cdk",
8756
+ oauth_token=SecretValue.secrets_manager("my-github-token"),
8757
+ output=source_output,
8758
+ branch="develop"
8759
+ )
8760
+ pipeline.add_stage(
8761
+ stage_name="Source",
8762
+ actions=[source_action]
8763
+ )
8764
+ '''
8765
+
8766
+ def __init__(
8767
+ self,
8768
+ *,
8769
+ oauth_token: _SecretValue_3dd0ddae,
8770
+ output: _Artifact_0cb05964,
8771
+ owner: builtins.str,
8772
+ repo: builtins.str,
8773
+ branch: typing.Optional[builtins.str] = None,
8774
+ trigger: typing.Optional["GitHubTrigger"] = None,
8775
+ action_name: builtins.str,
8776
+ run_order: typing.Optional[jsii.Number] = None,
8777
+ variables_namespace: typing.Optional[builtins.str] = None,
8778
+ ) -> None:
8779
+ '''
8780
+ :param oauth_token: A GitHub OAuth token to use for authentication. It is recommended to use a Secrets Manager ``Secret`` to obtain the token: const oauth = cdk.SecretValue.secretsManager('my-github-token'); new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... }); If you rotate the value in the Secret, you must also change at least one property of the CodePipeline to force CloudFormation to re-read the secret. The GitHub Personal Access Token should have these scopes: - **repo** - to read the repository - **admin:repo_hook** - if you plan to use webhooks (true by default)
8781
+ :param output:
8782
+ :param owner: The GitHub account/user that owns the repo.
8783
+ :param repo: The name of the repo, without the username.
8784
+ :param branch: The branch to use. Default: "master"
8785
+ :param trigger: How AWS CodePipeline should be triggered. With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action With "POLL", CodePipeline periodically checks the source for changes With "None", the action is not triggered through changes in the source To use ``WEBHOOK``, your GitHub Personal Access Token should have **admin:repo_hook** scope (in addition to the regular **repo** scope). Default: GitHubTrigger.WEBHOOK
8786
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
8787
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
8788
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
8789
+ '''
8790
+ props = GitHubSourceActionProps(
8791
+ oauth_token=oauth_token,
8792
+ output=output,
8793
+ owner=owner,
8794
+ repo=repo,
8795
+ branch=branch,
8796
+ trigger=trigger,
8797
+ action_name=action_name,
8798
+ run_order=run_order,
8799
+ variables_namespace=variables_namespace,
8800
+ )
8801
+
8802
+ jsii.create(self.__class__, self, [props])
8803
+
8804
+ @jsii.member(jsii_name="bound")
8805
+ def _bound(
8806
+ self,
8807
+ scope: _constructs_77d1e7e8.Construct,
8808
+ stage: _IStage_415fc571,
8809
+ *,
8810
+ bucket: _IBucket_42e086fd,
8811
+ role: _IRole_235f5d8e,
8812
+ ) -> _ActionConfig_846fc217:
8813
+ '''This is a renamed version of the ``IAction.bind`` method.
8814
+
8815
+ :param scope: -
8816
+ :param stage: -
8817
+ :param bucket:
8818
+ :param role:
8819
+ '''
8820
+ if __debug__:
8821
+ type_hints = typing.get_type_hints(_typecheckingstub__0d8955359f0f5e27f55406175fafdd393ec53543baf2e52d8ee262c5b113fa80)
8822
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
8823
+ check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
8824
+ _options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
8825
+
8826
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, _options]))
8827
+
8828
+ @builtins.property
8829
+ @jsii.member(jsii_name="variables")
8830
+ def variables(self) -> "GitHubSourceVariables":
8831
+ '''The variables emitted by this action.'''
8832
+ return typing.cast("GitHubSourceVariables", jsii.get(self, "variables"))
8833
+
8834
+
8835
+ @jsii.data_type(
8836
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceActionProps",
8837
+ jsii_struct_bases=[_CommonActionProps_e3aaeecb],
8838
+ name_mapping={
8839
+ "action_name": "actionName",
8840
+ "run_order": "runOrder",
8841
+ "variables_namespace": "variablesNamespace",
8842
+ "oauth_token": "oauthToken",
8843
+ "output": "output",
8844
+ "owner": "owner",
8845
+ "repo": "repo",
8846
+ "branch": "branch",
8847
+ "trigger": "trigger",
8848
+ },
8849
+ )
8850
+ class GitHubSourceActionProps(_CommonActionProps_e3aaeecb):
8851
+ def __init__(
8852
+ self,
8853
+ *,
8854
+ action_name: builtins.str,
8855
+ run_order: typing.Optional[jsii.Number] = None,
8856
+ variables_namespace: typing.Optional[builtins.str] = None,
8857
+ oauth_token: _SecretValue_3dd0ddae,
8858
+ output: _Artifact_0cb05964,
8859
+ owner: builtins.str,
8860
+ repo: builtins.str,
8861
+ branch: typing.Optional[builtins.str] = None,
8862
+ trigger: typing.Optional["GitHubTrigger"] = None,
8863
+ ) -> None:
8864
+ '''Construction properties of the ``GitHubSourceAction GitHub source action``.
8865
+
8866
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
8867
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
8868
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
8869
+ :param oauth_token: A GitHub OAuth token to use for authentication. It is recommended to use a Secrets Manager ``Secret`` to obtain the token: const oauth = cdk.SecretValue.secretsManager('my-github-token'); new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... }); If you rotate the value in the Secret, you must also change at least one property of the CodePipeline to force CloudFormation to re-read the secret. The GitHub Personal Access Token should have these scopes: - **repo** - to read the repository - **admin:repo_hook** - if you plan to use webhooks (true by default)
8870
+ :param output:
8871
+ :param owner: The GitHub account/user that owns the repo.
8872
+ :param repo: The name of the repo, without the username.
8873
+ :param branch: The branch to use. Default: "master"
8874
+ :param trigger: How AWS CodePipeline should be triggered. With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action With "POLL", CodePipeline periodically checks the source for changes With "None", the action is not triggered through changes in the source To use ``WEBHOOK``, your GitHub Personal Access Token should have **admin:repo_hook** scope (in addition to the regular **repo** scope). Default: GitHubTrigger.WEBHOOK
8875
+
8876
+ :exampleMetadata: infused
8877
+
8878
+ Example::
8879
+
8880
+ # Read the secret from Secrets Manager
8881
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
8882
+ source_output = codepipeline.Artifact()
8883
+ source_action = codepipeline_actions.GitHubSourceAction(
8884
+ action_name="GitHub_Source",
8885
+ owner="awslabs",
8886
+ repo="aws-cdk",
8887
+ oauth_token=SecretValue.secrets_manager("my-github-token"),
8888
+ output=source_output,
8889
+ branch="develop"
8890
+ )
8891
+ pipeline.add_stage(
8892
+ stage_name="Source",
8893
+ actions=[source_action]
8894
+ )
8895
+ '''
8896
+ if __debug__:
8897
+ type_hints = typing.get_type_hints(_typecheckingstub__5b86a9f2777055875dffe46f70e2990f3cbd3a06cc388b84510ff390d7dac9fd)
8898
+ check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
8899
+ check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
8900
+ check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
8901
+ check_type(argname="argument oauth_token", value=oauth_token, expected_type=type_hints["oauth_token"])
8902
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
8903
+ check_type(argname="argument owner", value=owner, expected_type=type_hints["owner"])
8904
+ check_type(argname="argument repo", value=repo, expected_type=type_hints["repo"])
8905
+ check_type(argname="argument branch", value=branch, expected_type=type_hints["branch"])
8906
+ check_type(argname="argument trigger", value=trigger, expected_type=type_hints["trigger"])
8907
+ self._values: typing.Dict[builtins.str, typing.Any] = {
8908
+ "action_name": action_name,
8909
+ "oauth_token": oauth_token,
8910
+ "output": output,
8911
+ "owner": owner,
8912
+ "repo": repo,
8913
+ }
8914
+ if run_order is not None:
8915
+ self._values["run_order"] = run_order
8916
+ if variables_namespace is not None:
8917
+ self._values["variables_namespace"] = variables_namespace
8918
+ if branch is not None:
8919
+ self._values["branch"] = branch
8920
+ if trigger is not None:
8921
+ self._values["trigger"] = trigger
8922
+
8923
+ @builtins.property
8924
+ def action_name(self) -> builtins.str:
8925
+ '''The physical, human-readable name of the Action.
8926
+
8927
+ Note that Action names must be unique within a single Stage.
8928
+ '''
8929
+ result = self._values.get("action_name")
8930
+ assert result is not None, "Required property 'action_name' is missing"
8441
8931
  return typing.cast(builtins.str, result)
8442
8932
 
8443
8933
  @builtins.property
8444
- def repo(self) -> builtins.str:
8445
- '''The name of the repo, without the username.'''
8446
- result = self._values.get("repo")
8447
- assert result is not None, "Required property 'repo' is missing"
8934
+ def run_order(self) -> typing.Optional[jsii.Number]:
8935
+ '''The runOrder property for this Action.
8936
+
8937
+ RunOrder determines the relative order in which multiple Actions in the same Stage execute.
8938
+
8939
+ :default: 1
8940
+
8941
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html
8942
+ '''
8943
+ result = self._values.get("run_order")
8944
+ return typing.cast(typing.Optional[jsii.Number], result)
8945
+
8946
+ @builtins.property
8947
+ def variables_namespace(self) -> typing.Optional[builtins.str]:
8948
+ '''The name of the namespace to use for variables emitted by this action.
8949
+
8950
+ :default:
8951
+
8952
+ - a name will be generated, based on the stage and action names,
8953
+ if any of the action's variables were referenced - otherwise,
8954
+ no namespace will be set
8955
+ '''
8956
+ result = self._values.get("variables_namespace")
8957
+ return typing.cast(typing.Optional[builtins.str], result)
8958
+
8959
+ @builtins.property
8960
+ def oauth_token(self) -> _SecretValue_3dd0ddae:
8961
+ '''A GitHub OAuth token to use for authentication.
8962
+
8963
+ It is recommended to use a Secrets Manager ``Secret`` to obtain the token:
8964
+
8965
+ const oauth = cdk.SecretValue.secretsManager('my-github-token');
8966
+ new GitHubSourceAction(this, 'GitHubAction', { oauthToken: oauth, ... });
8967
+
8968
+ If you rotate the value in the Secret, you must also change at least one property
8969
+ of the CodePipeline to force CloudFormation to re-read the secret.
8970
+
8971
+ The GitHub Personal Access Token should have these scopes:
8972
+
8973
+ - **repo** - to read the repository
8974
+ - **admin:repo_hook** - if you plan to use webhooks (true by default)
8975
+
8976
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/appendix-github-oauth.html#GitHub-create-personal-token-CLI
8977
+ '''
8978
+ result = self._values.get("oauth_token")
8979
+ assert result is not None, "Required property 'oauth_token' is missing"
8980
+ return typing.cast(_SecretValue_3dd0ddae, result)
8981
+
8982
+ @builtins.property
8983
+ def output(self) -> _Artifact_0cb05964:
8984
+ result = self._values.get("output")
8985
+ assert result is not None, "Required property 'output' is missing"
8986
+ return typing.cast(_Artifact_0cb05964, result)
8987
+
8988
+ @builtins.property
8989
+ def owner(self) -> builtins.str:
8990
+ '''The GitHub account/user that owns the repo.'''
8991
+ result = self._values.get("owner")
8992
+ assert result is not None, "Required property 'owner' is missing"
8993
+ return typing.cast(builtins.str, result)
8994
+
8995
+ @builtins.property
8996
+ def repo(self) -> builtins.str:
8997
+ '''The name of the repo, without the username.'''
8998
+ result = self._values.get("repo")
8999
+ assert result is not None, "Required property 'repo' is missing"
9000
+ return typing.cast(builtins.str, result)
9001
+
9002
+ @builtins.property
9003
+ def branch(self) -> typing.Optional[builtins.str]:
9004
+ '''The branch to use.
9005
+
9006
+ :default: "master"
9007
+ '''
9008
+ result = self._values.get("branch")
9009
+ return typing.cast(typing.Optional[builtins.str], result)
9010
+
9011
+ @builtins.property
9012
+ def trigger(self) -> typing.Optional["GitHubTrigger"]:
9013
+ '''How AWS CodePipeline should be triggered.
9014
+
9015
+ With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action
9016
+ With "POLL", CodePipeline periodically checks the source for changes
9017
+ With "None", the action is not triggered through changes in the source
9018
+
9019
+ To use ``WEBHOOK``, your GitHub Personal Access Token should have
9020
+ **admin:repo_hook** scope (in addition to the regular **repo** scope).
9021
+
9022
+ :default: GitHubTrigger.WEBHOOK
9023
+ '''
9024
+ result = self._values.get("trigger")
9025
+ return typing.cast(typing.Optional["GitHubTrigger"], result)
9026
+
9027
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
9028
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
9029
+
9030
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
9031
+ return not (rhs == self)
9032
+
9033
+ def __repr__(self) -> str:
9034
+ return "GitHubSourceActionProps(%s)" % ", ".join(
9035
+ k + "=" + repr(v) for k, v in self._values.items()
9036
+ )
9037
+
9038
+
9039
+ @jsii.data_type(
9040
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceVariables",
9041
+ jsii_struct_bases=[],
9042
+ name_mapping={
9043
+ "author_date": "authorDate",
9044
+ "branch_name": "branchName",
9045
+ "commit_id": "commitId",
9046
+ "commit_message": "commitMessage",
9047
+ "committer_date": "committerDate",
9048
+ "commit_url": "commitUrl",
9049
+ "repository_name": "repositoryName",
9050
+ },
9051
+ )
9052
+ class GitHubSourceVariables:
9053
+ def __init__(
9054
+ self,
9055
+ *,
9056
+ author_date: builtins.str,
9057
+ branch_name: builtins.str,
9058
+ commit_id: builtins.str,
9059
+ commit_message: builtins.str,
9060
+ committer_date: builtins.str,
9061
+ commit_url: builtins.str,
9062
+ repository_name: builtins.str,
9063
+ ) -> None:
9064
+ '''The CodePipeline variables emitted by GitHub source Action.
9065
+
9066
+ :param author_date: The date the currently last commit on the tracked branch was authored, in ISO-8601 format.
9067
+ :param branch_name: The name of the branch this action tracks.
9068
+ :param commit_id: The SHA1 hash of the currently last commit on the tracked branch.
9069
+ :param commit_message: The message of the currently last commit on the tracked branch.
9070
+ :param committer_date: The date the currently last commit on the tracked branch was committed, in ISO-8601 format.
9071
+ :param commit_url: The GitHub API URL of the currently last commit on the tracked branch.
9072
+ :param repository_name: The name of the repository this action points to.
9073
+
9074
+ :exampleMetadata: fixture=_generated
9075
+
9076
+ Example::
9077
+
9078
+ # The code below shows an example of how to instantiate this type.
9079
+ # The values are placeholders you should change.
9080
+ from aws_cdk import aws_codepipeline_actions as codepipeline_actions
9081
+
9082
+ git_hub_source_variables = codepipeline_actions.GitHubSourceVariables(
9083
+ author_date="authorDate",
9084
+ branch_name="branchName",
9085
+ commit_id="commitId",
9086
+ commit_message="commitMessage",
9087
+ committer_date="committerDate",
9088
+ commit_url="commitUrl",
9089
+ repository_name="repositoryName"
9090
+ )
9091
+ '''
9092
+ if __debug__:
9093
+ type_hints = typing.get_type_hints(_typecheckingstub__d36a66e26e764b2c204da0bcf323302f95847c475cba80cedc642606a76204a8)
9094
+ check_type(argname="argument author_date", value=author_date, expected_type=type_hints["author_date"])
9095
+ check_type(argname="argument branch_name", value=branch_name, expected_type=type_hints["branch_name"])
9096
+ check_type(argname="argument commit_id", value=commit_id, expected_type=type_hints["commit_id"])
9097
+ check_type(argname="argument commit_message", value=commit_message, expected_type=type_hints["commit_message"])
9098
+ check_type(argname="argument committer_date", value=committer_date, expected_type=type_hints["committer_date"])
9099
+ check_type(argname="argument commit_url", value=commit_url, expected_type=type_hints["commit_url"])
9100
+ check_type(argname="argument repository_name", value=repository_name, expected_type=type_hints["repository_name"])
9101
+ self._values: typing.Dict[builtins.str, typing.Any] = {
9102
+ "author_date": author_date,
9103
+ "branch_name": branch_name,
9104
+ "commit_id": commit_id,
9105
+ "commit_message": commit_message,
9106
+ "committer_date": committer_date,
9107
+ "commit_url": commit_url,
9108
+ "repository_name": repository_name,
9109
+ }
9110
+
9111
+ @builtins.property
9112
+ def author_date(self) -> builtins.str:
9113
+ '''The date the currently last commit on the tracked branch was authored, in ISO-8601 format.'''
9114
+ result = self._values.get("author_date")
9115
+ assert result is not None, "Required property 'author_date' is missing"
9116
+ return typing.cast(builtins.str, result)
9117
+
9118
+ @builtins.property
9119
+ def branch_name(self) -> builtins.str:
9120
+ '''The name of the branch this action tracks.'''
9121
+ result = self._values.get("branch_name")
9122
+ assert result is not None, "Required property 'branch_name' is missing"
9123
+ return typing.cast(builtins.str, result)
9124
+
9125
+ @builtins.property
9126
+ def commit_id(self) -> builtins.str:
9127
+ '''The SHA1 hash of the currently last commit on the tracked branch.'''
9128
+ result = self._values.get("commit_id")
9129
+ assert result is not None, "Required property 'commit_id' is missing"
9130
+ return typing.cast(builtins.str, result)
9131
+
9132
+ @builtins.property
9133
+ def commit_message(self) -> builtins.str:
9134
+ '''The message of the currently last commit on the tracked branch.'''
9135
+ result = self._values.get("commit_message")
9136
+ assert result is not None, "Required property 'commit_message' is missing"
9137
+ return typing.cast(builtins.str, result)
9138
+
9139
+ @builtins.property
9140
+ def committer_date(self) -> builtins.str:
9141
+ '''The date the currently last commit on the tracked branch was committed, in ISO-8601 format.'''
9142
+ result = self._values.get("committer_date")
9143
+ assert result is not None, "Required property 'committer_date' is missing"
9144
+ return typing.cast(builtins.str, result)
9145
+
9146
+ @builtins.property
9147
+ def commit_url(self) -> builtins.str:
9148
+ '''The GitHub API URL of the currently last commit on the tracked branch.'''
9149
+ result = self._values.get("commit_url")
9150
+ assert result is not None, "Required property 'commit_url' is missing"
9151
+ return typing.cast(builtins.str, result)
9152
+
9153
+ @builtins.property
9154
+ def repository_name(self) -> builtins.str:
9155
+ '''The name of the repository this action points to.'''
9156
+ result = self._values.get("repository_name")
9157
+ assert result is not None, "Required property 'repository_name' is missing"
9158
+ return typing.cast(builtins.str, result)
9159
+
9160
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
9161
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
9162
+
9163
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
9164
+ return not (rhs == self)
9165
+
9166
+ def __repr__(self) -> str:
9167
+ return "GitHubSourceVariables(%s)" % ", ".join(
9168
+ k + "=" + repr(v) for k, v in self._values.items()
9169
+ )
9170
+
9171
+
9172
+ @jsii.enum(jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubTrigger")
9173
+ class GitHubTrigger(enum.Enum):
9174
+ '''If and how the GitHub source action should be triggered.'''
9175
+
9176
+ NONE = "NONE"
9177
+ POLL = "POLL"
9178
+ WEBHOOK = "WEBHOOK"
9179
+
9180
+
9181
+ @jsii.interface(jsii_type="aws-cdk-lib.aws_codepipeline_actions.ICustomEventRule")
9182
+ class ICustomEventRule(typing_extensions.Protocol):
9183
+ '''Represents a custom event rule in AWS CodePipeline Actions.
9184
+
9185
+ This interface defines the structure for specifying a custom event rule
9186
+ in the AWS CodePipeline Actions module. The event rule is defined by an
9187
+ event pattern and a target.
9188
+
9189
+ :see: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events_targets-readme.html
9190
+ '''
9191
+
9192
+ @builtins.property
9193
+ @jsii.member(jsii_name="eventPattern")
9194
+ def event_pattern(self) -> _EventPattern_fe557901:
9195
+ '''event pattern when this rule should be triggered.'''
9196
+ ...
9197
+
9198
+ @builtins.property
9199
+ @jsii.member(jsii_name="target")
9200
+ def target(self) -> _IRuleTarget_7a91f454:
9201
+ '''Target e.g. Lambda when event pattern is fulfilled.'''
9202
+ ...
9203
+
9204
+ @builtins.property
9205
+ @jsii.member(jsii_name="description")
9206
+ def description(self) -> typing.Optional[builtins.str]:
9207
+ '''Description.'''
9208
+ ...
9209
+
9210
+ @builtins.property
9211
+ @jsii.member(jsii_name="ruleName")
9212
+ def rule_name(self) -> typing.Optional[builtins.str]:
9213
+ '''Rulename.'''
9214
+ ...
9215
+
9216
+
9217
+ class _ICustomEventRuleProxy:
9218
+ '''Represents a custom event rule in AWS CodePipeline Actions.
9219
+
9220
+ This interface defines the structure for specifying a custom event rule
9221
+ in the AWS CodePipeline Actions module. The event rule is defined by an
9222
+ event pattern and a target.
9223
+
9224
+ :see: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events_targets-readme.html
9225
+ '''
9226
+
9227
+ __jsii_type__: typing.ClassVar[str] = "aws-cdk-lib.aws_codepipeline_actions.ICustomEventRule"
9228
+
9229
+ @builtins.property
9230
+ @jsii.member(jsii_name="eventPattern")
9231
+ def event_pattern(self) -> _EventPattern_fe557901:
9232
+ '''event pattern when this rule should be triggered.'''
9233
+ return typing.cast(_EventPattern_fe557901, jsii.get(self, "eventPattern"))
9234
+
9235
+ @builtins.property
9236
+ @jsii.member(jsii_name="target")
9237
+ def target(self) -> _IRuleTarget_7a91f454:
9238
+ '''Target e.g. Lambda when event pattern is fulfilled.'''
9239
+ return typing.cast(_IRuleTarget_7a91f454, jsii.get(self, "target"))
9240
+
9241
+ @builtins.property
9242
+ @jsii.member(jsii_name="description")
9243
+ def description(self) -> typing.Optional[builtins.str]:
9244
+ '''Description.'''
9245
+ return typing.cast(typing.Optional[builtins.str], jsii.get(self, "description"))
9246
+
9247
+ @builtins.property
9248
+ @jsii.member(jsii_name="ruleName")
9249
+ def rule_name(self) -> typing.Optional[builtins.str]:
9250
+ '''Rulename.'''
9251
+ return typing.cast(typing.Optional[builtins.str], jsii.get(self, "ruleName"))
9252
+
9253
+ # Adding a "__jsii_proxy_class__(): typing.Type" function to the interface
9254
+ typing.cast(typing.Any, ICustomEventRule).__jsii_proxy_class__ = lambda : _ICustomEventRuleProxy
9255
+
9256
+
9257
+ @jsii.interface(jsii_type="aws-cdk-lib.aws_codepipeline_actions.IJenkinsProvider")
9258
+ class IJenkinsProvider(_constructs_77d1e7e8.IConstruct, typing_extensions.Protocol):
9259
+ '''A Jenkins provider.
9260
+
9261
+ If you want to create a new Jenkins provider managed alongside your CDK code,
9262
+ instantiate the ``JenkinsProvider`` class directly.
9263
+
9264
+ If you want to reference an already registered provider,
9265
+ use the ``JenkinsProvider#fromJenkinsProviderAttributes`` method.
9266
+ '''
9267
+
9268
+ @builtins.property
9269
+ @jsii.member(jsii_name="providerName")
9270
+ def provider_name(self) -> builtins.str:
9271
+ ...
9272
+
9273
+ @builtins.property
9274
+ @jsii.member(jsii_name="serverUrl")
9275
+ def server_url(self) -> builtins.str:
9276
+ ...
9277
+
9278
+ @builtins.property
9279
+ @jsii.member(jsii_name="version")
9280
+ def version(self) -> builtins.str:
9281
+ ...
9282
+
9283
+
9284
+ class _IJenkinsProviderProxy(
9285
+ jsii.proxy_for(_constructs_77d1e7e8.IConstruct), # type: ignore[misc]
9286
+ ):
9287
+ '''A Jenkins provider.
9288
+
9289
+ If you want to create a new Jenkins provider managed alongside your CDK code,
9290
+ instantiate the ``JenkinsProvider`` class directly.
9291
+
9292
+ If you want to reference an already registered provider,
9293
+ use the ``JenkinsProvider#fromJenkinsProviderAttributes`` method.
9294
+ '''
9295
+
9296
+ __jsii_type__: typing.ClassVar[str] = "aws-cdk-lib.aws_codepipeline_actions.IJenkinsProvider"
9297
+
9298
+ @builtins.property
9299
+ @jsii.member(jsii_name="providerName")
9300
+ def provider_name(self) -> builtins.str:
9301
+ return typing.cast(builtins.str, jsii.get(self, "providerName"))
9302
+
9303
+ @builtins.property
9304
+ @jsii.member(jsii_name="serverUrl")
9305
+ def server_url(self) -> builtins.str:
9306
+ return typing.cast(builtins.str, jsii.get(self, "serverUrl"))
9307
+
9308
+ @builtins.property
9309
+ @jsii.member(jsii_name="version")
9310
+ def version(self) -> builtins.str:
9311
+ return typing.cast(builtins.str, jsii.get(self, "version"))
9312
+
9313
+ # Adding a "__jsii_proxy_class__(): typing.Type" function to the interface
9314
+ typing.cast(typing.Any, IJenkinsProvider).__jsii_proxy_class__ = lambda : _IJenkinsProviderProxy
9315
+
9316
+
9317
+ class InspectorScanActionBase(
9318
+ Action,
9319
+ metaclass=jsii.JSIIAbstractClass,
9320
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorScanActionBase",
9321
+ ):
9322
+ '''CodePipeline invoke action that uses AWS InspectorScan.'''
9323
+
9324
+ def __init__(
9325
+ self,
9326
+ *,
9327
+ output: _Artifact_0cb05964,
9328
+ critical_threshold: typing.Optional[jsii.Number] = None,
9329
+ high_threshold: typing.Optional[jsii.Number] = None,
9330
+ low_threshold: typing.Optional[jsii.Number] = None,
9331
+ medium_threshold: typing.Optional[jsii.Number] = None,
9332
+ role: typing.Optional[_IRole_235f5d8e] = None,
9333
+ action_name: builtins.str,
9334
+ run_order: typing.Optional[jsii.Number] = None,
9335
+ variables_namespace: typing.Optional[builtins.str] = None,
9336
+ ) -> None:
9337
+ '''
9338
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
9339
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9340
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9341
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9342
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9343
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
9344
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
9345
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
9346
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
9347
+ '''
9348
+ props = InspectorScanActionBaseProps(
9349
+ output=output,
9350
+ critical_threshold=critical_threshold,
9351
+ high_threshold=high_threshold,
9352
+ low_threshold=low_threshold,
9353
+ medium_threshold=medium_threshold,
9354
+ role=role,
9355
+ action_name=action_name,
9356
+ run_order=run_order,
9357
+ variables_namespace=variables_namespace,
9358
+ )
9359
+
9360
+ jsii.create(self.__class__, self, [props])
9361
+
9362
+ @jsii.member(jsii_name="bound")
9363
+ def _bound(
9364
+ self,
9365
+ scope: _constructs_77d1e7e8.Construct,
9366
+ stage: _IStage_415fc571,
9367
+ *,
9368
+ bucket: _IBucket_42e086fd,
9369
+ role: _IRole_235f5d8e,
9370
+ ) -> _ActionConfig_846fc217:
9371
+ '''This is a renamed version of the ``IAction.bind`` method.
9372
+
9373
+ :param scope: -
9374
+ :param stage: -
9375
+ :param bucket:
9376
+ :param role:
9377
+ '''
9378
+ if __debug__:
9379
+ type_hints = typing.get_type_hints(_typecheckingstub__e14024ba1588c13bad01352500e04cd20ed7cde863ea927e167b0fbe92c82ecd)
9380
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
9381
+ check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
9382
+ options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
9383
+
9384
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, options]))
9385
+
9386
+ @jsii.member(jsii_name="renderActionConfiguration")
9387
+ @abc.abstractmethod
9388
+ def _render_action_configuration(self) -> typing.Mapping[builtins.str, typing.Any]:
9389
+ ...
9390
+
9391
+ @builtins.property
9392
+ @jsii.member(jsii_name="props")
9393
+ def _props(self) -> "InspectorScanActionBaseProps":
9394
+ return typing.cast("InspectorScanActionBaseProps", jsii.get(self, "props"))
9395
+
9396
+ @builtins.property
9397
+ @jsii.member(jsii_name="variables")
9398
+ def variables(self) -> "InspectorScanVariables":
9399
+ '''The variables emitted by this action.'''
9400
+ return typing.cast("InspectorScanVariables", jsii.get(self, "variables"))
9401
+
9402
+
9403
+ class _InspectorScanActionBaseProxy(
9404
+ InspectorScanActionBase,
9405
+ jsii.proxy_for(Action), # type: ignore[misc]
9406
+ ):
9407
+ @jsii.member(jsii_name="renderActionConfiguration")
9408
+ def _render_action_configuration(self) -> typing.Mapping[builtins.str, typing.Any]:
9409
+ return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderActionConfiguration", []))
9410
+
9411
+ # Adding a "__jsii_proxy_class__(): typing.Type" function to the abstract class
9412
+ typing.cast(typing.Any, InspectorScanActionBase).__jsii_proxy_class__ = lambda : _InspectorScanActionBaseProxy
9413
+
9414
+
9415
+ @jsii.data_type(
9416
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorScanActionBaseProps",
9417
+ jsii_struct_bases=[_CommonAwsActionProps_8b809bb6],
9418
+ name_mapping={
9419
+ "action_name": "actionName",
9420
+ "run_order": "runOrder",
9421
+ "variables_namespace": "variablesNamespace",
9422
+ "role": "role",
9423
+ "output": "output",
9424
+ "critical_threshold": "criticalThreshold",
9425
+ "high_threshold": "highThreshold",
9426
+ "low_threshold": "lowThreshold",
9427
+ "medium_threshold": "mediumThreshold",
9428
+ },
9429
+ )
9430
+ class InspectorScanActionBaseProps(_CommonAwsActionProps_8b809bb6):
9431
+ def __init__(
9432
+ self,
9433
+ *,
9434
+ action_name: builtins.str,
9435
+ run_order: typing.Optional[jsii.Number] = None,
9436
+ variables_namespace: typing.Optional[builtins.str] = None,
9437
+ role: typing.Optional[_IRole_235f5d8e] = None,
9438
+ output: _Artifact_0cb05964,
9439
+ critical_threshold: typing.Optional[jsii.Number] = None,
9440
+ high_threshold: typing.Optional[jsii.Number] = None,
9441
+ low_threshold: typing.Optional[jsii.Number] = None,
9442
+ medium_threshold: typing.Optional[jsii.Number] = None,
9443
+ ) -> None:
9444
+ '''Base construction properties of the ``InspectorScanActionBase``.
9445
+
9446
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
9447
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
9448
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
9449
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
9450
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
9451
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9452
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9453
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9454
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9455
+
9456
+ :exampleMetadata: fixture=_generated
9457
+
9458
+ Example::
9459
+
9460
+ # The code below shows an example of how to instantiate this type.
9461
+ # The values are placeholders you should change.
9462
+ from aws_cdk import aws_codepipeline as codepipeline
9463
+ from aws_cdk import aws_codepipeline_actions as codepipeline_actions
9464
+ from aws_cdk import aws_iam as iam
9465
+
9466
+ # artifact: codepipeline.Artifact
9467
+ # role: iam.Role
9468
+
9469
+ inspector_scan_action_base_props = codepipeline_actions.InspectorScanActionBaseProps(
9470
+ action_name="actionName",
9471
+ output=artifact,
9472
+
9473
+ # the properties below are optional
9474
+ critical_threshold=123,
9475
+ high_threshold=123,
9476
+ low_threshold=123,
9477
+ medium_threshold=123,
9478
+ role=role,
9479
+ run_order=123,
9480
+ variables_namespace="variablesNamespace"
9481
+ )
9482
+ '''
9483
+ if __debug__:
9484
+ type_hints = typing.get_type_hints(_typecheckingstub__6da783895b7ba6899d69141e306683f07acbbde47f1425f850879dc762f2e644)
9485
+ check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
9486
+ check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
9487
+ check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
9488
+ check_type(argname="argument role", value=role, expected_type=type_hints["role"])
9489
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
9490
+ check_type(argname="argument critical_threshold", value=critical_threshold, expected_type=type_hints["critical_threshold"])
9491
+ check_type(argname="argument high_threshold", value=high_threshold, expected_type=type_hints["high_threshold"])
9492
+ check_type(argname="argument low_threshold", value=low_threshold, expected_type=type_hints["low_threshold"])
9493
+ check_type(argname="argument medium_threshold", value=medium_threshold, expected_type=type_hints["medium_threshold"])
9494
+ self._values: typing.Dict[builtins.str, typing.Any] = {
9495
+ "action_name": action_name,
9496
+ "output": output,
9497
+ }
9498
+ if run_order is not None:
9499
+ self._values["run_order"] = run_order
9500
+ if variables_namespace is not None:
9501
+ self._values["variables_namespace"] = variables_namespace
9502
+ if role is not None:
9503
+ self._values["role"] = role
9504
+ if critical_threshold is not None:
9505
+ self._values["critical_threshold"] = critical_threshold
9506
+ if high_threshold is not None:
9507
+ self._values["high_threshold"] = high_threshold
9508
+ if low_threshold is not None:
9509
+ self._values["low_threshold"] = low_threshold
9510
+ if medium_threshold is not None:
9511
+ self._values["medium_threshold"] = medium_threshold
9512
+
9513
+ @builtins.property
9514
+ def action_name(self) -> builtins.str:
9515
+ '''The physical, human-readable name of the Action.
9516
+
9517
+ Note that Action names must be unique within a single Stage.
9518
+ '''
9519
+ result = self._values.get("action_name")
9520
+ assert result is not None, "Required property 'action_name' is missing"
8448
9521
  return typing.cast(builtins.str, result)
8449
9522
 
8450
9523
  @builtins.property
8451
- def branch(self) -> typing.Optional[builtins.str]:
8452
- '''The branch to use.
9524
+ def run_order(self) -> typing.Optional[jsii.Number]:
9525
+ '''The runOrder property for this Action.
8453
9526
 
8454
- :default: "master"
9527
+ RunOrder determines the relative order in which multiple Actions in the same Stage execute.
9528
+
9529
+ :default: 1
9530
+
9531
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html
8455
9532
  '''
8456
- result = self._values.get("branch")
9533
+ result = self._values.get("run_order")
9534
+ return typing.cast(typing.Optional[jsii.Number], result)
9535
+
9536
+ @builtins.property
9537
+ def variables_namespace(self) -> typing.Optional[builtins.str]:
9538
+ '''The name of the namespace to use for variables emitted by this action.
9539
+
9540
+ :default:
9541
+
9542
+ - a name will be generated, based on the stage and action names,
9543
+ if any of the action's variables were referenced - otherwise,
9544
+ no namespace will be set
9545
+ '''
9546
+ result = self._values.get("variables_namespace")
8457
9547
  return typing.cast(typing.Optional[builtins.str], result)
8458
9548
 
8459
9549
  @builtins.property
8460
- def trigger(self) -> typing.Optional["GitHubTrigger"]:
8461
- '''How AWS CodePipeline should be triggered.
9550
+ def role(self) -> typing.Optional[_IRole_235f5d8e]:
9551
+ '''The Role in which context's this Action will be executing in.
8462
9552
 
8463
- With the default value "WEBHOOK", a webhook is created in GitHub that triggers the action
8464
- With "POLL", CodePipeline periodically checks the source for changes
8465
- With "None", the action is not triggered through changes in the source
9553
+ The Pipeline's Role will assume this Role
9554
+ (the required permissions for that will be granted automatically)
9555
+ right before executing this Action.
9556
+ This Action will be passed into your ``IAction.bind``
9557
+ method in the ``ActionBindOptions.role`` property.
8466
9558
 
8467
- To use ``WEBHOOK``, your GitHub Personal Access Token should have
8468
- **admin:repo_hook** scope (in addition to the regular **repo** scope).
9559
+ :default: a new Role will be generated
9560
+ '''
9561
+ result = self._values.get("role")
9562
+ return typing.cast(typing.Optional[_IRole_235f5d8e], result)
8469
9563
 
8470
- :default: GitHubTrigger.WEBHOOK
9564
+ @builtins.property
9565
+ def output(self) -> _Artifact_0cb05964:
9566
+ '''Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.'''
9567
+ result = self._values.get("output")
9568
+ assert result is not None, "Required property 'output' is missing"
9569
+ return typing.cast(_Artifact_0cb05964, result)
9570
+
9571
+ @builtins.property
9572
+ def critical_threshold(self) -> typing.Optional[jsii.Number]:
9573
+ '''The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
9574
+
9575
+ :default: - no threshold
8471
9576
  '''
8472
- result = self._values.get("trigger")
8473
- return typing.cast(typing.Optional["GitHubTrigger"], result)
9577
+ result = self._values.get("critical_threshold")
9578
+ return typing.cast(typing.Optional[jsii.Number], result)
9579
+
9580
+ @builtins.property
9581
+ def high_threshold(self) -> typing.Optional[jsii.Number]:
9582
+ '''The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
9583
+
9584
+ :default: - no threshold
9585
+ '''
9586
+ result = self._values.get("high_threshold")
9587
+ return typing.cast(typing.Optional[jsii.Number], result)
9588
+
9589
+ @builtins.property
9590
+ def low_threshold(self) -> typing.Optional[jsii.Number]:
9591
+ '''The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
9592
+
9593
+ :default: - no threshold
9594
+ '''
9595
+ result = self._values.get("low_threshold")
9596
+ return typing.cast(typing.Optional[jsii.Number], result)
9597
+
9598
+ @builtins.property
9599
+ def medium_threshold(self) -> typing.Optional[jsii.Number]:
9600
+ '''The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
9601
+
9602
+ :default: - no threshold
9603
+ '''
9604
+ result = self._values.get("medium_threshold")
9605
+ return typing.cast(typing.Optional[jsii.Number], result)
8474
9606
 
8475
9607
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
8476
9608
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -8479,45 +9611,21 @@ class GitHubSourceActionProps(_CommonActionProps_e3aaeecb):
8479
9611
  return not (rhs == self)
8480
9612
 
8481
9613
  def __repr__(self) -> str:
8482
- return "GitHubSourceActionProps(%s)" % ", ".join(
9614
+ return "InspectorScanActionBaseProps(%s)" % ", ".join(
8483
9615
  k + "=" + repr(v) for k, v in self._values.items()
8484
9616
  )
8485
9617
 
8486
9618
 
8487
9619
  @jsii.data_type(
8488
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubSourceVariables",
9620
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorScanVariables",
8489
9621
  jsii_struct_bases=[],
8490
- name_mapping={
8491
- "author_date": "authorDate",
8492
- "branch_name": "branchName",
8493
- "commit_id": "commitId",
8494
- "commit_message": "commitMessage",
8495
- "committer_date": "committerDate",
8496
- "commit_url": "commitUrl",
8497
- "repository_name": "repositoryName",
8498
- },
9622
+ name_mapping={"highest_scanned_severity": "highestScannedSeverity"},
8499
9623
  )
8500
- class GitHubSourceVariables:
8501
- def __init__(
8502
- self,
8503
- *,
8504
- author_date: builtins.str,
8505
- branch_name: builtins.str,
8506
- commit_id: builtins.str,
8507
- commit_message: builtins.str,
8508
- committer_date: builtins.str,
8509
- commit_url: builtins.str,
8510
- repository_name: builtins.str,
8511
- ) -> None:
8512
- '''The CodePipeline variables emitted by GitHub source Action.
9624
+ class InspectorScanVariables:
9625
+ def __init__(self, *, highest_scanned_severity: builtins.str) -> None:
9626
+ '''The CodePipeline variables emitted by the InspectorScan Action.
8513
9627
 
8514
- :param author_date: The date the currently last commit on the tracked branch was authored, in ISO-8601 format.
8515
- :param branch_name: The name of the branch this action tracks.
8516
- :param commit_id: The SHA1 hash of the currently last commit on the tracked branch.
8517
- :param commit_message: The message of the currently last commit on the tracked branch.
8518
- :param committer_date: The date the currently last commit on the tracked branch was committed, in ISO-8601 format.
8519
- :param commit_url: The GitHub API URL of the currently last commit on the tracked branch.
8520
- :param repository_name: The name of the repository this action points to.
9628
+ :param highest_scanned_severity: The highest severity output from the scan. Valid values are medium | high | critical.
8521
9629
 
8522
9630
  :exampleMetadata: fixture=_generated
8523
9631
 
@@ -8527,82 +9635,25 @@ class GitHubSourceVariables:
8527
9635
  # The values are placeholders you should change.
8528
9636
  from aws_cdk import aws_codepipeline_actions as codepipeline_actions
8529
9637
 
8530
- git_hub_source_variables = codepipeline_actions.GitHubSourceVariables(
8531
- author_date="authorDate",
8532
- branch_name="branchName",
8533
- commit_id="commitId",
8534
- commit_message="commitMessage",
8535
- committer_date="committerDate",
8536
- commit_url="commitUrl",
8537
- repository_name="repositoryName"
9638
+ inspector_scan_variables = codepipeline_actions.InspectorScanVariables(
9639
+ highest_scanned_severity="highestScannedSeverity"
8538
9640
  )
8539
9641
  '''
8540
9642
  if __debug__:
8541
- type_hints = typing.get_type_hints(_typecheckingstub__d36a66e26e764b2c204da0bcf323302f95847c475cba80cedc642606a76204a8)
8542
- check_type(argname="argument author_date", value=author_date, expected_type=type_hints["author_date"])
8543
- check_type(argname="argument branch_name", value=branch_name, expected_type=type_hints["branch_name"])
8544
- check_type(argname="argument commit_id", value=commit_id, expected_type=type_hints["commit_id"])
8545
- check_type(argname="argument commit_message", value=commit_message, expected_type=type_hints["commit_message"])
8546
- check_type(argname="argument committer_date", value=committer_date, expected_type=type_hints["committer_date"])
8547
- check_type(argname="argument commit_url", value=commit_url, expected_type=type_hints["commit_url"])
8548
- check_type(argname="argument repository_name", value=repository_name, expected_type=type_hints["repository_name"])
9643
+ type_hints = typing.get_type_hints(_typecheckingstub__8a48c3b3b3e2cfc1dcf7a2e04c2e32728ebe17a3f38a9cad1bada36d22fe6a24)
9644
+ check_type(argname="argument highest_scanned_severity", value=highest_scanned_severity, expected_type=type_hints["highest_scanned_severity"])
8549
9645
  self._values: typing.Dict[builtins.str, typing.Any] = {
8550
- "author_date": author_date,
8551
- "branch_name": branch_name,
8552
- "commit_id": commit_id,
8553
- "commit_message": commit_message,
8554
- "committer_date": committer_date,
8555
- "commit_url": commit_url,
8556
- "repository_name": repository_name,
9646
+ "highest_scanned_severity": highest_scanned_severity,
8557
9647
  }
8558
9648
 
8559
9649
  @builtins.property
8560
- def author_date(self) -> builtins.str:
8561
- '''The date the currently last commit on the tracked branch was authored, in ISO-8601 format.'''
8562
- result = self._values.get("author_date")
8563
- assert result is not None, "Required property 'author_date' is missing"
8564
- return typing.cast(builtins.str, result)
8565
-
8566
- @builtins.property
8567
- def branch_name(self) -> builtins.str:
8568
- '''The name of the branch this action tracks.'''
8569
- result = self._values.get("branch_name")
8570
- assert result is not None, "Required property 'branch_name' is missing"
8571
- return typing.cast(builtins.str, result)
8572
-
8573
- @builtins.property
8574
- def commit_id(self) -> builtins.str:
8575
- '''The SHA1 hash of the currently last commit on the tracked branch.'''
8576
- result = self._values.get("commit_id")
8577
- assert result is not None, "Required property 'commit_id' is missing"
8578
- return typing.cast(builtins.str, result)
8579
-
8580
- @builtins.property
8581
- def commit_message(self) -> builtins.str:
8582
- '''The message of the currently last commit on the tracked branch.'''
8583
- result = self._values.get("commit_message")
8584
- assert result is not None, "Required property 'commit_message' is missing"
8585
- return typing.cast(builtins.str, result)
8586
-
8587
- @builtins.property
8588
- def committer_date(self) -> builtins.str:
8589
- '''The date the currently last commit on the tracked branch was committed, in ISO-8601 format.'''
8590
- result = self._values.get("committer_date")
8591
- assert result is not None, "Required property 'committer_date' is missing"
8592
- return typing.cast(builtins.str, result)
8593
-
8594
- @builtins.property
8595
- def commit_url(self) -> builtins.str:
8596
- '''The GitHub API URL of the currently last commit on the tracked branch.'''
8597
- result = self._values.get("commit_url")
8598
- assert result is not None, "Required property 'commit_url' is missing"
8599
- return typing.cast(builtins.str, result)
9650
+ def highest_scanned_severity(self) -> builtins.str:
9651
+ '''The highest severity output from the scan.
8600
9652
 
8601
- @builtins.property
8602
- def repository_name(self) -> builtins.str:
8603
- '''The name of the repository this action points to.'''
8604
- result = self._values.get("repository_name")
8605
- assert result is not None, "Required property 'repository_name' is missing"
9653
+ Valid values are medium | high | critical.
9654
+ '''
9655
+ result = self._values.get("highest_scanned_severity")
9656
+ assert result is not None, "Required property 'highest_scanned_severity' is missing"
8606
9657
  return typing.cast(builtins.str, result)
8607
9658
 
8608
9659
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
@@ -8612,154 +9663,340 @@ class GitHubSourceVariables:
8612
9663
  return not (rhs == self)
8613
9664
 
8614
9665
  def __repr__(self) -> str:
8615
- return "GitHubSourceVariables(%s)" % ", ".join(
9666
+ return "InspectorScanVariables(%s)" % ", ".join(
8616
9667
  k + "=" + repr(v) for k, v in self._values.items()
8617
9668
  )
8618
9669
 
8619
9670
 
8620
- @jsii.enum(jsii_type="aws-cdk-lib.aws_codepipeline_actions.GitHubTrigger")
8621
- class GitHubTrigger(enum.Enum):
8622
- '''If and how the GitHub source action should be triggered.'''
9671
+ class InspectorSourceCodeScanAction(
9672
+ InspectorScanActionBase,
9673
+ metaclass=jsii.JSIIMeta,
9674
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorSourceCodeScanAction",
9675
+ ):
9676
+ '''CodePipeline invoke action that uses AWS InspectorScan for source code.
9677
+
9678
+ :exampleMetadata: infused
9679
+
9680
+ Example::
9681
+
9682
+ # pipeline: codepipeline.Pipeline
9683
+
9684
+
9685
+ source_output = codepipeline.Artifact()
9686
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
9687
+ action_name="CodeStarConnectionsSourceAction",
9688
+ output=source_output,
9689
+ connection_arn="your-connection-arn",
9690
+ owner="your-owner",
9691
+ repo="your-repo"
9692
+ )
9693
+
9694
+ scan_output = codepipeline.Artifact()
9695
+ scan_action = codepipeline_actions.InspectorSourceCodeScanAction(
9696
+ action_name="InspectorSourceCodeScanAction",
9697
+ input=source_output,
9698
+ output=scan_output
9699
+ )
9700
+
9701
+ pipeline.add_stage(
9702
+ stage_name="Source",
9703
+ actions=[source_action]
9704
+ )
9705
+ pipeline.add_stage(
9706
+ stage_name="Scan",
9707
+ actions=[scan_action]
9708
+ )
9709
+ '''
9710
+
9711
+ def __init__(
9712
+ self,
9713
+ *,
9714
+ input: _Artifact_0cb05964,
9715
+ output: _Artifact_0cb05964,
9716
+ critical_threshold: typing.Optional[jsii.Number] = None,
9717
+ high_threshold: typing.Optional[jsii.Number] = None,
9718
+ low_threshold: typing.Optional[jsii.Number] = None,
9719
+ medium_threshold: typing.Optional[jsii.Number] = None,
9720
+ role: typing.Optional[_IRole_235f5d8e] = None,
9721
+ action_name: builtins.str,
9722
+ run_order: typing.Optional[jsii.Number] = None,
9723
+ variables_namespace: typing.Optional[builtins.str] = None,
9724
+ ) -> None:
9725
+ '''
9726
+ :param input: The source code to scan for vulnerabilities.
9727
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
9728
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9729
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9730
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9731
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9732
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
9733
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
9734
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
9735
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
9736
+ '''
9737
+ props = InspectorSourceCodeScanActionProps(
9738
+ input=input,
9739
+ output=output,
9740
+ critical_threshold=critical_threshold,
9741
+ high_threshold=high_threshold,
9742
+ low_threshold=low_threshold,
9743
+ medium_threshold=medium_threshold,
9744
+ role=role,
9745
+ action_name=action_name,
9746
+ run_order=run_order,
9747
+ variables_namespace=variables_namespace,
9748
+ )
9749
+
9750
+ jsii.create(self.__class__, self, [props])
9751
+
9752
+ @jsii.member(jsii_name="bound")
9753
+ def _bound(
9754
+ self,
9755
+ scope: _constructs_77d1e7e8.Construct,
9756
+ stage: _IStage_415fc571,
9757
+ *,
9758
+ bucket: _IBucket_42e086fd,
9759
+ role: _IRole_235f5d8e,
9760
+ ) -> _ActionConfig_846fc217:
9761
+ '''This is a renamed version of the ``IAction.bind`` method.
9762
+
9763
+ :param scope: -
9764
+ :param stage: -
9765
+ :param bucket:
9766
+ :param role:
9767
+ '''
9768
+ if __debug__:
9769
+ type_hints = typing.get_type_hints(_typecheckingstub__45cb7f03b6f947f8e3545d0c1c5e5d7b428fd0bbe2dec88db250699b2fba4ec2)
9770
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
9771
+ check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
9772
+ options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
9773
+
9774
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, options]))
9775
+
9776
+ @jsii.member(jsii_name="renderActionConfiguration")
9777
+ def _render_action_configuration(self) -> typing.Mapping[builtins.str, typing.Any]:
9778
+ return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderActionConfiguration", []))
8623
9779
 
8624
- NONE = "NONE"
8625
- POLL = "POLL"
8626
- WEBHOOK = "WEBHOOK"
8627
9780
 
9781
+ @jsii.data_type(
9782
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorSourceCodeScanActionProps",
9783
+ jsii_struct_bases=[InspectorScanActionBaseProps],
9784
+ name_mapping={
9785
+ "action_name": "actionName",
9786
+ "run_order": "runOrder",
9787
+ "variables_namespace": "variablesNamespace",
9788
+ "role": "role",
9789
+ "output": "output",
9790
+ "critical_threshold": "criticalThreshold",
9791
+ "high_threshold": "highThreshold",
9792
+ "low_threshold": "lowThreshold",
9793
+ "medium_threshold": "mediumThreshold",
9794
+ "input": "input",
9795
+ },
9796
+ )
9797
+ class InspectorSourceCodeScanActionProps(InspectorScanActionBaseProps):
9798
+ def __init__(
9799
+ self,
9800
+ *,
9801
+ action_name: builtins.str,
9802
+ run_order: typing.Optional[jsii.Number] = None,
9803
+ variables_namespace: typing.Optional[builtins.str] = None,
9804
+ role: typing.Optional[_IRole_235f5d8e] = None,
9805
+ output: _Artifact_0cb05964,
9806
+ critical_threshold: typing.Optional[jsii.Number] = None,
9807
+ high_threshold: typing.Optional[jsii.Number] = None,
9808
+ low_threshold: typing.Optional[jsii.Number] = None,
9809
+ medium_threshold: typing.Optional[jsii.Number] = None,
9810
+ input: _Artifact_0cb05964,
9811
+ ) -> None:
9812
+ '''Construction properties of the ``InspectorSourceCodeScanAction``.
8628
9813
 
8629
- @jsii.interface(jsii_type="aws-cdk-lib.aws_codepipeline_actions.ICustomEventRule")
8630
- class ICustomEventRule(typing_extensions.Protocol):
8631
- '''Represents a custom event rule in AWS CodePipeline Actions.
9814
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
9815
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
9816
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
9817
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
9818
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
9819
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9820
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9821
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9822
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
9823
+ :param input: The source code to scan for vulnerabilities.
8632
9824
 
8633
- This interface defines the structure for specifying a custom event rule
8634
- in the AWS CodePipeline Actions module. The event rule is defined by an
8635
- event pattern and a target.
9825
+ :exampleMetadata: infused
8636
9826
 
8637
- :see: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events_targets-readme.html
8638
- '''
9827
+ Example::
8639
9828
 
8640
- @builtins.property
8641
- @jsii.member(jsii_name="eventPattern")
8642
- def event_pattern(self) -> _EventPattern_fe557901:
8643
- '''event pattern when this rule should be triggered.'''
8644
- ...
9829
+ # pipeline: codepipeline.Pipeline
9830
+
9831
+
9832
+ source_output = codepipeline.Artifact()
9833
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
9834
+ action_name="CodeStarConnectionsSourceAction",
9835
+ output=source_output,
9836
+ connection_arn="your-connection-arn",
9837
+ owner="your-owner",
9838
+ repo="your-repo"
9839
+ )
9840
+
9841
+ scan_output = codepipeline.Artifact()
9842
+ scan_action = codepipeline_actions.InspectorSourceCodeScanAction(
9843
+ action_name="InspectorSourceCodeScanAction",
9844
+ input=source_output,
9845
+ output=scan_output
9846
+ )
9847
+
9848
+ pipeline.add_stage(
9849
+ stage_name="Source",
9850
+ actions=[source_action]
9851
+ )
9852
+ pipeline.add_stage(
9853
+ stage_name="Scan",
9854
+ actions=[scan_action]
9855
+ )
9856
+ '''
9857
+ if __debug__:
9858
+ type_hints = typing.get_type_hints(_typecheckingstub__b15e4f7143687072e838007e65ae09dfa2481ef37d0679cc1fe389ce6997a557)
9859
+ check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
9860
+ check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
9861
+ check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
9862
+ check_type(argname="argument role", value=role, expected_type=type_hints["role"])
9863
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
9864
+ check_type(argname="argument critical_threshold", value=critical_threshold, expected_type=type_hints["critical_threshold"])
9865
+ check_type(argname="argument high_threshold", value=high_threshold, expected_type=type_hints["high_threshold"])
9866
+ check_type(argname="argument low_threshold", value=low_threshold, expected_type=type_hints["low_threshold"])
9867
+ check_type(argname="argument medium_threshold", value=medium_threshold, expected_type=type_hints["medium_threshold"])
9868
+ check_type(argname="argument input", value=input, expected_type=type_hints["input"])
9869
+ self._values: typing.Dict[builtins.str, typing.Any] = {
9870
+ "action_name": action_name,
9871
+ "output": output,
9872
+ "input": input,
9873
+ }
9874
+ if run_order is not None:
9875
+ self._values["run_order"] = run_order
9876
+ if variables_namespace is not None:
9877
+ self._values["variables_namespace"] = variables_namespace
9878
+ if role is not None:
9879
+ self._values["role"] = role
9880
+ if critical_threshold is not None:
9881
+ self._values["critical_threshold"] = critical_threshold
9882
+ if high_threshold is not None:
9883
+ self._values["high_threshold"] = high_threshold
9884
+ if low_threshold is not None:
9885
+ self._values["low_threshold"] = low_threshold
9886
+ if medium_threshold is not None:
9887
+ self._values["medium_threshold"] = medium_threshold
8645
9888
 
8646
9889
  @builtins.property
8647
- @jsii.member(jsii_name="target")
8648
- def target(self) -> _IRuleTarget_7a91f454:
8649
- '''Target e.g. Lambda when event pattern is fulfilled.'''
8650
- ...
9890
+ def action_name(self) -> builtins.str:
9891
+ '''The physical, human-readable name of the Action.
8651
9892
 
8652
- @builtins.property
8653
- @jsii.member(jsii_name="description")
8654
- def description(self) -> typing.Optional[builtins.str]:
8655
- '''Description.'''
8656
- ...
9893
+ Note that Action names must be unique within a single Stage.
9894
+ '''
9895
+ result = self._values.get("action_name")
9896
+ assert result is not None, "Required property 'action_name' is missing"
9897
+ return typing.cast(builtins.str, result)
8657
9898
 
8658
9899
  @builtins.property
8659
- @jsii.member(jsii_name="ruleName")
8660
- def rule_name(self) -> typing.Optional[builtins.str]:
8661
- '''Rulename.'''
8662
- ...
8663
-
8664
-
8665
- class _ICustomEventRuleProxy:
8666
- '''Represents a custom event rule in AWS CodePipeline Actions.
9900
+ def run_order(self) -> typing.Optional[jsii.Number]:
9901
+ '''The runOrder property for this Action.
8667
9902
 
8668
- This interface defines the structure for specifying a custom event rule
8669
- in the AWS CodePipeline Actions module. The event rule is defined by an
8670
- event pattern and a target.
9903
+ RunOrder determines the relative order in which multiple Actions in the same Stage execute.
8671
9904
 
8672
- :see: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_events_targets-readme.html
8673
- '''
9905
+ :default: 1
8674
9906
 
8675
- __jsii_type__: typing.ClassVar[str] = "aws-cdk-lib.aws_codepipeline_actions.ICustomEventRule"
9907
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html
9908
+ '''
9909
+ result = self._values.get("run_order")
9910
+ return typing.cast(typing.Optional[jsii.Number], result)
8676
9911
 
8677
9912
  @builtins.property
8678
- @jsii.member(jsii_name="eventPattern")
8679
- def event_pattern(self) -> _EventPattern_fe557901:
8680
- '''event pattern when this rule should be triggered.'''
8681
- return typing.cast(_EventPattern_fe557901, jsii.get(self, "eventPattern"))
9913
+ def variables_namespace(self) -> typing.Optional[builtins.str]:
9914
+ '''The name of the namespace to use for variables emitted by this action.
8682
9915
 
8683
- @builtins.property
8684
- @jsii.member(jsii_name="target")
8685
- def target(self) -> _IRuleTarget_7a91f454:
8686
- '''Target e.g. Lambda when event pattern is fulfilled.'''
8687
- return typing.cast(_IRuleTarget_7a91f454, jsii.get(self, "target"))
9916
+ :default:
8688
9917
 
8689
- @builtins.property
8690
- @jsii.member(jsii_name="description")
8691
- def description(self) -> typing.Optional[builtins.str]:
8692
- '''Description.'''
8693
- return typing.cast(typing.Optional[builtins.str], jsii.get(self, "description"))
9918
+ - a name will be generated, based on the stage and action names,
9919
+ if any of the action's variables were referenced - otherwise,
9920
+ no namespace will be set
9921
+ '''
9922
+ result = self._values.get("variables_namespace")
9923
+ return typing.cast(typing.Optional[builtins.str], result)
8694
9924
 
8695
9925
  @builtins.property
8696
- @jsii.member(jsii_name="ruleName")
8697
- def rule_name(self) -> typing.Optional[builtins.str]:
8698
- '''Rulename.'''
8699
- return typing.cast(typing.Optional[builtins.str], jsii.get(self, "ruleName"))
8700
-
8701
- # Adding a "__jsii_proxy_class__(): typing.Type" function to the interface
8702
- typing.cast(typing.Any, ICustomEventRule).__jsii_proxy_class__ = lambda : _ICustomEventRuleProxy
8703
-
8704
-
8705
- @jsii.interface(jsii_type="aws-cdk-lib.aws_codepipeline_actions.IJenkinsProvider")
8706
- class IJenkinsProvider(_constructs_77d1e7e8.IConstruct, typing_extensions.Protocol):
8707
- '''A Jenkins provider.
9926
+ def role(self) -> typing.Optional[_IRole_235f5d8e]:
9927
+ '''The Role in which context's this Action will be executing in.
8708
9928
 
8709
- If you want to create a new Jenkins provider managed alongside your CDK code,
8710
- instantiate the ``JenkinsProvider`` class directly.
9929
+ The Pipeline's Role will assume this Role
9930
+ (the required permissions for that will be granted automatically)
9931
+ right before executing this Action.
9932
+ This Action will be passed into your ``IAction.bind``
9933
+ method in the ``ActionBindOptions.role`` property.
8711
9934
 
8712
- If you want to reference an already registered provider,
8713
- use the ``JenkinsProvider#fromJenkinsProviderAttributes`` method.
8714
- '''
9935
+ :default: a new Role will be generated
9936
+ '''
9937
+ result = self._values.get("role")
9938
+ return typing.cast(typing.Optional[_IRole_235f5d8e], result)
8715
9939
 
8716
9940
  @builtins.property
8717
- @jsii.member(jsii_name="providerName")
8718
- def provider_name(self) -> builtins.str:
8719
- ...
9941
+ def output(self) -> _Artifact_0cb05964:
9942
+ '''Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.'''
9943
+ result = self._values.get("output")
9944
+ assert result is not None, "Required property 'output' is missing"
9945
+ return typing.cast(_Artifact_0cb05964, result)
8720
9946
 
8721
9947
  @builtins.property
8722
- @jsii.member(jsii_name="serverUrl")
8723
- def server_url(self) -> builtins.str:
8724
- ...
9948
+ def critical_threshold(self) -> typing.Optional[jsii.Number]:
9949
+ '''The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
9950
+
9951
+ :default: - no threshold
9952
+ '''
9953
+ result = self._values.get("critical_threshold")
9954
+ return typing.cast(typing.Optional[jsii.Number], result)
8725
9955
 
8726
9956
  @builtins.property
8727
- @jsii.member(jsii_name="version")
8728
- def version(self) -> builtins.str:
8729
- ...
9957
+ def high_threshold(self) -> typing.Optional[jsii.Number]:
9958
+ '''The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
8730
9959
 
9960
+ :default: - no threshold
9961
+ '''
9962
+ result = self._values.get("high_threshold")
9963
+ return typing.cast(typing.Optional[jsii.Number], result)
8731
9964
 
8732
- class _IJenkinsProviderProxy(
8733
- jsii.proxy_for(_constructs_77d1e7e8.IConstruct), # type: ignore[misc]
8734
- ):
8735
- '''A Jenkins provider.
9965
+ @builtins.property
9966
+ def low_threshold(self) -> typing.Optional[jsii.Number]:
9967
+ '''The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
8736
9968
 
8737
- If you want to create a new Jenkins provider managed alongside your CDK code,
8738
- instantiate the ``JenkinsProvider`` class directly.
9969
+ :default: - no threshold
9970
+ '''
9971
+ result = self._values.get("low_threshold")
9972
+ return typing.cast(typing.Optional[jsii.Number], result)
8739
9973
 
8740
- If you want to reference an already registered provider,
8741
- use the ``JenkinsProvider#fromJenkinsProviderAttributes`` method.
8742
- '''
9974
+ @builtins.property
9975
+ def medium_threshold(self) -> typing.Optional[jsii.Number]:
9976
+ '''The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
8743
9977
 
8744
- __jsii_type__: typing.ClassVar[str] = "aws-cdk-lib.aws_codepipeline_actions.IJenkinsProvider"
9978
+ :default: - no threshold
9979
+ '''
9980
+ result = self._values.get("medium_threshold")
9981
+ return typing.cast(typing.Optional[jsii.Number], result)
8745
9982
 
8746
9983
  @builtins.property
8747
- @jsii.member(jsii_name="providerName")
8748
- def provider_name(self) -> builtins.str:
8749
- return typing.cast(builtins.str, jsii.get(self, "providerName"))
9984
+ def input(self) -> _Artifact_0cb05964:
9985
+ '''The source code to scan for vulnerabilities.'''
9986
+ result = self._values.get("input")
9987
+ assert result is not None, "Required property 'input' is missing"
9988
+ return typing.cast(_Artifact_0cb05964, result)
8750
9989
 
8751
- @builtins.property
8752
- @jsii.member(jsii_name="serverUrl")
8753
- def server_url(self) -> builtins.str:
8754
- return typing.cast(builtins.str, jsii.get(self, "serverUrl"))
9990
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
9991
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
8755
9992
 
8756
- @builtins.property
8757
- @jsii.member(jsii_name="version")
8758
- def version(self) -> builtins.str:
8759
- return typing.cast(builtins.str, jsii.get(self, "version"))
9993
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
9994
+ return not (rhs == self)
8760
9995
 
8761
- # Adding a "__jsii_proxy_class__(): typing.Type" function to the interface
8762
- typing.cast(typing.Any, IJenkinsProvider).__jsii_proxy_class__ = lambda : _IJenkinsProviderProxy
9996
+ def __repr__(self) -> str:
9997
+ return "InspectorSourceCodeScanActionProps(%s)" % ", ".join(
9998
+ k + "=" + repr(v) for k, v in self._values.items()
9999
+ )
8763
10000
 
8764
10001
 
8765
10002
  class JenkinsAction(
@@ -9917,6 +11154,55 @@ class OrganizationsDeploymentProps:
9917
11154
  )
9918
11155
 
9919
11156
 
11157
+ @jsii.enum(jsii_type="aws-cdk-lib.aws_codepipeline_actions.RegistryType")
11158
+ class RegistryType(enum.Enum):
11159
+ '''The type of registry to use for the EcrBuildAndPublish action.
11160
+
11161
+ :exampleMetadata: infused
11162
+
11163
+ Example::
11164
+
11165
+ import aws_cdk.aws_ecr as ecr
11166
+
11167
+ # pipeline: codepipeline.Pipeline
11168
+ # repository: ecr.IRepository
11169
+
11170
+
11171
+ source_output = codepipeline.Artifact()
11172
+ # your source repository
11173
+ source_action = codepipeline_actions.CodeStarConnectionsSourceAction(
11174
+ action_name="CodeStarConnectionsSourceAction",
11175
+ output=source_output,
11176
+ connection_arn="your-connection-arn",
11177
+ owner="your-owner",
11178
+ repo="your-repo"
11179
+ )
11180
+
11181
+ build_action = codepipeline_actions.EcrBuildAndPublishAction(
11182
+ action_name="EcrBuildAndPublishAction",
11183
+ repository_name=repository.repository_name,
11184
+ registry_type=codepipeline_actions.RegistryType.PRIVATE,
11185
+ dockerfile_directory_path="./my-dir", # The path indicates ./my-dir/Dockerfile in the source repository
11186
+ image_tags=["my-tag-1", "my-tag-2"],
11187
+ input=source_output
11188
+ )
11189
+
11190
+ pipeline.add_stage(
11191
+ stage_name="Source",
11192
+ actions=[source_action]
11193
+ )
11194
+ pipeline.add_stage(
11195
+ stage_name="Build",
11196
+ actions=[build_action]
11197
+ )
11198
+ '''
11199
+
11200
+ PRIVATE = "PRIVATE"
11201
+ '''Private registry.'''
11202
+ PUBLIC = "PUBLIC"
11203
+ '''Public registry.'''
11204
+
11205
+
9920
11206
  class S3DeployAction(
9921
11207
  Action,
9922
11208
  metaclass=jsii.JSIIMeta,
@@ -11671,51 +12957,324 @@ class StepFunctionsInvokeActionProps(_CommonAwsActionProps_8b809bb6):
11671
12957
  output: typing.Optional[_Artifact_0cb05964] = None,
11672
12958
  state_machine_input: typing.Optional[StateMachineInput] = None,
11673
12959
  ) -> None:
11674
- '''Construction properties of the ``StepFunctionsInvokeAction StepFunction Invoke Action``.
12960
+ '''Construction properties of the ``StepFunctionsInvokeAction StepFunction Invoke Action``.
12961
+
12962
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
12963
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
12964
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
12965
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
12966
+ :param state_machine: The state machine to invoke.
12967
+ :param execution_name_prefix: Prefix (optional). By default, the action execution ID is used as the state machine execution name. If a prefix is provided, it is prepended to the action execution ID with a hyphen and together used as the state machine execution name. Default: - action execution ID
12968
+ :param output: The optional output Artifact of the Action. Default: the Action will not have any outputs
12969
+ :param state_machine_input: Represents the input to the StateMachine. This includes input artifact, input type and the statemachine input. Default: - none
12970
+
12971
+ :exampleMetadata: infused
12972
+
12973
+ Example::
12974
+
12975
+ import aws_cdk.aws_stepfunctions as stepfunctions
12976
+
12977
+ pipeline = codepipeline.Pipeline(self, "MyPipeline")
12978
+ start_state = stepfunctions.Pass(self, "StartState")
12979
+ simple_state_machine = stepfunctions.StateMachine(self, "SimpleStateMachine",
12980
+ definition=start_state
12981
+ )
12982
+ step_function_action = codepipeline_actions.StepFunctionInvokeAction(
12983
+ action_name="Invoke",
12984
+ state_machine=simple_state_machine,
12985
+ state_machine_input=codepipeline_actions.StateMachineInput.literal({"IsHelloWorldExample": True})
12986
+ )
12987
+ pipeline.add_stage(
12988
+ stage_name="StepFunctions",
12989
+ actions=[step_function_action]
12990
+ )
12991
+ '''
12992
+ if __debug__:
12993
+ type_hints = typing.get_type_hints(_typecheckingstub__64ac90d220b5e655386915e2881b269f896519c023a90afd1756161c9305f606)
12994
+ check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
12995
+ check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
12996
+ check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
12997
+ check_type(argname="argument role", value=role, expected_type=type_hints["role"])
12998
+ check_type(argname="argument state_machine", value=state_machine, expected_type=type_hints["state_machine"])
12999
+ check_type(argname="argument execution_name_prefix", value=execution_name_prefix, expected_type=type_hints["execution_name_prefix"])
13000
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
13001
+ check_type(argname="argument state_machine_input", value=state_machine_input, expected_type=type_hints["state_machine_input"])
13002
+ self._values: typing.Dict[builtins.str, typing.Any] = {
13003
+ "action_name": action_name,
13004
+ "state_machine": state_machine,
13005
+ }
13006
+ if run_order is not None:
13007
+ self._values["run_order"] = run_order
13008
+ if variables_namespace is not None:
13009
+ self._values["variables_namespace"] = variables_namespace
13010
+ if role is not None:
13011
+ self._values["role"] = role
13012
+ if execution_name_prefix is not None:
13013
+ self._values["execution_name_prefix"] = execution_name_prefix
13014
+ if output is not None:
13015
+ self._values["output"] = output
13016
+ if state_machine_input is not None:
13017
+ self._values["state_machine_input"] = state_machine_input
13018
+
13019
+ @builtins.property
13020
+ def action_name(self) -> builtins.str:
13021
+ '''The physical, human-readable name of the Action.
13022
+
13023
+ Note that Action names must be unique within a single Stage.
13024
+ '''
13025
+ result = self._values.get("action_name")
13026
+ assert result is not None, "Required property 'action_name' is missing"
13027
+ return typing.cast(builtins.str, result)
13028
+
13029
+ @builtins.property
13030
+ def run_order(self) -> typing.Optional[jsii.Number]:
13031
+ '''The runOrder property for this Action.
13032
+
13033
+ RunOrder determines the relative order in which multiple Actions in the same Stage execute.
13034
+
13035
+ :default: 1
13036
+
13037
+ :see: https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html
13038
+ '''
13039
+ result = self._values.get("run_order")
13040
+ return typing.cast(typing.Optional[jsii.Number], result)
13041
+
13042
+ @builtins.property
13043
+ def variables_namespace(self) -> typing.Optional[builtins.str]:
13044
+ '''The name of the namespace to use for variables emitted by this action.
13045
+
13046
+ :default:
13047
+
13048
+ - a name will be generated, based on the stage and action names,
13049
+ if any of the action's variables were referenced - otherwise,
13050
+ no namespace will be set
13051
+ '''
13052
+ result = self._values.get("variables_namespace")
13053
+ return typing.cast(typing.Optional[builtins.str], result)
13054
+
13055
+ @builtins.property
13056
+ def role(self) -> typing.Optional[_IRole_235f5d8e]:
13057
+ '''The Role in which context's this Action will be executing in.
13058
+
13059
+ The Pipeline's Role will assume this Role
13060
+ (the required permissions for that will be granted automatically)
13061
+ right before executing this Action.
13062
+ This Action will be passed into your ``IAction.bind``
13063
+ method in the ``ActionBindOptions.role`` property.
13064
+
13065
+ :default: a new Role will be generated
13066
+ '''
13067
+ result = self._values.get("role")
13068
+ return typing.cast(typing.Optional[_IRole_235f5d8e], result)
13069
+
13070
+ @builtins.property
13071
+ def state_machine(self) -> _IStateMachine_73e8d2b0:
13072
+ '''The state machine to invoke.'''
13073
+ result = self._values.get("state_machine")
13074
+ assert result is not None, "Required property 'state_machine' is missing"
13075
+ return typing.cast(_IStateMachine_73e8d2b0, result)
13076
+
13077
+ @builtins.property
13078
+ def execution_name_prefix(self) -> typing.Optional[builtins.str]:
13079
+ '''Prefix (optional).
13080
+
13081
+ By default, the action execution ID is used as the state machine execution name.
13082
+ If a prefix is provided, it is prepended to the action execution ID with a hyphen and
13083
+ together used as the state machine execution name.
13084
+
13085
+ :default: - action execution ID
13086
+ '''
13087
+ result = self._values.get("execution_name_prefix")
13088
+ return typing.cast(typing.Optional[builtins.str], result)
13089
+
13090
+ @builtins.property
13091
+ def output(self) -> typing.Optional[_Artifact_0cb05964]:
13092
+ '''The optional output Artifact of the Action.
13093
+
13094
+ :default: the Action will not have any outputs
13095
+ '''
13096
+ result = self._values.get("output")
13097
+ return typing.cast(typing.Optional[_Artifact_0cb05964], result)
13098
+
13099
+ @builtins.property
13100
+ def state_machine_input(self) -> typing.Optional[StateMachineInput]:
13101
+ '''Represents the input to the StateMachine.
13102
+
13103
+ This includes input artifact, input type and the statemachine input.
13104
+
13105
+ :default: - none
13106
+ '''
13107
+ result = self._values.get("state_machine_input")
13108
+ return typing.cast(typing.Optional[StateMachineInput], result)
13109
+
13110
+ def __eq__(self, rhs: typing.Any) -> builtins.bool:
13111
+ return isinstance(rhs, self.__class__) and rhs._values == self._values
13112
+
13113
+ def __ne__(self, rhs: typing.Any) -> builtins.bool:
13114
+ return not (rhs == self)
13115
+
13116
+ def __repr__(self) -> str:
13117
+ return "StepFunctionsInvokeActionProps(%s)" % ", ".join(
13118
+ k + "=" + repr(v) for k, v in self._values.items()
13119
+ )
13120
+
13121
+
13122
+ @jsii.implements(IJenkinsProvider)
13123
+ class BaseJenkinsProvider(
13124
+ _constructs_77d1e7e8.Construct,
13125
+ metaclass=jsii.JSIIAbstractClass,
13126
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.BaseJenkinsProvider",
13127
+ ):
13128
+ def __init__(
13129
+ self,
13130
+ scope: _constructs_77d1e7e8.Construct,
13131
+ id: builtins.str,
13132
+ version: typing.Optional[builtins.str] = None,
13133
+ ) -> None:
13134
+ '''
13135
+ :param scope: -
13136
+ :param id: -
13137
+ :param version: -
13138
+ '''
13139
+ if __debug__:
13140
+ type_hints = typing.get_type_hints(_typecheckingstub__8038675dee538d81000d6714c6f38401c5d7a19b8e5d7a412a3e91fd12717854)
13141
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
13142
+ check_type(argname="argument id", value=id, expected_type=type_hints["id"])
13143
+ check_type(argname="argument version", value=version, expected_type=type_hints["version"])
13144
+ jsii.create(self.__class__, self, [scope, id, version])
13145
+
13146
+ @builtins.property
13147
+ @jsii.member(jsii_name="providerName")
13148
+ @abc.abstractmethod
13149
+ def provider_name(self) -> builtins.str:
13150
+ ...
13151
+
13152
+ @builtins.property
13153
+ @jsii.member(jsii_name="serverUrl")
13154
+ @abc.abstractmethod
13155
+ def server_url(self) -> builtins.str:
13156
+ ...
13157
+
13158
+ @builtins.property
13159
+ @jsii.member(jsii_name="version")
13160
+ def version(self) -> builtins.str:
13161
+ return typing.cast(builtins.str, jsii.get(self, "version"))
13162
+
13163
+
13164
+ class _BaseJenkinsProviderProxy(BaseJenkinsProvider):
13165
+ @builtins.property
13166
+ @jsii.member(jsii_name="providerName")
13167
+ def provider_name(self) -> builtins.str:
13168
+ return typing.cast(builtins.str, jsii.get(self, "providerName"))
13169
+
13170
+ @builtins.property
13171
+ @jsii.member(jsii_name="serverUrl")
13172
+ def server_url(self) -> builtins.str:
13173
+ return typing.cast(builtins.str, jsii.get(self, "serverUrl"))
13174
+
13175
+ # Adding a "__jsii_proxy_class__(): typing.Type" function to the abstract class
13176
+ typing.cast(typing.Any, BaseJenkinsProvider).__jsii_proxy_class__ = lambda : _BaseJenkinsProviderProxy
13177
+
13178
+
13179
+ @jsii.data_type(
13180
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.CloudFormationDeployStackInstancesActionProps",
13181
+ jsii_struct_bases=[
13182
+ _CommonAwsActionProps_8b809bb6, CommonCloudFormationStackSetOptions
13183
+ ],
13184
+ name_mapping={
13185
+ "action_name": "actionName",
13186
+ "run_order": "runOrder",
13187
+ "variables_namespace": "variablesNamespace",
13188
+ "role": "role",
13189
+ "failure_tolerance_percentage": "failureTolerancePercentage",
13190
+ "max_account_concurrency_percentage": "maxAccountConcurrencyPercentage",
13191
+ "stack_set_region": "stackSetRegion",
13192
+ "stack_instances": "stackInstances",
13193
+ "stack_set_name": "stackSetName",
13194
+ "parameter_overrides": "parameterOverrides",
13195
+ },
13196
+ )
13197
+ class CloudFormationDeployStackInstancesActionProps(
13198
+ _CommonAwsActionProps_8b809bb6,
13199
+ CommonCloudFormationStackSetOptions,
13200
+ ):
13201
+ def __init__(
13202
+ self,
13203
+ *,
13204
+ action_name: builtins.str,
13205
+ run_order: typing.Optional[jsii.Number] = None,
13206
+ variables_namespace: typing.Optional[builtins.str] = None,
13207
+ role: typing.Optional[_IRole_235f5d8e] = None,
13208
+ failure_tolerance_percentage: typing.Optional[jsii.Number] = None,
13209
+ max_account_concurrency_percentage: typing.Optional[jsii.Number] = None,
13210
+ stack_set_region: typing.Optional[builtins.str] = None,
13211
+ stack_instances: StackInstances,
13212
+ stack_set_name: builtins.str,
13213
+ parameter_overrides: typing.Optional[StackSetParameters] = None,
13214
+ ) -> None:
13215
+ '''Properties for the CloudFormationDeployStackInstancesAction.
11675
13216
 
11676
13217
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
11677
13218
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
11678
13219
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
11679
13220
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
11680
- :param state_machine: The state machine to invoke.
11681
- :param execution_name_prefix: Prefix (optional). By default, the action execution ID is used as the state machine execution name. If a prefix is provided, it is prepended to the action execution ID with a hyphen and together used as the state machine execution name. Default: - action execution ID
11682
- :param output: The optional output Artifact of the Action. Default: the Action will not have any outputs
11683
- :param state_machine_input: Represents the input to the StateMachine. This includes input artifact, input type and the statemachine input. Default: - none
13221
+ :param failure_tolerance_percentage: The percentage of accounts per Region for which this stack operation can fail before AWS CloudFormation stops the operation in that Region. If the operation is stopped in a Region, AWS CloudFormation doesn't attempt the operation in subsequent Regions. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. Default: 0%
13222
+ :param max_account_concurrency_percentage: The maximum percentage of accounts in which to perform this operation at one time. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. If rounding down would result in zero, AWS CloudFormation sets the number as one instead. Although you use this setting to specify the maximum, for large deployments the actual number of accounts acted upon concurrently may be lower due to service throttling. Default: 1%
13223
+ :param stack_set_region: The AWS Region the StackSet is in. Note that a cross-region Pipeline requires replication buckets to function correctly. You can provide their names with the ``PipelineProps.crossRegionReplicationBuckets`` property. If you don't, the CodePipeline Construct will create new Stacks in your CDK app containing those buckets, that you will need to ``cdk deploy`` before deploying the main, Pipeline-containing Stack. Default: - same region as the Pipeline
13224
+ :param stack_instances: Specify where to create or update Stack Instances. You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
13225
+ :param stack_set_name: The name of the StackSet we are adding instances to.
13226
+ :param parameter_overrides: Parameter values that only apply to the current Stack Instances. These parameters are shared between all instances added by this action. Default: - no parameters will be overridden
11684
13227
 
11685
13228
  :exampleMetadata: infused
11686
13229
 
11687
13230
  Example::
11688
13231
 
11689
- import aws_cdk.aws_stepfunctions as stepfunctions
13232
+ # pipeline: codepipeline.Pipeline
13233
+ # source_output: codepipeline.Artifact
13234
+
11690
13235
 
11691
- pipeline = codepipeline.Pipeline(self, "MyPipeline")
11692
- start_state = stepfunctions.Pass(self, "StartState")
11693
- simple_state_machine = stepfunctions.StateMachine(self, "SimpleStateMachine",
11694
- definition=start_state
11695
- )
11696
- step_function_action = codepipeline_actions.StepFunctionInvokeAction(
11697
- action_name="Invoke",
11698
- state_machine=simple_state_machine,
11699
- state_machine_input=codepipeline_actions.StateMachineInput.literal({"IsHelloWorldExample": True})
11700
- )
11701
13236
  pipeline.add_stage(
11702
- stage_name="StepFunctions",
11703
- actions=[step_function_action]
13237
+ stage_name="DeployStackSets",
13238
+ actions=[
13239
+ # First, update the StackSet itself with the newest template
13240
+ codepipeline_actions.CloudFormationDeployStackSetAction(
13241
+ action_name="UpdateStackSet",
13242
+ run_order=1,
13243
+ stack_set_name="MyStackSet",
13244
+ template=codepipeline_actions.StackSetTemplate.from_artifact_path(source_output.at_path("template.yaml")),
13245
+
13246
+ # Change this to 'StackSetDeploymentModel.organizations()' if you want to deploy to OUs
13247
+ deployment_model=codepipeline_actions.StackSetDeploymentModel.self_managed(),
13248
+ # This deploys to a set of accounts
13249
+ stack_instances=codepipeline_actions.StackInstances.in_accounts(["111111111111"], ["us-east-1", "eu-west-1"])
13250
+ ),
13251
+
13252
+ # Afterwards, update/create additional instances in other accounts
13253
+ codepipeline_actions.CloudFormationDeployStackInstancesAction(
13254
+ action_name="AddMoreInstances",
13255
+ run_order=2,
13256
+ stack_set_name="MyStackSet",
13257
+ stack_instances=codepipeline_actions.StackInstances.in_accounts(["222222222222", "333333333333"], ["us-east-1", "eu-west-1"])
13258
+ )
13259
+ ]
11704
13260
  )
11705
13261
  '''
11706
13262
  if __debug__:
11707
- type_hints = typing.get_type_hints(_typecheckingstub__64ac90d220b5e655386915e2881b269f896519c023a90afd1756161c9305f606)
13263
+ type_hints = typing.get_type_hints(_typecheckingstub__74ad2f406f6e2b75484390d66800bc9f6856c72cd6da5761e1f0bc953e50c5f5)
11708
13264
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
11709
13265
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
11710
13266
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
11711
13267
  check_type(argname="argument role", value=role, expected_type=type_hints["role"])
11712
- check_type(argname="argument state_machine", value=state_machine, expected_type=type_hints["state_machine"])
11713
- check_type(argname="argument execution_name_prefix", value=execution_name_prefix, expected_type=type_hints["execution_name_prefix"])
11714
- check_type(argname="argument output", value=output, expected_type=type_hints["output"])
11715
- check_type(argname="argument state_machine_input", value=state_machine_input, expected_type=type_hints["state_machine_input"])
13268
+ check_type(argname="argument failure_tolerance_percentage", value=failure_tolerance_percentage, expected_type=type_hints["failure_tolerance_percentage"])
13269
+ check_type(argname="argument max_account_concurrency_percentage", value=max_account_concurrency_percentage, expected_type=type_hints["max_account_concurrency_percentage"])
13270
+ check_type(argname="argument stack_set_region", value=stack_set_region, expected_type=type_hints["stack_set_region"])
13271
+ check_type(argname="argument stack_instances", value=stack_instances, expected_type=type_hints["stack_instances"])
13272
+ check_type(argname="argument stack_set_name", value=stack_set_name, expected_type=type_hints["stack_set_name"])
13273
+ check_type(argname="argument parameter_overrides", value=parameter_overrides, expected_type=type_hints["parameter_overrides"])
11716
13274
  self._values: typing.Dict[builtins.str, typing.Any] = {
11717
13275
  "action_name": action_name,
11718
- "state_machine": state_machine,
13276
+ "stack_instances": stack_instances,
13277
+ "stack_set_name": stack_set_name,
11719
13278
  }
11720
13279
  if run_order is not None:
11721
13280
  self._values["run_order"] = run_order
@@ -11723,12 +13282,14 @@ class StepFunctionsInvokeActionProps(_CommonAwsActionProps_8b809bb6):
11723
13282
  self._values["variables_namespace"] = variables_namespace
11724
13283
  if role is not None:
11725
13284
  self._values["role"] = role
11726
- if execution_name_prefix is not None:
11727
- self._values["execution_name_prefix"] = execution_name_prefix
11728
- if output is not None:
11729
- self._values["output"] = output
11730
- if state_machine_input is not None:
11731
- self._values["state_machine_input"] = state_machine_input
13285
+ if failure_tolerance_percentage is not None:
13286
+ self._values["failure_tolerance_percentage"] = failure_tolerance_percentage
13287
+ if max_account_concurrency_percentage is not None:
13288
+ self._values["max_account_concurrency_percentage"] = max_account_concurrency_percentage
13289
+ if stack_set_region is not None:
13290
+ self._values["stack_set_region"] = stack_set_region
13291
+ if parameter_overrides is not None:
13292
+ self._values["parameter_overrides"] = parameter_overrides
11732
13293
 
11733
13294
  @builtins.property
11734
13295
  def action_name(self) -> builtins.str:
@@ -11782,44 +13343,73 @@ class StepFunctionsInvokeActionProps(_CommonAwsActionProps_8b809bb6):
11782
13343
  return typing.cast(typing.Optional[_IRole_235f5d8e], result)
11783
13344
 
11784
13345
  @builtins.property
11785
- def state_machine(self) -> _IStateMachine_73e8d2b0:
11786
- '''The state machine to invoke.'''
11787
- result = self._values.get("state_machine")
11788
- assert result is not None, "Required property 'state_machine' is missing"
11789
- return typing.cast(_IStateMachine_73e8d2b0, result)
13346
+ def failure_tolerance_percentage(self) -> typing.Optional[jsii.Number]:
13347
+ '''The percentage of accounts per Region for which this stack operation can fail before AWS CloudFormation stops the operation in that Region.
13348
+
13349
+ If
13350
+ the operation is stopped in a Region, AWS CloudFormation doesn't attempt the operation in subsequent Regions. When calculating the number
13351
+ of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number.
13352
+
13353
+ :default: 0%
13354
+ '''
13355
+ result = self._values.get("failure_tolerance_percentage")
13356
+ return typing.cast(typing.Optional[jsii.Number], result)
11790
13357
 
11791
13358
  @builtins.property
11792
- def execution_name_prefix(self) -> typing.Optional[builtins.str]:
11793
- '''Prefix (optional).
13359
+ def max_account_concurrency_percentage(self) -> typing.Optional[jsii.Number]:
13360
+ '''The maximum percentage of accounts in which to perform this operation at one time.
11794
13361
 
11795
- By default, the action execution ID is used as the state machine execution name.
11796
- If a prefix is provided, it is prepended to the action execution ID with a hyphen and
11797
- together used as the state machine execution name.
13362
+ When calculating the number of accounts based on the specified
13363
+ percentage, AWS CloudFormation rounds down to the next whole number. If rounding down would result in zero, AWS CloudFormation sets the number as
13364
+ one instead. Although you use this setting to specify the maximum, for large deployments the actual number of accounts acted upon concurrently
13365
+ may be lower due to service throttling.
11798
13366
 
11799
- :default: - action execution ID
13367
+ :default: 1%
11800
13368
  '''
11801
- result = self._values.get("execution_name_prefix")
13369
+ result = self._values.get("max_account_concurrency_percentage")
13370
+ return typing.cast(typing.Optional[jsii.Number], result)
13371
+
13372
+ @builtins.property
13373
+ def stack_set_region(self) -> typing.Optional[builtins.str]:
13374
+ '''The AWS Region the StackSet is in.
13375
+
13376
+ Note that a cross-region Pipeline requires replication buckets to function correctly.
13377
+ You can provide their names with the ``PipelineProps.crossRegionReplicationBuckets`` property.
13378
+ If you don't, the CodePipeline Construct will create new Stacks in your CDK app containing those buckets,
13379
+ that you will need to ``cdk deploy`` before deploying the main, Pipeline-containing Stack.
13380
+
13381
+ :default: - same region as the Pipeline
13382
+ '''
13383
+ result = self._values.get("stack_set_region")
11802
13384
  return typing.cast(typing.Optional[builtins.str], result)
11803
13385
 
11804
13386
  @builtins.property
11805
- def output(self) -> typing.Optional[_Artifact_0cb05964]:
11806
- '''The optional output Artifact of the Action.
13387
+ def stack_instances(self) -> StackInstances:
13388
+ '''Specify where to create or update Stack Instances.
11807
13389
 
11808
- :default: the Action will not have any outputs
13390
+ You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
11809
13391
  '''
11810
- result = self._values.get("output")
11811
- return typing.cast(typing.Optional[_Artifact_0cb05964], result)
13392
+ result = self._values.get("stack_instances")
13393
+ assert result is not None, "Required property 'stack_instances' is missing"
13394
+ return typing.cast(StackInstances, result)
11812
13395
 
11813
13396
  @builtins.property
11814
- def state_machine_input(self) -> typing.Optional[StateMachineInput]:
11815
- '''Represents the input to the StateMachine.
13397
+ def stack_set_name(self) -> builtins.str:
13398
+ '''The name of the StackSet we are adding instances to.'''
13399
+ result = self._values.get("stack_set_name")
13400
+ assert result is not None, "Required property 'stack_set_name' is missing"
13401
+ return typing.cast(builtins.str, result)
11816
13402
 
11817
- This includes input artifact, input type and the statemachine input.
13403
+ @builtins.property
13404
+ def parameter_overrides(self) -> typing.Optional[StackSetParameters]:
13405
+ '''Parameter values that only apply to the current Stack Instances.
11818
13406
 
11819
- :default: - none
13407
+ These parameters are shared between all instances added by this action.
13408
+
13409
+ :default: - no parameters will be overridden
11820
13410
  '''
11821
- result = self._values.get("state_machine_input")
11822
- return typing.cast(typing.Optional[StateMachineInput], result)
13411
+ result = self._values.get("parameter_overrides")
13412
+ return typing.cast(typing.Optional[StackSetParameters], result)
11823
13413
 
11824
13414
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
11825
13415
  return isinstance(rhs, self.__class__) and rhs._values == self._values
@@ -11828,70 +13418,13 @@ class StepFunctionsInvokeActionProps(_CommonAwsActionProps_8b809bb6):
11828
13418
  return not (rhs == self)
11829
13419
 
11830
13420
  def __repr__(self) -> str:
11831
- return "StepFunctionsInvokeActionProps(%s)" % ", ".join(
13421
+ return "CloudFormationDeployStackInstancesActionProps(%s)" % ", ".join(
11832
13422
  k + "=" + repr(v) for k, v in self._values.items()
11833
13423
  )
11834
13424
 
11835
13425
 
11836
- @jsii.implements(IJenkinsProvider)
11837
- class BaseJenkinsProvider(
11838
- _constructs_77d1e7e8.Construct,
11839
- metaclass=jsii.JSIIAbstractClass,
11840
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.BaseJenkinsProvider",
11841
- ):
11842
- def __init__(
11843
- self,
11844
- scope: _constructs_77d1e7e8.Construct,
11845
- id: builtins.str,
11846
- version: typing.Optional[builtins.str] = None,
11847
- ) -> None:
11848
- '''
11849
- :param scope: -
11850
- :param id: -
11851
- :param version: -
11852
- '''
11853
- if __debug__:
11854
- type_hints = typing.get_type_hints(_typecheckingstub__8038675dee538d81000d6714c6f38401c5d7a19b8e5d7a412a3e91fd12717854)
11855
- check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
11856
- check_type(argname="argument id", value=id, expected_type=type_hints["id"])
11857
- check_type(argname="argument version", value=version, expected_type=type_hints["version"])
11858
- jsii.create(self.__class__, self, [scope, id, version])
11859
-
11860
- @builtins.property
11861
- @jsii.member(jsii_name="providerName")
11862
- @abc.abstractmethod
11863
- def provider_name(self) -> builtins.str:
11864
- ...
11865
-
11866
- @builtins.property
11867
- @jsii.member(jsii_name="serverUrl")
11868
- @abc.abstractmethod
11869
- def server_url(self) -> builtins.str:
11870
- ...
11871
-
11872
- @builtins.property
11873
- @jsii.member(jsii_name="version")
11874
- def version(self) -> builtins.str:
11875
- return typing.cast(builtins.str, jsii.get(self, "version"))
11876
-
11877
-
11878
- class _BaseJenkinsProviderProxy(BaseJenkinsProvider):
11879
- @builtins.property
11880
- @jsii.member(jsii_name="providerName")
11881
- def provider_name(self) -> builtins.str:
11882
- return typing.cast(builtins.str, jsii.get(self, "providerName"))
11883
-
11884
- @builtins.property
11885
- @jsii.member(jsii_name="serverUrl")
11886
- def server_url(self) -> builtins.str:
11887
- return typing.cast(builtins.str, jsii.get(self, "serverUrl"))
11888
-
11889
- # Adding a "__jsii_proxy_class__(): typing.Type" function to the abstract class
11890
- typing.cast(typing.Any, BaseJenkinsProvider).__jsii_proxy_class__ = lambda : _BaseJenkinsProviderProxy
11891
-
11892
-
11893
13426
  @jsii.data_type(
11894
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.CloudFormationDeployStackInstancesActionProps",
13427
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.CloudFormationDeployStackSetActionProps",
11895
13428
  jsii_struct_bases=[
11896
13429
  _CommonAwsActionProps_8b809bb6, CommonCloudFormationStackSetOptions
11897
13430
  ],
@@ -11903,12 +13436,16 @@ typing.cast(typing.Any, BaseJenkinsProvider).__jsii_proxy_class__ = lambda : _Ba
11903
13436
  "failure_tolerance_percentage": "failureTolerancePercentage",
11904
13437
  "max_account_concurrency_percentage": "maxAccountConcurrencyPercentage",
11905
13438
  "stack_set_region": "stackSetRegion",
11906
- "stack_instances": "stackInstances",
11907
13439
  "stack_set_name": "stackSetName",
11908
- "parameter_overrides": "parameterOverrides",
13440
+ "template": "template",
13441
+ "cfn_capabilities": "cfnCapabilities",
13442
+ "deployment_model": "deploymentModel",
13443
+ "description": "description",
13444
+ "parameters": "parameters",
13445
+ "stack_instances": "stackInstances",
11909
13446
  },
11910
13447
  )
11911
- class CloudFormationDeployStackInstancesActionProps(
13448
+ class CloudFormationDeployStackSetActionProps(
11912
13449
  _CommonAwsActionProps_8b809bb6,
11913
13450
  CommonCloudFormationStackSetOptions,
11914
13451
  ):
@@ -11922,11 +13459,15 @@ class CloudFormationDeployStackInstancesActionProps(
11922
13459
  failure_tolerance_percentage: typing.Optional[jsii.Number] = None,
11923
13460
  max_account_concurrency_percentage: typing.Optional[jsii.Number] = None,
11924
13461
  stack_set_region: typing.Optional[builtins.str] = None,
11925
- stack_instances: StackInstances,
11926
13462
  stack_set_name: builtins.str,
11927
- parameter_overrides: typing.Optional[StackSetParameters] = None,
13463
+ template: StackSetTemplate,
13464
+ cfn_capabilities: typing.Optional[typing.Sequence[_CfnCapabilities_f5c35b06]] = None,
13465
+ deployment_model: typing.Optional[StackSetDeploymentModel] = None,
13466
+ description: typing.Optional[builtins.str] = None,
13467
+ parameters: typing.Optional[StackSetParameters] = None,
13468
+ stack_instances: typing.Optional[StackInstances] = None,
11928
13469
  ) -> None:
11929
- '''Properties for the CloudFormationDeployStackInstancesAction.
13470
+ '''Properties for the CloudFormationDeployStackSetAction.
11930
13471
 
11931
13472
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
11932
13473
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
@@ -11935,9 +13476,13 @@ class CloudFormationDeployStackInstancesActionProps(
11935
13476
  :param failure_tolerance_percentage: The percentage of accounts per Region for which this stack operation can fail before AWS CloudFormation stops the operation in that Region. If the operation is stopped in a Region, AWS CloudFormation doesn't attempt the operation in subsequent Regions. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. Default: 0%
11936
13477
  :param max_account_concurrency_percentage: The maximum percentage of accounts in which to perform this operation at one time. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. If rounding down would result in zero, AWS CloudFormation sets the number as one instead. Although you use this setting to specify the maximum, for large deployments the actual number of accounts acted upon concurrently may be lower due to service throttling. Default: 1%
11937
13478
  :param stack_set_region: The AWS Region the StackSet is in. Note that a cross-region Pipeline requires replication buckets to function correctly. You can provide their names with the ``PipelineProps.crossRegionReplicationBuckets`` property. If you don't, the CodePipeline Construct will create new Stacks in your CDK app containing those buckets, that you will need to ``cdk deploy`` before deploying the main, Pipeline-containing Stack. Default: - same region as the Pipeline
11938
- :param stack_instances: Specify where to create or update Stack Instances. You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
11939
- :param stack_set_name: The name of the StackSet we are adding instances to.
11940
- :param parameter_overrides: Parameter values that only apply to the current Stack Instances. These parameters are shared between all instances added by this action. Default: - no parameters will be overridden
13479
+ :param stack_set_name: The name to associate with the stack set. This name must be unique in the Region where it is created. The name may only contain alphanumeric and hyphen characters. It must begin with an alphabetic character and be 128 characters or fewer.
13480
+ :param template: The location of the template that defines the resources in the stack set. This must point to a template with a maximum size of 460,800 bytes. Enter the path to the source artifact name and template file.
13481
+ :param cfn_capabilities: Indicates that the template can create and update resources, depending on the types of resources in the template. You must use this property if you have IAM resources in your stack template or you create a stack directly from a template containing macros. Default: - the StackSet will have no IAM capabilities
13482
+ :param deployment_model: Determines how IAM roles are created and managed. The choices are: - Self Managed: you create IAM roles with the required permissions in the administration account and all target accounts. - Service Managed: only available if the account and target accounts are part of an AWS Organization. The necessary roles will be created for you. If you want to deploy to all accounts that are a member of AWS Organizations Organizational Units (OUs), you must select Service Managed permissions. Note: This parameter can only be changed when no stack instances exist in the stack set. Default: StackSetDeploymentModel.selfManaged()
13483
+ :param description: A description of the stack set. You can use this to describe the stack set’s purpose or other relevant information. Default: - no description
13484
+ :param parameters: The template parameters for your stack set. These parameters are shared between all instances of the stack set. Default: - no parameters will be used
13485
+ :param stack_instances: Specify where to create or update Stack Instances. You can specify either AWS Accounts Ids or AWS Organizations Organizational Units. Default: - don't create or update any Stack Instances
11941
13486
 
11942
13487
  :exampleMetadata: infused
11943
13488
 
@@ -11974,7 +13519,7 @@ class CloudFormationDeployStackInstancesActionProps(
11974
13519
  )
11975
13520
  '''
11976
13521
  if __debug__:
11977
- type_hints = typing.get_type_hints(_typecheckingstub__74ad2f406f6e2b75484390d66800bc9f6856c72cd6da5761e1f0bc953e50c5f5)
13522
+ type_hints = typing.get_type_hints(_typecheckingstub__ee2cef6462ecd2f50e6747ca0f4c5443f4167fadcb9b523b71950626de829059)
11978
13523
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
11979
13524
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
11980
13525
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
@@ -11982,13 +13527,17 @@ class CloudFormationDeployStackInstancesActionProps(
11982
13527
  check_type(argname="argument failure_tolerance_percentage", value=failure_tolerance_percentage, expected_type=type_hints["failure_tolerance_percentage"])
11983
13528
  check_type(argname="argument max_account_concurrency_percentage", value=max_account_concurrency_percentage, expected_type=type_hints["max_account_concurrency_percentage"])
11984
13529
  check_type(argname="argument stack_set_region", value=stack_set_region, expected_type=type_hints["stack_set_region"])
11985
- check_type(argname="argument stack_instances", value=stack_instances, expected_type=type_hints["stack_instances"])
11986
13530
  check_type(argname="argument stack_set_name", value=stack_set_name, expected_type=type_hints["stack_set_name"])
11987
- check_type(argname="argument parameter_overrides", value=parameter_overrides, expected_type=type_hints["parameter_overrides"])
13531
+ check_type(argname="argument template", value=template, expected_type=type_hints["template"])
13532
+ check_type(argname="argument cfn_capabilities", value=cfn_capabilities, expected_type=type_hints["cfn_capabilities"])
13533
+ check_type(argname="argument deployment_model", value=deployment_model, expected_type=type_hints["deployment_model"])
13534
+ check_type(argname="argument description", value=description, expected_type=type_hints["description"])
13535
+ check_type(argname="argument parameters", value=parameters, expected_type=type_hints["parameters"])
13536
+ check_type(argname="argument stack_instances", value=stack_instances, expected_type=type_hints["stack_instances"])
11988
13537
  self._values: typing.Dict[builtins.str, typing.Any] = {
11989
13538
  "action_name": action_name,
11990
- "stack_instances": stack_instances,
11991
13539
  "stack_set_name": stack_set_name,
13540
+ "template": template,
11992
13541
  }
11993
13542
  if run_order is not None:
11994
13543
  self._values["run_order"] = run_order
@@ -12002,8 +13551,16 @@ class CloudFormationDeployStackInstancesActionProps(
12002
13551
  self._values["max_account_concurrency_percentage"] = max_account_concurrency_percentage
12003
13552
  if stack_set_region is not None:
12004
13553
  self._values["stack_set_region"] = stack_set_region
12005
- if parameter_overrides is not None:
12006
- self._values["parameter_overrides"] = parameter_overrides
13554
+ if cfn_capabilities is not None:
13555
+ self._values["cfn_capabilities"] = cfn_capabilities
13556
+ if deployment_model is not None:
13557
+ self._values["deployment_model"] = deployment_model
13558
+ if description is not None:
13559
+ self._values["description"] = description
13560
+ if parameters is not None:
13561
+ self._values["parameters"] = parameters
13562
+ if stack_instances is not None:
13563
+ self._values["stack_instances"] = stack_instances
12007
13564
 
12008
13565
  @builtins.property
12009
13566
  def action_name(self) -> builtins.str:
@@ -12098,33 +13655,99 @@ class CloudFormationDeployStackInstancesActionProps(
12098
13655
  return typing.cast(typing.Optional[builtins.str], result)
12099
13656
 
12100
13657
  @builtins.property
12101
- def stack_instances(self) -> StackInstances:
12102
- '''Specify where to create or update Stack Instances.
13658
+ def stack_set_name(self) -> builtins.str:
13659
+ '''The name to associate with the stack set.
12103
13660
 
12104
- You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
12105
- '''
12106
- result = self._values.get("stack_instances")
12107
- assert result is not None, "Required property 'stack_instances' is missing"
12108
- return typing.cast(StackInstances, result)
13661
+ This name must be unique in the Region where it is created.
12109
13662
 
12110
- @builtins.property
12111
- def stack_set_name(self) -> builtins.str:
12112
- '''The name of the StackSet we are adding instances to.'''
13663
+ The name may only contain alphanumeric and hyphen characters. It must begin with an alphabetic character and be 128 characters or fewer.
13664
+ '''
12113
13665
  result = self._values.get("stack_set_name")
12114
13666
  assert result is not None, "Required property 'stack_set_name' is missing"
12115
13667
  return typing.cast(builtins.str, result)
12116
13668
 
12117
13669
  @builtins.property
12118
- def parameter_overrides(self) -> typing.Optional[StackSetParameters]:
12119
- '''Parameter values that only apply to the current Stack Instances.
13670
+ def template(self) -> StackSetTemplate:
13671
+ '''The location of the template that defines the resources in the stack set.
12120
13672
 
12121
- These parameters are shared between all instances added by this action.
13673
+ This must point to a template with a maximum size of 460,800 bytes.
12122
13674
 
12123
- :default: - no parameters will be overridden
13675
+ Enter the path to the source artifact name and template file.
12124
13676
  '''
12125
- result = self._values.get("parameter_overrides")
13677
+ result = self._values.get("template")
13678
+ assert result is not None, "Required property 'template' is missing"
13679
+ return typing.cast(StackSetTemplate, result)
13680
+
13681
+ @builtins.property
13682
+ def cfn_capabilities(
13683
+ self,
13684
+ ) -> typing.Optional[typing.List[_CfnCapabilities_f5c35b06]]:
13685
+ '''Indicates that the template can create and update resources, depending on the types of resources in the template.
13686
+
13687
+ You must use this property if you have IAM resources in your stack template or you create a stack directly from a template containing macros.
13688
+
13689
+ :default: - the StackSet will have no IAM capabilities
13690
+ '''
13691
+ result = self._values.get("cfn_capabilities")
13692
+ return typing.cast(typing.Optional[typing.List[_CfnCapabilities_f5c35b06]], result)
13693
+
13694
+ @builtins.property
13695
+ def deployment_model(self) -> typing.Optional[StackSetDeploymentModel]:
13696
+ '''Determines how IAM roles are created and managed.
13697
+
13698
+ The choices are:
13699
+
13700
+ - Self Managed: you create IAM roles with the required permissions
13701
+ in the administration account and all target accounts.
13702
+ - Service Managed: only available if the account and target accounts
13703
+ are part of an AWS Organization. The necessary roles will be created
13704
+ for you.
13705
+
13706
+ If you want to deploy to all accounts that are a member of AWS
13707
+ Organizations Organizational Units (OUs), you must select Service Managed
13708
+ permissions.
13709
+
13710
+ Note: This parameter can only be changed when no stack instances exist in
13711
+ the stack set.
13712
+
13713
+ :default: StackSetDeploymentModel.selfManaged()
13714
+ '''
13715
+ result = self._values.get("deployment_model")
13716
+ return typing.cast(typing.Optional[StackSetDeploymentModel], result)
13717
+
13718
+ @builtins.property
13719
+ def description(self) -> typing.Optional[builtins.str]:
13720
+ '''A description of the stack set.
13721
+
13722
+ You can use this to describe the stack set’s purpose or other relevant information.
13723
+
13724
+ :default: - no description
13725
+ '''
13726
+ result = self._values.get("description")
13727
+ return typing.cast(typing.Optional[builtins.str], result)
13728
+
13729
+ @builtins.property
13730
+ def parameters(self) -> typing.Optional[StackSetParameters]:
13731
+ '''The template parameters for your stack set.
13732
+
13733
+ These parameters are shared between all instances of the stack set.
13734
+
13735
+ :default: - no parameters will be used
13736
+ '''
13737
+ result = self._values.get("parameters")
12126
13738
  return typing.cast(typing.Optional[StackSetParameters], result)
12127
13739
 
13740
+ @builtins.property
13741
+ def stack_instances(self) -> typing.Optional[StackInstances]:
13742
+ '''Specify where to create or update Stack Instances.
13743
+
13744
+ You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
13745
+
13746
+ :default: - don't create or update any Stack Instances
13747
+ '''
13748
+ result = self._values.get("stack_instances")
13749
+ return typing.cast(typing.Optional[StackInstances], result)
13750
+
12128
13751
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
12129
13752
  return isinstance(rhs, self.__class__) and rhs._values == self._values
12130
13753
 
@@ -12132,37 +13755,132 @@ class CloudFormationDeployStackInstancesActionProps(
12132
13755
  return not (rhs == self)
12133
13756
 
12134
13757
  def __repr__(self) -> str:
12135
- return "CloudFormationDeployStackInstancesActionProps(%s)" % ", ".join(
13758
+ return "CloudFormationDeployStackSetActionProps(%s)" % ", ".join(
12136
13759
  k + "=" + repr(v) for k, v in self._values.items()
12137
13760
  )
12138
13761
 
12139
13762
 
13763
+ class InspectorEcrImageScanAction(
13764
+ InspectorScanActionBase,
13765
+ metaclass=jsii.JSIIMeta,
13766
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorEcrImageScanAction",
13767
+ ):
13768
+ '''CodePipeline invoke action that uses AWS InspectorScan for ECR images.
13769
+
13770
+ :exampleMetadata: infused
13771
+
13772
+ Example::
13773
+
13774
+ import aws_cdk.aws_ecr as ecr
13775
+
13776
+ # pipeline: codepipeline.Pipeline
13777
+ # repository: ecr.IRepository
13778
+
13779
+
13780
+ scan_output = codepipeline.Artifact()
13781
+ scan_action = codepipeline_actions.InspectorEcrImageScanAction(
13782
+ action_name="InspectorEcrImageScanAction",
13783
+ output=scan_output,
13784
+ repository=repository
13785
+ )
13786
+
13787
+ pipeline.add_stage(
13788
+ stage_name="Scan",
13789
+ actions=[scan_action]
13790
+ )
13791
+ '''
13792
+
13793
+ def __init__(
13794
+ self,
13795
+ *,
13796
+ repository: _IRepository_e6004aa6,
13797
+ image_tag: typing.Optional[builtins.str] = None,
13798
+ output: _Artifact_0cb05964,
13799
+ critical_threshold: typing.Optional[jsii.Number] = None,
13800
+ high_threshold: typing.Optional[jsii.Number] = None,
13801
+ low_threshold: typing.Optional[jsii.Number] = None,
13802
+ medium_threshold: typing.Optional[jsii.Number] = None,
13803
+ role: typing.Optional[_IRole_235f5d8e] = None,
13804
+ action_name: builtins.str,
13805
+ run_order: typing.Optional[jsii.Number] = None,
13806
+ variables_namespace: typing.Optional[builtins.str] = None,
13807
+ ) -> None:
13808
+ '''
13809
+ :param repository: The Amazon ECR repository where the image is pushed.
13810
+ :param image_tag: The tag used for the image. Default: 'latest'
13811
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
13812
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13813
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13814
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13815
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13816
+ :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
13817
+ :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
13818
+ :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
13819
+ :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
13820
+ '''
13821
+ props = InspectorEcrImageScanActionProps(
13822
+ repository=repository,
13823
+ image_tag=image_tag,
13824
+ output=output,
13825
+ critical_threshold=critical_threshold,
13826
+ high_threshold=high_threshold,
13827
+ low_threshold=low_threshold,
13828
+ medium_threshold=medium_threshold,
13829
+ role=role,
13830
+ action_name=action_name,
13831
+ run_order=run_order,
13832
+ variables_namespace=variables_namespace,
13833
+ )
13834
+
13835
+ jsii.create(self.__class__, self, [props])
13836
+
13837
+ @jsii.member(jsii_name="bound")
13838
+ def _bound(
13839
+ self,
13840
+ scope: _constructs_77d1e7e8.Construct,
13841
+ stage: _IStage_415fc571,
13842
+ *,
13843
+ bucket: _IBucket_42e086fd,
13844
+ role: _IRole_235f5d8e,
13845
+ ) -> _ActionConfig_846fc217:
13846
+ '''This is a renamed version of the ``IAction.bind`` method.
13847
+
13848
+ :param scope: -
13849
+ :param stage: -
13850
+ :param bucket:
13851
+ :param role:
13852
+ '''
13853
+ if __debug__:
13854
+ type_hints = typing.get_type_hints(_typecheckingstub__b9417731b05c3a732c5ac482215baf762edbfe9d6dfefcdf5bb578bb5c2ca37f)
13855
+ check_type(argname="argument scope", value=scope, expected_type=type_hints["scope"])
13856
+ check_type(argname="argument stage", value=stage, expected_type=type_hints["stage"])
13857
+ options = _ActionBindOptions_3a612254(bucket=bucket, role=role)
13858
+
13859
+ return typing.cast(_ActionConfig_846fc217, jsii.invoke(self, "bound", [scope, stage, options]))
13860
+
13861
+ @jsii.member(jsii_name="renderActionConfiguration")
13862
+ def _render_action_configuration(self) -> typing.Mapping[builtins.str, typing.Any]:
13863
+ return typing.cast(typing.Mapping[builtins.str, typing.Any], jsii.invoke(self, "renderActionConfiguration", []))
13864
+
13865
+
12140
13866
  @jsii.data_type(
12141
- jsii_type="aws-cdk-lib.aws_codepipeline_actions.CloudFormationDeployStackSetActionProps",
12142
- jsii_struct_bases=[
12143
- _CommonAwsActionProps_8b809bb6, CommonCloudFormationStackSetOptions
12144
- ],
13867
+ jsii_type="aws-cdk-lib.aws_codepipeline_actions.InspectorEcrImageScanActionProps",
13868
+ jsii_struct_bases=[InspectorScanActionBaseProps],
12145
13869
  name_mapping={
12146
13870
  "action_name": "actionName",
12147
13871
  "run_order": "runOrder",
12148
13872
  "variables_namespace": "variablesNamespace",
12149
13873
  "role": "role",
12150
- "failure_tolerance_percentage": "failureTolerancePercentage",
12151
- "max_account_concurrency_percentage": "maxAccountConcurrencyPercentage",
12152
- "stack_set_region": "stackSetRegion",
12153
- "stack_set_name": "stackSetName",
12154
- "template": "template",
12155
- "cfn_capabilities": "cfnCapabilities",
12156
- "deployment_model": "deploymentModel",
12157
- "description": "description",
12158
- "parameters": "parameters",
12159
- "stack_instances": "stackInstances",
13874
+ "output": "output",
13875
+ "critical_threshold": "criticalThreshold",
13876
+ "high_threshold": "highThreshold",
13877
+ "low_threshold": "lowThreshold",
13878
+ "medium_threshold": "mediumThreshold",
13879
+ "repository": "repository",
13880
+ "image_tag": "imageTag",
12160
13881
  },
12161
13882
  )
12162
- class CloudFormationDeployStackSetActionProps(
12163
- _CommonAwsActionProps_8b809bb6,
12164
- CommonCloudFormationStackSetOptions,
12165
- ):
13883
+ class InspectorEcrImageScanActionProps(InspectorScanActionBaseProps):
12166
13884
  def __init__(
12167
13885
  self,
12168
13886
  *,
@@ -12170,88 +13888,67 @@ class CloudFormationDeployStackSetActionProps(
12170
13888
  run_order: typing.Optional[jsii.Number] = None,
12171
13889
  variables_namespace: typing.Optional[builtins.str] = None,
12172
13890
  role: typing.Optional[_IRole_235f5d8e] = None,
12173
- failure_tolerance_percentage: typing.Optional[jsii.Number] = None,
12174
- max_account_concurrency_percentage: typing.Optional[jsii.Number] = None,
12175
- stack_set_region: typing.Optional[builtins.str] = None,
12176
- stack_set_name: builtins.str,
12177
- template: StackSetTemplate,
12178
- cfn_capabilities: typing.Optional[typing.Sequence[_CfnCapabilities_f5c35b06]] = None,
12179
- deployment_model: typing.Optional[StackSetDeploymentModel] = None,
12180
- description: typing.Optional[builtins.str] = None,
12181
- parameters: typing.Optional[StackSetParameters] = None,
12182
- stack_instances: typing.Optional[StackInstances] = None,
13891
+ output: _Artifact_0cb05964,
13892
+ critical_threshold: typing.Optional[jsii.Number] = None,
13893
+ high_threshold: typing.Optional[jsii.Number] = None,
13894
+ low_threshold: typing.Optional[jsii.Number] = None,
13895
+ medium_threshold: typing.Optional[jsii.Number] = None,
13896
+ repository: _IRepository_e6004aa6,
13897
+ image_tag: typing.Optional[builtins.str] = None,
12183
13898
  ) -> None:
12184
- '''Properties for the CloudFormationDeployStackSetAction.
13899
+ '''Construction properties of the ``InspectorEcrImageScanAction``.
12185
13900
 
12186
13901
  :param action_name: The physical, human-readable name of the Action. Note that Action names must be unique within a single Stage.
12187
13902
  :param run_order: The runOrder property for this Action. RunOrder determines the relative order in which multiple Actions in the same Stage execute. Default: 1
12188
13903
  :param variables_namespace: The name of the namespace to use for variables emitted by this action. Default: - a name will be generated, based on the stage and action names, if any of the action's variables were referenced - otherwise, no namespace will be set
12189
13904
  :param role: The Role in which context's this Action will be executing in. The Pipeline's Role will assume this Role (the required permissions for that will be granted automatically) right before executing this Action. This Action will be passed into your ``IAction.bind`` method in the ``ActionBindOptions.role`` property. Default: a new Role will be generated
12190
- :param failure_tolerance_percentage: The percentage of accounts per Region for which this stack operation can fail before AWS CloudFormation stops the operation in that Region. If the operation is stopped in a Region, AWS CloudFormation doesn't attempt the operation in subsequent Regions. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. Default: 0%
12191
- :param max_account_concurrency_percentage: The maximum percentage of accounts in which to perform this operation at one time. When calculating the number of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number. If rounding down would result in zero, AWS CloudFormation sets the number as one instead. Although you use this setting to specify the maximum, for large deployments the actual number of accounts acted upon concurrently may be lower due to service throttling. Default: 1%
12192
- :param stack_set_region: The AWS Region the StackSet is in. Note that a cross-region Pipeline requires replication buckets to function correctly. You can provide their names with the ``PipelineProps.crossRegionReplicationBuckets`` property. If you don't, the CodePipeline Construct will create new Stacks in your CDK app containing those buckets, that you will need to ``cdk deploy`` before deploying the main, Pipeline-containing Stack. Default: - same region as the Pipeline
12193
- :param stack_set_name: The name to associate with the stack set. This name must be unique in the Region where it is created. The name may only contain alphanumeric and hyphen characters. It must begin with an alphabetic character and be 128 characters or fewer.
12194
- :param template: The location of the template that defines the resources in the stack set. This must point to a template with a maximum size of 460,800 bytes. Enter the path to the source artifact name and template file.
12195
- :param cfn_capabilities: Indicates that the template can create and update resources, depending on the types of resources in the template. You must use this property if you have IAM resources in your stack template or you create a stack directly from a template containing macros. Default: - the StackSet will have no IAM capabilities
12196
- :param deployment_model: Determines how IAM roles are created and managed. The choices are: - Self Managed: you create IAM roles with the required permissions in the administration account and all target accounts. - Service Managed: only available if the account and target accounts are part of an AWS Organization. The necessary roles will be created for you. If you want to deploy to all accounts that are a member of AWS Organizations Organizational Units (OUs), you must select Service Managed permissions. Note: This parameter can only be changed when no stack instances exist in the stack set. Default: StackSetDeploymentModel.selfManaged()
12197
- :param description: A description of the stack set. You can use this to describe the stack set’s purpose or other relevant information. Default: - no description
12198
- :param parameters: The template parameters for your stack set. These parameters are shared between all instances of the stack set. Default: - no parameters will be used
12199
- :param stack_instances: Specify where to create or update Stack Instances. You can specify either AWS Accounts Ids or AWS Organizations Organizational Units. Default: - don't create or update any Stack Instances
13905
+ :param output: Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.
13906
+ :param critical_threshold: The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13907
+ :param high_threshold: The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13908
+ :param low_threshold: The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13909
+ :param medium_threshold: The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action. Default: - no threshold
13910
+ :param repository: The Amazon ECR repository where the image is pushed.
13911
+ :param image_tag: The tag used for the image. Default: 'latest'
12200
13912
 
12201
13913
  :exampleMetadata: infused
12202
13914
 
12203
13915
  Example::
12204
13916
 
12205
- # pipeline: codepipeline.Pipeline
12206
- # source_output: codepipeline.Artifact
12207
-
12208
-
12209
- pipeline.add_stage(
12210
- stage_name="DeployStackSets",
12211
- actions=[
12212
- # First, update the StackSet itself with the newest template
12213
- codepipeline_actions.CloudFormationDeployStackSetAction(
12214
- action_name="UpdateStackSet",
12215
- run_order=1,
12216
- stack_set_name="MyStackSet",
12217
- template=codepipeline_actions.StackSetTemplate.from_artifact_path(source_output.at_path("template.yaml")),
12218
-
12219
- # Change this to 'StackSetDeploymentModel.organizations()' if you want to deploy to OUs
12220
- deployment_model=codepipeline_actions.StackSetDeploymentModel.self_managed(),
12221
- # This deploys to a set of accounts
12222
- stack_instances=codepipeline_actions.StackInstances.in_accounts(["111111111111"], ["us-east-1", "eu-west-1"])
12223
- ),
13917
+ import aws_cdk.aws_ecr as ecr
12224
13918
 
12225
- # Afterwards, update/create additional instances in other accounts
12226
- codepipeline_actions.CloudFormationDeployStackInstancesAction(
12227
- action_name="AddMoreInstances",
12228
- run_order=2,
12229
- stack_set_name="MyStackSet",
12230
- stack_instances=codepipeline_actions.StackInstances.in_accounts(["222222222222", "333333333333"], ["us-east-1", "eu-west-1"])
12231
- )
12232
- ]
13919
+ # pipeline: codepipeline.Pipeline
13920
+ # repository: ecr.IRepository
13921
+
13922
+
13923
+ scan_output = codepipeline.Artifact()
13924
+ scan_action = codepipeline_actions.InspectorEcrImageScanAction(
13925
+ action_name="InspectorEcrImageScanAction",
13926
+ output=scan_output,
13927
+ repository=repository
13928
+ )
13929
+
13930
+ pipeline.add_stage(
13931
+ stage_name="Scan",
13932
+ actions=[scan_action]
12233
13933
  )
12234
13934
  '''
12235
13935
  if __debug__:
12236
- type_hints = typing.get_type_hints(_typecheckingstub__ee2cef6462ecd2f50e6747ca0f4c5443f4167fadcb9b523b71950626de829059)
13936
+ type_hints = typing.get_type_hints(_typecheckingstub__6a7982da431d6fa0bd0f4dcdb140e96377e641305c9d377e566f656cfce34443)
12237
13937
  check_type(argname="argument action_name", value=action_name, expected_type=type_hints["action_name"])
12238
13938
  check_type(argname="argument run_order", value=run_order, expected_type=type_hints["run_order"])
12239
13939
  check_type(argname="argument variables_namespace", value=variables_namespace, expected_type=type_hints["variables_namespace"])
12240
13940
  check_type(argname="argument role", value=role, expected_type=type_hints["role"])
12241
- check_type(argname="argument failure_tolerance_percentage", value=failure_tolerance_percentage, expected_type=type_hints["failure_tolerance_percentage"])
12242
- check_type(argname="argument max_account_concurrency_percentage", value=max_account_concurrency_percentage, expected_type=type_hints["max_account_concurrency_percentage"])
12243
- check_type(argname="argument stack_set_region", value=stack_set_region, expected_type=type_hints["stack_set_region"])
12244
- check_type(argname="argument stack_set_name", value=stack_set_name, expected_type=type_hints["stack_set_name"])
12245
- check_type(argname="argument template", value=template, expected_type=type_hints["template"])
12246
- check_type(argname="argument cfn_capabilities", value=cfn_capabilities, expected_type=type_hints["cfn_capabilities"])
12247
- check_type(argname="argument deployment_model", value=deployment_model, expected_type=type_hints["deployment_model"])
12248
- check_type(argname="argument description", value=description, expected_type=type_hints["description"])
12249
- check_type(argname="argument parameters", value=parameters, expected_type=type_hints["parameters"])
12250
- check_type(argname="argument stack_instances", value=stack_instances, expected_type=type_hints["stack_instances"])
13941
+ check_type(argname="argument output", value=output, expected_type=type_hints["output"])
13942
+ check_type(argname="argument critical_threshold", value=critical_threshold, expected_type=type_hints["critical_threshold"])
13943
+ check_type(argname="argument high_threshold", value=high_threshold, expected_type=type_hints["high_threshold"])
13944
+ check_type(argname="argument low_threshold", value=low_threshold, expected_type=type_hints["low_threshold"])
13945
+ check_type(argname="argument medium_threshold", value=medium_threshold, expected_type=type_hints["medium_threshold"])
13946
+ check_type(argname="argument repository", value=repository, expected_type=type_hints["repository"])
13947
+ check_type(argname="argument image_tag", value=image_tag, expected_type=type_hints["image_tag"])
12251
13948
  self._values: typing.Dict[builtins.str, typing.Any] = {
12252
13949
  "action_name": action_name,
12253
- "stack_set_name": stack_set_name,
12254
- "template": template,
13950
+ "output": output,
13951
+ "repository": repository,
12255
13952
  }
12256
13953
  if run_order is not None:
12257
13954
  self._values["run_order"] = run_order
@@ -12259,22 +13956,16 @@ class CloudFormationDeployStackSetActionProps(
12259
13956
  self._values["variables_namespace"] = variables_namespace
12260
13957
  if role is not None:
12261
13958
  self._values["role"] = role
12262
- if failure_tolerance_percentage is not None:
12263
- self._values["failure_tolerance_percentage"] = failure_tolerance_percentage
12264
- if max_account_concurrency_percentage is not None:
12265
- self._values["max_account_concurrency_percentage"] = max_account_concurrency_percentage
12266
- if stack_set_region is not None:
12267
- self._values["stack_set_region"] = stack_set_region
12268
- if cfn_capabilities is not None:
12269
- self._values["cfn_capabilities"] = cfn_capabilities
12270
- if deployment_model is not None:
12271
- self._values["deployment_model"] = deployment_model
12272
- if description is not None:
12273
- self._values["description"] = description
12274
- if parameters is not None:
12275
- self._values["parameters"] = parameters
12276
- if stack_instances is not None:
12277
- self._values["stack_instances"] = stack_instances
13959
+ if critical_threshold is not None:
13960
+ self._values["critical_threshold"] = critical_threshold
13961
+ if high_threshold is not None:
13962
+ self._values["high_threshold"] = high_threshold
13963
+ if low_threshold is not None:
13964
+ self._values["low_threshold"] = low_threshold
13965
+ if medium_threshold is not None:
13966
+ self._values["medium_threshold"] = medium_threshold
13967
+ if image_tag is not None:
13968
+ self._values["image_tag"] = image_tag
12278
13969
 
12279
13970
  @builtins.property
12280
13971
  def action_name(self) -> builtins.str:
@@ -12328,140 +14019,64 @@ class CloudFormationDeployStackSetActionProps(
12328
14019
  return typing.cast(typing.Optional[_IRole_235f5d8e], result)
12329
14020
 
12330
14021
  @builtins.property
12331
- def failure_tolerance_percentage(self) -> typing.Optional[jsii.Number]:
12332
- '''The percentage of accounts per Region for which this stack operation can fail before AWS CloudFormation stops the operation in that Region.
12333
-
12334
- If
12335
- the operation is stopped in a Region, AWS CloudFormation doesn't attempt the operation in subsequent Regions. When calculating the number
12336
- of accounts based on the specified percentage, AWS CloudFormation rounds down to the next whole number.
12337
-
12338
- :default: 0%
12339
- '''
12340
- result = self._values.get("failure_tolerance_percentage")
12341
- return typing.cast(typing.Optional[jsii.Number], result)
14022
+ def output(self) -> _Artifact_0cb05964:
14023
+ '''Vulnerability details of your source in the form of a Software Bill of Materials (SBOM) file.'''
14024
+ result = self._values.get("output")
14025
+ assert result is not None, "Required property 'output' is missing"
14026
+ return typing.cast(_Artifact_0cb05964, result)
12342
14027
 
12343
14028
  @builtins.property
12344
- def max_account_concurrency_percentage(self) -> typing.Optional[jsii.Number]:
12345
- '''The maximum percentage of accounts in which to perform this operation at one time.
12346
-
12347
- When calculating the number of accounts based on the specified
12348
- percentage, AWS CloudFormation rounds down to the next whole number. If rounding down would result in zero, AWS CloudFormation sets the number as
12349
- one instead. Although you use this setting to specify the maximum, for large deployments the actual number of accounts acted upon concurrently
12350
- may be lower due to service throttling.
14029
+ def critical_threshold(self) -> typing.Optional[jsii.Number]:
14030
+ '''The number of critical severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
12351
14031
 
12352
- :default: 1%
14032
+ :default: - no threshold
12353
14033
  '''
12354
- result = self._values.get("max_account_concurrency_percentage")
14034
+ result = self._values.get("critical_threshold")
12355
14035
  return typing.cast(typing.Optional[jsii.Number], result)
12356
14036
 
12357
14037
  @builtins.property
12358
- def stack_set_region(self) -> typing.Optional[builtins.str]:
12359
- '''The AWS Region the StackSet is in.
12360
-
12361
- Note that a cross-region Pipeline requires replication buckets to function correctly.
12362
- You can provide their names with the ``PipelineProps.crossRegionReplicationBuckets`` property.
12363
- If you don't, the CodePipeline Construct will create new Stacks in your CDK app containing those buckets,
12364
- that you will need to ``cdk deploy`` before deploying the main, Pipeline-containing Stack.
12365
-
12366
- :default: - same region as the Pipeline
12367
- '''
12368
- result = self._values.get("stack_set_region")
12369
- return typing.cast(typing.Optional[builtins.str], result)
12370
-
12371
- @builtins.property
12372
- def stack_set_name(self) -> builtins.str:
12373
- '''The name to associate with the stack set.
12374
-
12375
- This name must be unique in the Region where it is created.
14038
+ def high_threshold(self) -> typing.Optional[jsii.Number]:
14039
+ '''The number of high severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
12376
14040
 
12377
- The name may only contain alphanumeric and hyphen characters. It must begin with an alphabetic character and be 128 characters or fewer.
14041
+ :default: - no threshold
12378
14042
  '''
12379
- result = self._values.get("stack_set_name")
12380
- assert result is not None, "Required property 'stack_set_name' is missing"
12381
- return typing.cast(builtins.str, result)
14043
+ result = self._values.get("high_threshold")
14044
+ return typing.cast(typing.Optional[jsii.Number], result)
12382
14045
 
12383
14046
  @builtins.property
12384
- def template(self) -> StackSetTemplate:
12385
- '''The location of the template that defines the resources in the stack set.
12386
-
12387
- This must point to a template with a maximum size of 460,800 bytes.
14047
+ def low_threshold(self) -> typing.Optional[jsii.Number]:
14048
+ '''The number of low severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
12388
14049
 
12389
- Enter the path to the source artifact name and template file.
14050
+ :default: - no threshold
12390
14051
  '''
12391
- result = self._values.get("template")
12392
- assert result is not None, "Required property 'template' is missing"
12393
- return typing.cast(StackSetTemplate, result)
14052
+ result = self._values.get("low_threshold")
14053
+ return typing.cast(typing.Optional[jsii.Number], result)
12394
14054
 
12395
14055
  @builtins.property
12396
- def cfn_capabilities(
12397
- self,
12398
- ) -> typing.Optional[typing.List[_CfnCapabilities_f5c35b06]]:
12399
- '''Indicates that the template can create and update resources, depending on the types of resources in the template.
12400
-
12401
- You must use this property if you have IAM resources in your stack template or you create a stack directly from a template containing macros.
14056
+ def medium_threshold(self) -> typing.Optional[jsii.Number]:
14057
+ '''The number of medium severity vulnerabilities found in your source beyond which CodePipeline should fail the action.
12402
14058
 
12403
- :default: - the StackSet will have no IAM capabilities
14059
+ :default: - no threshold
12404
14060
  '''
12405
- result = self._values.get("cfn_capabilities")
12406
- return typing.cast(typing.Optional[typing.List[_CfnCapabilities_f5c35b06]], result)
14061
+ result = self._values.get("medium_threshold")
14062
+ return typing.cast(typing.Optional[jsii.Number], result)
12407
14063
 
12408
14064
  @builtins.property
12409
- def deployment_model(self) -> typing.Optional[StackSetDeploymentModel]:
12410
- '''Determines how IAM roles are created and managed.
12411
-
12412
- The choices are:
12413
-
12414
- - Self Managed: you create IAM roles with the required permissions
12415
- in the administration account and all target accounts.
12416
- - Service Managed: only available if the account and target accounts
12417
- are part of an AWS Organization. The necessary roles will be created
12418
- for you.
12419
-
12420
- If you want to deploy to all accounts that are a member of AWS
12421
- Organizations Organizational Units (OUs), you must select Service Managed
12422
- permissions.
12423
-
12424
- Note: This parameter can only be changed when no stack instances exist in
12425
- the stack set.
12426
-
12427
- :default: StackSetDeploymentModel.selfManaged()
12428
- '''
12429
- result = self._values.get("deployment_model")
12430
- return typing.cast(typing.Optional[StackSetDeploymentModel], result)
14065
+ def repository(self) -> _IRepository_e6004aa6:
14066
+ '''The Amazon ECR repository where the image is pushed.'''
14067
+ result = self._values.get("repository")
14068
+ assert result is not None, "Required property 'repository' is missing"
14069
+ return typing.cast(_IRepository_e6004aa6, result)
12431
14070
 
12432
14071
  @builtins.property
12433
- def description(self) -> typing.Optional[builtins.str]:
12434
- '''A description of the stack set.
12435
-
12436
- You can use this to describe the stack set’s purpose or other relevant information.
14072
+ def image_tag(self) -> typing.Optional[builtins.str]:
14073
+ '''The tag used for the image.
12437
14074
 
12438
- :default: - no description
14075
+ :default: 'latest'
12439
14076
  '''
12440
- result = self._values.get("description")
14077
+ result = self._values.get("image_tag")
12441
14078
  return typing.cast(typing.Optional[builtins.str], result)
12442
14079
 
12443
- @builtins.property
12444
- def parameters(self) -> typing.Optional[StackSetParameters]:
12445
- '''The template parameters for your stack set.
12446
-
12447
- These parameters are shared between all instances of the stack set.
12448
-
12449
- :default: - no parameters will be used
12450
- '''
12451
- result = self._values.get("parameters")
12452
- return typing.cast(typing.Optional[StackSetParameters], result)
12453
-
12454
- @builtins.property
12455
- def stack_instances(self) -> typing.Optional[StackInstances]:
12456
- '''Specify where to create or update Stack Instances.
12457
-
12458
- You can specify either AWS Accounts Ids or AWS Organizations Organizational Units.
12459
-
12460
- :default: - don't create or update any Stack Instances
12461
- '''
12462
- result = self._values.get("stack_instances")
12463
- return typing.cast(typing.Optional[StackInstances], result)
12464
-
12465
14080
  def __eq__(self, rhs: typing.Any) -> builtins.bool:
12466
14081
  return isinstance(rhs, self.__class__) and rhs._values == self._values
12467
14082
 
@@ -12469,7 +14084,7 @@ class CloudFormationDeployStackSetActionProps(
12469
14084
  return not (rhs == self)
12470
14085
 
12471
14086
  def __repr__(self) -> str:
12472
- return "CloudFormationDeployStackSetActionProps(%s)" % ", ".join(
14087
+ return "InspectorEcrImageScanActionProps(%s)" % ", ".join(
12473
14088
  k + "=" + repr(v) for k, v in self._values.items()
12474
14089
  )
12475
14090
 
@@ -12605,6 +14220,9 @@ __all__ = [
12605
14220
  "CommandsAction",
12606
14221
  "CommandsActionProps",
12607
14222
  "CommonCloudFormationStackSetOptions",
14223
+ "EcrBuildAndPublishAction",
14224
+ "EcrBuildAndPublishActionProps",
14225
+ "EcrBuildAndPublishVariables",
12608
14226
  "EcrSourceAction",
12609
14227
  "EcrSourceActionProps",
12610
14228
  "EcrSourceVariables",
@@ -12618,6 +14236,13 @@ __all__ = [
12618
14236
  "GitHubTrigger",
12619
14237
  "ICustomEventRule",
12620
14238
  "IJenkinsProvider",
14239
+ "InspectorEcrImageScanAction",
14240
+ "InspectorEcrImageScanActionProps",
14241
+ "InspectorScanActionBase",
14242
+ "InspectorScanActionBaseProps",
14243
+ "InspectorScanVariables",
14244
+ "InspectorSourceCodeScanAction",
14245
+ "InspectorSourceCodeScanActionProps",
12621
14246
  "JenkinsAction",
12622
14247
  "JenkinsActionProps",
12623
14248
  "JenkinsActionType",
@@ -12629,6 +14254,7 @@ __all__ = [
12629
14254
  "ManualApprovalAction",
12630
14255
  "ManualApprovalActionProps",
12631
14256
  "OrganizationsDeploymentProps",
14257
+ "RegistryType",
12632
14258
  "S3DeployAction",
12633
14259
  "S3DeployActionProps",
12634
14260
  "S3SourceAction",
@@ -13081,6 +14707,39 @@ def _typecheckingstub__2410584584bdbc5570942e28fb48b74fa12d17853f6fde7bdcddfd923
13081
14707
  """Type checking stubs"""
13082
14708
  pass
13083
14709
 
14710
+ def _typecheckingstub__29d16187e06f9d23101e6955f383d38368a5309fb4f73cf04c52e7a739830b33(
14711
+ scope: _constructs_77d1e7e8.Construct,
14712
+ stage: _IStage_415fc571,
14713
+ *,
14714
+ bucket: _IBucket_42e086fd,
14715
+ role: _IRole_235f5d8e,
14716
+ ) -> None:
14717
+ """Type checking stubs"""
14718
+ pass
14719
+
14720
+ def _typecheckingstub__1b13d08d881a39c394898fc7c83d74e8f65d5c1bdabde058e6bb0d10e57ec00f(
14721
+ *,
14722
+ action_name: builtins.str,
14723
+ run_order: typing.Optional[jsii.Number] = None,
14724
+ variables_namespace: typing.Optional[builtins.str] = None,
14725
+ role: typing.Optional[_IRole_235f5d8e] = None,
14726
+ input: _Artifact_0cb05964,
14727
+ repository_name: builtins.str,
14728
+ dockerfile_directory_path: typing.Optional[builtins.str] = None,
14729
+ image_tags: typing.Optional[typing.Sequence[builtins.str]] = None,
14730
+ registry_type: typing.Optional[RegistryType] = None,
14731
+ ) -> None:
14732
+ """Type checking stubs"""
14733
+ pass
14734
+
14735
+ def _typecheckingstub__91516fa8ca0077d312e46c891a6812f3570330144844a5f751633dbd6d3cdef7(
14736
+ *,
14737
+ ecr_image_digest_id: builtins.str,
14738
+ ecr_repository_name: builtins.str,
14739
+ ) -> None:
14740
+ """Type checking stubs"""
14741
+ pass
14742
+
13084
14743
  def _typecheckingstub__d95f17ce1dc91ce862a33fcb114ba70ca493fdcf80aba4bd2b33da0283823b94(
13085
14744
  scope: _constructs_77d1e7e8.Construct,
13086
14745
  stage: _IStage_415fc571,
@@ -13200,6 +14859,64 @@ def _typecheckingstub__d36a66e26e764b2c204da0bcf323302f95847c475cba80cedc642606a
13200
14859
  """Type checking stubs"""
13201
14860
  pass
13202
14861
 
14862
+ def _typecheckingstub__e14024ba1588c13bad01352500e04cd20ed7cde863ea927e167b0fbe92c82ecd(
14863
+ scope: _constructs_77d1e7e8.Construct,
14864
+ stage: _IStage_415fc571,
14865
+ *,
14866
+ bucket: _IBucket_42e086fd,
14867
+ role: _IRole_235f5d8e,
14868
+ ) -> None:
14869
+ """Type checking stubs"""
14870
+ pass
14871
+
14872
+ def _typecheckingstub__6da783895b7ba6899d69141e306683f07acbbde47f1425f850879dc762f2e644(
14873
+ *,
14874
+ action_name: builtins.str,
14875
+ run_order: typing.Optional[jsii.Number] = None,
14876
+ variables_namespace: typing.Optional[builtins.str] = None,
14877
+ role: typing.Optional[_IRole_235f5d8e] = None,
14878
+ output: _Artifact_0cb05964,
14879
+ critical_threshold: typing.Optional[jsii.Number] = None,
14880
+ high_threshold: typing.Optional[jsii.Number] = None,
14881
+ low_threshold: typing.Optional[jsii.Number] = None,
14882
+ medium_threshold: typing.Optional[jsii.Number] = None,
14883
+ ) -> None:
14884
+ """Type checking stubs"""
14885
+ pass
14886
+
14887
+ def _typecheckingstub__8a48c3b3b3e2cfc1dcf7a2e04c2e32728ebe17a3f38a9cad1bada36d22fe6a24(
14888
+ *,
14889
+ highest_scanned_severity: builtins.str,
14890
+ ) -> None:
14891
+ """Type checking stubs"""
14892
+ pass
14893
+
14894
+ def _typecheckingstub__45cb7f03b6f947f8e3545d0c1c5e5d7b428fd0bbe2dec88db250699b2fba4ec2(
14895
+ scope: _constructs_77d1e7e8.Construct,
14896
+ stage: _IStage_415fc571,
14897
+ *,
14898
+ bucket: _IBucket_42e086fd,
14899
+ role: _IRole_235f5d8e,
14900
+ ) -> None:
14901
+ """Type checking stubs"""
14902
+ pass
14903
+
14904
+ def _typecheckingstub__b15e4f7143687072e838007e65ae09dfa2481ef37d0679cc1fe389ce6997a557(
14905
+ *,
14906
+ action_name: builtins.str,
14907
+ run_order: typing.Optional[jsii.Number] = None,
14908
+ variables_namespace: typing.Optional[builtins.str] = None,
14909
+ role: typing.Optional[_IRole_235f5d8e] = None,
14910
+ output: _Artifact_0cb05964,
14911
+ critical_threshold: typing.Optional[jsii.Number] = None,
14912
+ high_threshold: typing.Optional[jsii.Number] = None,
14913
+ low_threshold: typing.Optional[jsii.Number] = None,
14914
+ medium_threshold: typing.Optional[jsii.Number] = None,
14915
+ input: _Artifact_0cb05964,
14916
+ ) -> None:
14917
+ """Type checking stubs"""
14918
+ pass
14919
+
13203
14920
  def _typecheckingstub__f08ae51a4cf2b1bfb9e531ba516d1aea22c51dd0dac157890193226f4ae1269b(
13204
14921
  _scope: _constructs_77d1e7e8.Construct,
13205
14922
  _stage: _IStage_415fc571,
@@ -13524,6 +15241,33 @@ def _typecheckingstub__ee2cef6462ecd2f50e6747ca0f4c5443f4167fadcb9b523b71950626d
13524
15241
  """Type checking stubs"""
13525
15242
  pass
13526
15243
 
15244
+ def _typecheckingstub__b9417731b05c3a732c5ac482215baf762edbfe9d6dfefcdf5bb578bb5c2ca37f(
15245
+ scope: _constructs_77d1e7e8.Construct,
15246
+ stage: _IStage_415fc571,
15247
+ *,
15248
+ bucket: _IBucket_42e086fd,
15249
+ role: _IRole_235f5d8e,
15250
+ ) -> None:
15251
+ """Type checking stubs"""
15252
+ pass
15253
+
15254
+ def _typecheckingstub__6a7982da431d6fa0bd0f4dcdb140e96377e641305c9d377e566f656cfce34443(
15255
+ *,
15256
+ action_name: builtins.str,
15257
+ run_order: typing.Optional[jsii.Number] = None,
15258
+ variables_namespace: typing.Optional[builtins.str] = None,
15259
+ role: typing.Optional[_IRole_235f5d8e] = None,
15260
+ output: _Artifact_0cb05964,
15261
+ critical_threshold: typing.Optional[jsii.Number] = None,
15262
+ high_threshold: typing.Optional[jsii.Number] = None,
15263
+ low_threshold: typing.Optional[jsii.Number] = None,
15264
+ medium_threshold: typing.Optional[jsii.Number] = None,
15265
+ repository: _IRepository_e6004aa6,
15266
+ image_tag: typing.Optional[builtins.str] = None,
15267
+ ) -> None:
15268
+ """Type checking stubs"""
15269
+ pass
15270
+
13527
15271
  def _typecheckingstub__74d249a9cbff04d8fc99bef3b5dbad3dd843fa3f7fa6ed1b04089cc0913ba631(
13528
15272
  scope: _constructs_77d1e7e8.Construct,
13529
15273
  id: builtins.str,