From 01dcd4e95e8b4c14309d12dd86d49ccf35177aa1 Mon Sep 17 00:00:00 2001 From: Michael Sambol Date: Tue, 12 Sep 2023 18:11:42 -0500 Subject: [PATCH 1/7] fix(aws-codepipeline-actions): update zip to noncorrupted one --- .../test/assets/nodejs.zip | Bin 4928 -> 3092 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/assets/nodejs.zip b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/assets/nodejs.zip index e8db142cdf85d7fbbfaca296005556392754e1f7..4810a50d131d9dbf56c6a43f1c11887031ce794b 100644 GIT binary patch literal 3092 zcma);c{G&!AIBfY%-ESij8d|cHA5vL!eH!)D22fo!!TpZATqhg9V1!el8j`@Hb~YY zp%kJtSx2%|whC9`>NoDar>pDM`JLx{pYuHbyuPpVdCvF!ysb<@96|s9Z~{qJsaB6& za#Wyf05Hc|BEU`nsdp0XO~hl46NyR|1UHPQzcS7nZ)?K^fFS%Sjtcszj)5c|fQ^H{ z#(xLL(@>Ca*i}nY5JKqT{2xM+i*<(0k&k?MdQ0}7i|QStKkW44b6-eJyIIW~nPKiV zCXiRm-DOcz`5om_3C}&$!h`&uh`rjDQXLaVP=7K`?#3on=?U|yTr8D*vwP)vDai?M zr*YqYeg*%){)~%lE_gaU#nvs`H%|wZ2w||png@)G%Al%|f-=zXBTh}Z2PG3jy+==6 z#-%klG!*A&#`ee?667^q2aV#Q)=QQlI>@8m)VDmi3AW2>-uEM_Ea95BtS>b)nz2JC zBhZjclkGx_1J9&o?U_TnW6sTI?v=YS6r#C2KhS_IW+~u&+%P0%kAS}&-2dC5&#pOs@UURxvcfF~ zp+*C1d>KslgiXx|@&FRPhfPF7tjZV_CuhB!rpK$@{F$@|pXjYj{gy0n}s8S&^EmA@0->ZWqPwQFX(cbc3110_NMSxM2aW zh!R@pXA%i`lx(FLo$a?AqA}nv+eN!ZFd19Luxzk3?GeEmTF8*xurEF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-elastic-beanstalk-deploy.assets.json | 10 +- ...ine-elastic-beanstalk-deploy.template.json | 2 +- .../manifest.json | 2 +- ...7a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip | Bin 0 -> 4540 bytes ...e782b91873a033a2af81afb07f38cf38ec67ea.zip | Bin 0 -> 310 bytes packages/@aws-cdk/aws-batch-alpha/.jsii | 15284 ++++++++++++++++ .../aws-batch-alpha/.warnings.jsii.js | 515 + .../lib/compute-environment-base.d.ts | 87 + .../lib/compute-environment-base.js | 20 + .../lib/ecs-container-definition.d.ts | 726 + .../lib/ecs-container-definition.js | 531 + .../lib/ecs-job-definition.d.ts | 67 + .../aws-batch-alpha/lib/ecs-job-definition.js | 102 + .../lib/eks-container-definition.d.ts | 728 + .../lib/eks-container-definition.js | 338 + .../lib/eks-job-definition.d.ts | 123 + .../aws-batch-alpha/lib/eks-job-definition.js | 134 + .../@aws-cdk/aws-batch-alpha/lib/index.d.ts | 12 + .../@aws-cdk/aws-batch-alpha/lib/index.js | 29 + .../lib/job-definition-base.d.ts | 217 + .../lib/job-definition-base.js | 153 + .../aws-batch-alpha/lib/job-queue.d.ts | 140 + .../@aws-cdk/aws-batch-alpha/lib/job-queue.js | 102 + .../aws-batch-alpha/lib/linux-parameters.d.ts | 196 + .../aws-batch-alpha/lib/linux-parameters.js | 175 + .../lib/managed-compute-environment.d.ts | 806 + .../lib/managed-compute-environment.js | 451 + .../lib/multinode-job-definition.d.ts | 107 + .../lib/multinode-job-definition.js | 104 + .../lib/scheduling-policy.d.ts | 188 + .../aws-batch-alpha/lib/scheduling-policy.js | 101 + .../lib/unmanaged-compute-environment.d.ts | 47 + .../lib/unmanaged-compute-environment.js | 70 + .../test/aws-events-targets/batch.test.d.ts | 1 + .../test/aws-events-targets/batch.test.js | 294 + .../run-batch-job.test.d.ts | 1 + .../run-batch-job.test.js | 286 + .../submit-job.test.d.ts | 1 + .../submit-job.test.js | 401 + .../test/ecs-container-definition.test.d.ts | 1 + .../test/ecs-container-definition.test.js | 998 + .../test/ecs-job-definition.test.d.ts | 1 + .../test/ecs-job-definition.test.js | 147 + .../test/eks-container-definition.test.d.ts | 1 + .../test/eks-container-definition.test.js | 712 + .../test/eks-job-definition.test.d.ts | 1 + .../test/eks-job-definition.test.js | 72 + .../test/integ.batch-unique-name.d.ts | 1 + .../test/integ.batch-unique-name.js | 34 + .../test/integ.ecs-job-definition.d.ts | 1 + .../test/integ.ecs-job-definition.js | 94 + .../test/integ.eks-job-definition.d.ts | 1 + .../test/integ.eks-job-definition.js | 59 + .../aws-batch-alpha/test/integ.grants.d.ts | 1 + .../aws-batch-alpha/test/integ.grants.js | 35 + .../aws-batch-alpha/test/integ.job-queue.d.ts | 1 + .../aws-batch-alpha/test/integ.job-queue.js | 41 + .../integ.managed-compute-environment.d.ts | 1 + .../test/integ.managed-compute-environment.js | 78 + .../test/integ.multinode-job-definition.d.ts | 1 + .../test/integ.multinode-job-definition.js | 48 + .../integ.unmanaged-compute-environment.d.ts | 1 + .../integ.unmanaged-compute-environment.js | 25 + .../test/job-definition-base.test.d.ts | 1 + .../test/job-definition-base.test.js | 205 + .../aws-batch-alpha/test/job-queue.test.d.ts | 1 + .../aws-batch-alpha/test/job-queue.test.js | 228 + .../managed-compute-environment.test.d.ts | 1 + .../test/managed-compute-environment.test.js | 860 + .../test/multinode-job-definition.test.d.ts | 1 + .../test/multinode-job-definition.test.js | 155 + .../test/scheduling-policy.test.d.ts | 1 + .../test/scheduling-policy.test.js | 133 + .../unmanaged-compute-environment.test.d.ts | 1 + .../unmanaged-compute-environment.test.js | 90 + .../@aws-cdk/aws-batch-alpha/test/utils.d.ts | 6 + .../@aws-cdk/aws-batch-alpha/test/utils.js | 28 + .../@aws-cdk/aws-batch-alpha/tsconfig.json | 53 + .../test/workers/integ-worker.test.ts | 4 +- 79 files changed, 26665 insertions(+), 9 deletions(-) create mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip create mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip create mode 100644 packages/@aws-cdk/aws-batch-alpha/.jsii create mode 100644 packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/index.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts create mode 100644 packages/@aws-cdk/aws-batch-alpha/test/utils.js create mode 100644 packages/@aws-cdk/aws-batch-alpha/tsconfig.json diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json index f385825f1f871..0d246ebffb760 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json @@ -40,20 +40,20 @@ } } }, - "a69ee80d8b447031cda0ebb680c4b77d8ad701ea4b043f241da243fa6e34f9b7": { + "6a9a0507c3e2bfac9749f257bdd3d9f313c01ee3984ad7bf373597c341863d6f": { "source": { - "path": "asset.a69ee80d8b447031cda0ebb680c4b77d8ad701ea4b043f241da243fa6e34f9b7.zip", + "path": "asset.6a9a0507c3e2bfac9749f257bdd3d9f313c01ee3984ad7bf373597c341863d6f.zip", "packaging": "file" }, "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "a69ee80d8b447031cda0ebb680c4b77d8ad701ea4b043f241da243fa6e34f9b7.zip", + "objectKey": "6a9a0507c3e2bfac9749f257bdd3d9f313c01ee3984ad7bf373597c341863d6f.zip", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } }, - "8ef1242d08beb235d6de8a49a1da6b3c01b739b93cb0125ff17f3b68e5984c8e": { + "c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55": { "source": { "path": "aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json", "packaging": "file" @@ -61,7 +61,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "8ef1242d08beb235d6de8a49a1da6b3c01b739b93cb0125ff17f3b68e5984c8e.json", + "objectKey": "c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json index 82b5cf0897a09..3fabf1dc5a284 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json @@ -175,7 +175,7 @@ } ], "SourceObjectKeys": [ - "a69ee80d8b447031cda0ebb680c4b77d8ad701ea4b043f241da243fa6e34f9b7.zip" + "6a9a0507c3e2bfac9749f257bdd3d9f313c01ee3984ad7bf373597c341863d6f.zip" ], "DestinationBucketName": { "Ref": "PipelineBucketB967BD35" diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json index 56c6ce44c290b..169010b153254 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json @@ -17,7 +17,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/8ef1242d08beb235d6de8a49a1da6b3c01b739b93cb0125ff17f3b68e5984c8e.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip b/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip new file mode 100644 index 0000000000000000000000000000000000000000..cb2790cf47f87701182d2d185a3bef4ec4634d2b GIT binary patch literal 4540 zcmV;t5ku}!O9KQH00;mG0000X00000000000000000;m80BLSyWq2-ddBt0AbK5v` zf3Humr6xn_F|Az3ebLd3I+MreJoUtJTs!Vft9m#vxsq_E06qk0S;^(QcNTw0K$ddX z>ooO?NFo=D-Nj<@+r@@&8rf;6~w z*tD`l)xX!cX_mak(Xy2r=-RsGkJA?a-l5XqCc3phb9yZs6ppszm8a-BUj37O{Dm8S z{>^{#<~_0Z5_G8&b&?5bre zg@!p8e$%q%D0G$%uhPj#oxOUm&eF+fbpHOjxVt|;zqq@DIVA3DVxGT$cX@U3Gd;H7 zlF`NWzZV}a{-gN#>Hhk2ar5r;ztY>`*FbUi;qs<9zq)vLeSc#Z2fvfi=-n@O#rf4` zasKK0{pH_^_m@`}MDD)fGGG*$~LWR zu+&#MMaBEKRd zS{aMSu6#mW2)02|!HBjl?Lfj#*{22G1g{<0^-D<&UscVh_C z9MW`H6q?%m2z~c|&XiW83+qHQRJR?b6PVB4*GR7xHRGa?qOe{|%pyj&hTxO<**JBY zLqhx#!_R(=_*Go#mOq-kNnZ1c-_HTTWpzNcPGMVYP_v3@=5&iBx>wkKbnnyHUx{4p zl*UcWAsT;Y2)@IiX*+>#X8#d!xFLeUw9{H{vCWQ|7+=b|t73)`y9-N@=CF8(mzj&- z8G3064h*HROlPJ>p${r?$5-Oqz9&_dtX7y#4(JlC?-(9g`LtzirJ$6XhH3uDYp!>2 zN^vxac2Yv81RW%*!ICdIR{0(?rc}2w2L~PZVrpD-^`)F=_F{GSYcM9$PPrO$s`EO#IM37>uOy@UfwXhhIter z>;~VLm@ILW!xTlO=vd5>w@CmZyc$Ob!U-Xzo4IglKL5Ph|492c9pt)qjmEvLr{*2#0 zhvh0vU2Su>@CihKya7o^%P&Y(keRyaAU>E?ov%#+{kAhKVXmdL@$_5`~&R+*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QfdBvi0BLSyWq2-d ac~DCQ1^@s60096205$*s0B{ii00014ZoSF? literal 0 HcmV?d00001 diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip b/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip new file mode 100644 index 0000000000000000000000000000000000000000..3cf3517aadf3c86fe0b7520aa3a9693e6b601fcd GIT binary patch literal 310 zcmWIWW@Zs#-~d7f21Ou700$t`)Xc=xz|_FN(AXl?Fv-Niz%nH%$uu$1GAY^AFgZEJ zFx4O_*}%ZWB-t#{#MC&+#2_WjJk>PO(A>zx#N5O{ThCWZ@1%~V?#VOfx%E7OjBP<0 zZbFxJ^?d#OboKnS&jvm@<$1=}%d\n\n---\n\n![cdk-constructs: Developer Preview](https://img.shields.io/badge/cdk--constructs-developer--preview-informational.svg?style=for-the-badge)\n\n> The APIs of higher level constructs in this module are in **developer preview** before they\n> become stable. We will only make breaking changes to address unforeseen API issues. Therefore,\n> these APIs are not subject to [Semantic Versioning](https://semver.org/), and breaking changes\n> will be announced in release notes. This means that while you may use them, you may need to\n> update your source code when upgrading to a newer version of this package.\n\n---\n\n\n\nThis module is part of the [AWS Cloud Development Kit](https://github.com/aws/aws-cdk) project.\n\nAWS Batch is a batch processing tool for efficiently running hundreds of thousands computing jobs in AWS.\nBatch can dynamically provision [Amazon EC2](https://aws.amazon.com/ec2/) Instances to meet the resource requirements of submitted jobs\nand simplifies the planning, scheduling, and executions of your batch workloads. Batch achieves this through four different resources:\n\n* ComputeEnvironments: Contain the resources used to execute Jobs\n* JobDefinitions: Define a type of Job that can be submitted\n* JobQueues: Route waiting Jobs to ComputeEnvironments\n* SchedulingPolicies: Applied to Queues to control how and when Jobs exit the JobQueue and enter the ComputeEnvironment\n\n`ComputeEnvironment`s can be managed or unmanaged. Batch will automatically provision EC2 Instances in a managed `ComputeEnvironment` and will\nnot provision any Instances in an unmanaged `ComputeEnvironment`. Managed `ComputeEnvironment`s can use ECS, Fargate, or EKS resources to spin up\nEC2 Instances in (ensure your EKS Cluster has [been configured](https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html)\nto support a Batch ComputeEnvironment before linking it). You can use Launch Templates and Placement Groups to configure exactly how these resources\nwill be provisioned.\n\n`JobDefinition`s can use either ECS resources or EKS resources. ECS `JobDefinition`s can use multiple containers to execute distributed workloads.\nEKS `JobDefinition`s can only execute a single container. Submitted Jobs use `JobDefinition`s as templates.\n\n`JobQueue`s must link at least one `ComputeEnvironment`. Jobs exit the Queue in FIFO order unless a `SchedulingPolicy` is specified.\n\n`SchedulingPolicy`s tell the Scheduler how to choose which Jobs should be executed next by the ComputeEnvironment.\n\n## Use Cases & Examples\n\n### Cost Optimization\n\n#### Spot Instances\n\nSpot instances are significantly discounted EC2 instances that can be reclaimed at any time by AWS.\nWorkloads that are fault-tolerant or stateless can take advantage of spot pricing.\nTo use spot spot instances, set `spot` to `true` on a managed Ec2 or Fargate Compute Environment:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\nnew batch.FargateComputeEnvironment(this, 'myFargateComputeEnv', {\n vpc,\n spot: true,\n});\n```\n\nBatch allows you to specify the percentage of the on-demand instance that the current spot price\nmust be to provision the instance using the `spotBidPercentage`.\nThis defaults to 100%, which is the recommended value.\nThis value cannot be specified for `FargateComputeEnvironment`s\nand only applies to `ManagedEc2EcsComputeEnvironment`s.\nThe following code configures a Compute Environment to only use spot instances that\nare at most 20% the price of the on-demand instance price:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n spot: true,\n spotBidPercentage: 20,\n});\n```\n\nFor stateful or otherwise non-interruption-tolerant workflows, omit `spot` or set it to `false` to only provision on-demand instances.\n\n#### Choosing Your Instance Types\n\nBatch allows you to choose the instance types or classes that will run your workload.\nThis example configures your `ComputeEnvironment` to use only the `M5AD.large` instance:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\n\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE)],\n});\n```\n\nBatch allows you to specify only the instance class and to let it choose the size, which you can do like this:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\n\ndeclare const computeEnv: batch.IManagedEc2EcsComputeEnvironment\ncomputeEnv.addInstanceClass(ec2.InstanceClass.M5AD);\n// Or, specify it on the constructor:\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.R4],\n});\n```\n\nUnless you explicitly specify `useOptimalInstanceClasses: false`, this compute environment will use `'optimal'` instances,\nwhich tells Batch to pick an instance from the C4, M4, and R4 instance families.\n*Note*: Batch does not allow specifying instance types or classes with different architectures.\nFor example, `InstanceClass.A1` cannot be specified alongside `'optimal'`,\nbecause `A1` uses ARM and `'optimal'` uses x86_64.\nYou can specify both `'optimal'` alongside several different instance types in the same compute environment:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE)],\n useOptimalInstanceClasses: true, // default\n vpc,\n});\n// Note: this is equivalent to specifying\ncomputeEnv.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE));\ncomputeEnv.addInstanceClass(ec2.InstanceClass.C4);\ncomputeEnv.addInstanceClass(ec2.InstanceClass.M4);\ncomputeEnv.addInstanceClass(ec2.InstanceClass.R4);\n```\n\n#### Allocation Strategies\n\n| Allocation Strategy | Optimized for | Downsides |\n| ----------------------- | ------------- | ----------------------------- |\n| BEST_FIT | Cost | May limit throughput |\n| BEST_FIT_PROGRESSIVE | Throughput | May increase cost |\n| SPOT_CAPACITY_OPTIMIZED | Least interruption | Only useful on Spot instances |\n| SPOT_PRICE_CAPACITY_OPTIMIZED | Least interruption + Price | Only useful on Spot instances |\n\nBatch provides different Allocation Strategies to help it choose which instances to provision.\nIf your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment`\nand use `SPOT_PRICE_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled).\nThis will tell Batch to choose the instance types from the ones you’ve specified that have\nthe most spot capacity available to minimize the chance of interruption and have the lowest price.\nTo get the most benefit from your spot instances,\nyou should allow Batch to choose from as many different instance types as possible.\nIf you only care about minimal interruptions and not want Batch to optimize for cost, use\n`SPOT_CAPACITY_OPTIMIZED`. `SPOT_PRICE_CAPACITY_OPTIMIZED` is recommended over `SPOT_CAPACITY_OPTIMIZED`\nfor most use cases.\n\nIf your workflow does not tolerate interruptions and you want to minimize your costs at the expense\nof potentially longer waiting times, use `AllocationStrategy.BEST_FIT`.\nThis will choose the lowest-cost instance type that fits all the jobs in the queue.\nIf instances of that type are not available,\nthe queue will not choose a new type; instead, it will wait for the instance to become available.\nThis can stall your `Queue`, with your compute environment only using part of its max capacity\n(or none at all) until the `BEST_FIT` instance becomes available.\n\nIf you are running a workflow that does not tolerate interruptions and you want to maximize throughput,\nyou can use `AllocationStrategy.BEST_FIT_PROGRESSIVE`.\nThis is the default Allocation Strategy if `spot` is `false` or unspecified.\nThis strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements\nof the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`.\nHowever, if not all of the capacity can be filled with this instance type,\nit will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity.\nTo make the most use of this allocation strategy,\nit is recommended to use as many instance classes as is feasible for your workload.\nThis example shows a `ComputeEnvironment` that uses `BEST_FIT_PROGRESSIVE`\nwith `'optimal'` and `InstanceClass.M5` instance types:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.M5],\n});\n```\n\nThis example shows a `ComputeEnvironment` that uses `BEST_FIT` with `'optimal'` instances:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n allocationStrategy: batch.AllocationStrategy.BEST_FIT,\n});\n```\n\n*Note*: `allocationStrategy` cannot be specified on Fargate Compute Environments.\n\n### Controlling vCPU allocation\n\nYou can specify the maximum and minimum vCPUs a managed `ComputeEnvironment` can have at any given time.\nBatch will *always* maintain `minvCpus` worth of instances in your ComputeEnvironment, even if it is not executing any jobs,\nand even if it is disabled. Batch will scale the instances up to `maxvCpus` worth of instances as\njobs exit the JobQueue and enter the ComputeEnvironment. If you use `AllocationStrategy.BEST_FIT_PROGRESSIVE`,\n`AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED`, or `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`,\nbatch may exceed `maxvCpus`; it will never exceed `maxvCpus` by more than a single instance type. This example configures a\n`minvCpus` of 10 and a `maxvCpus` of 100:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.R4],\n minvCpus: 10,\n maxvCpus: 100,\n});\n```\n\n### Tagging Instances\n\nYou can tag any instances launched by your managed EC2 ComputeEnvironments by using the CDK `Tags` API:\n\n```ts\nimport { Tags } from 'aws-cdk-lib';\n\ndeclare const vpc: ec2.IVpc;\n\nconst tagCE = new batch.ManagedEc2EcsComputeEnvironment(this, 'CEThatMakesTaggedInstnaces', {\n vpc,\n});\n\nTags.of(tagCE).add('super', 'salamander');\n```\n\nUnmanaged `ComputeEnvironment`s do not support `maxvCpus` or `minvCpus` because you must provision and manage the instances yourself;\nthat is, Batch will not scale them up and down as needed.\n\n### Sharing a ComputeEnvironment between multiple JobQueues\n\nMultiple `JobQueue`s can share the same `ComputeEnvironment`.\nIf multiple Queues are attempting to submit Jobs to the same `ComputeEnvironment`,\nBatch will pick the Job from the Queue with the highest priority.\nThis example creates two `JobQueue`s that share a `ComputeEnvironment`:\n\n```ts\ndeclare const vpc: ec2.IVpc;\nconst sharedComputeEnv = new batch.FargateComputeEnvironment(this, 'spotEnv', {\n vpc,\n spot: true,\n});\nconst lowPriorityQueue = new batch.JobQueue(this, 'JobQueue', {\n priority: 1,\n});\nconst highPriorityQueue = new batch.JobQueue(this, 'JobQueue', {\n priority: 10,\n});\nlowPriorityQueue.addComputeEnvironment(sharedComputeEnv, 1);\nhighPriorityQueue.addComputeEnvironment(sharedComputeEnv, 1);\n```\n\n### Fairshare Scheduling\n\nBatch `JobQueue`s execute Jobs submitted to them in FIFO order unless you specify a `SchedulingPolicy`.\nFIFO queuing can cause short-running jobs to be starved while long-running jobs fill the compute environment.\nTo solve this, Jobs can be associated with a share.\n\nShares consist of a `shareIdentifier` and a `weightFactor`, which is inversely correlated with the vCPU allocated to that share identifier.\nWhen submitting a Job, you can specify its `shareIdentifier` to associate that particular job with that share.\nLet's see how the scheduler uses this information to schedule jobs.\n\nFor example, if there are two shares defined as follows:\n\n| Share Identifier | Weight Factor |\n| ---------------- | ------------- |\n| A | 1 |\n| B | 1 |\n\nThe weight factors share the following relationship:\n\n```math\nA_{vCpus} / A_{Weight} = B_{vCpus} / B_{Weight}\n```\n\nwhere `BvCpus` is the number of vCPUs allocated to jobs with share identifier `'B'`, and `B_weight` is the weight factor of `B`.\n\nThe total number of vCpus allocated to a share is equal to the amount of jobs in that share times the number of vCpus necessary for every job.\nLet's say that each A job needs 32 VCpus (`A_requirement` = 32) and each B job needs 64 vCpus (`B_requirement` = 64):\n\n```math\nA_{vCpus} = A_{Jobs} * A_{Requirement}\n```\n\n```math\nB_{vCpus} = B_{Jobs} * B_{Requirement}\n```\n\nWe have:\n\n```math\nA_{vCpus} / A_{Weight} = B_{vCpus} / B_{Weight}\n```\n\n```math\nA_{Jobs} * A_{Requirement} / A_{Weight} = B_{Jobs} * B_{Requirement} / B_{Weight}\n```\n\n```math\nA_{Jobs} * 32 / 1 = B_{Jobs} * 64 / 1\n```\n\n```math\nA_{Jobs} * 32 = B_{Jobs} * 64\n```\n\n```math\nA_{Jobs} = B_{Jobs} * 2\n```\n\nThus the scheduler will schedule two `'A'` jobs for each `'B'` job.\n\nYou can control the weight factors to change these ratios, but note that\nweight factors are inversely correlated with the vCpus allocated to the corresponding share.\n\nThis example would be configured like this:\n\n```ts\nconst fairsharePolicy = new batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy');\n\nfairsharePolicy.addShare({\n shareIdentifier: 'A',\n weightFactor: 1,\n});\nfairsharePolicy.addShare({\n shareIdentifier: 'B',\n weightFactor: 1,\n});\nnew batch.JobQueue(this, 'JobQueue', {\n schedulingPolicy: fairsharePolicy,\n});\n```\n\n*Note*: The scheduler will only consider the current usage of the compute environment unless you specify `shareDecay`.\nFor example, a `shareDecay` of 5 minutes in the above example means that at any given point in time, twice as many `'A'` jobs\nwill be scheduled for each `'B'` job, but only for the past 5 minutes. If `'B'` jobs run longer than 5 minutes, then\nthe scheduler is allowed to put more than two `'A'` jobs for each `'B'` job, because the usage of those long-running\n`'B'` jobs will no longer be considered after 5 minutes. `shareDecay` linearly decreases the usage of\nlong running jobs for calculation purposes. For example if share decay is 60 seconds,\nthen jobs that run for 30 seconds have their usage considered to be only 50% of what it actually is,\nbut after a whole minute the scheduler pretends they don't exist for fairness calculations.\n\nThe following code specifies a `shareDecay` of 5 minutes:\n\n```ts\nimport * as cdk from 'aws-cdk-lib'\nconst fairsharePolicy = new batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy', {\n shareDecay: cdk.Duration.minutes(5),\n});\n```\n\nIf you have high priority jobs that should always be executed as soon as they arrive,\nyou can define a `computeReservation` to specify the percentage of the\nmaximum vCPU capacity that should be reserved for shares that are *not in the queue*.\nThe actual reserved percentage is defined by Batch as:\n\n```math\n (\\frac{computeReservation}{100}) ^ {ActiveFairShares}\n```\n\nwhere `ActiveFairShares` is the number of shares for which there exists\nat least one job in the queue with a unique share identifier.\n\nThis is best illustrated with an example.\nSuppose there are three shares with share identifiers `A`, `B` and `C` respectively\nand we specify the `computeReservation` to be 75%. The queue is currently empty,\nand no other shares exist.\n\nThere are no active fair shares, since the queue is empty.\nThus (75/100)^0 = 1 = 100% of the maximum vCpus are reserved for all shares.\n\nA job with identifier `A` enters the queue.\n\nThe number of active fair shares is now 1, hence\n(75/100)^1 = .75 = 75% of the maximum vCpus are reserved for all shares that do not have the identifier `A`;\nfor this example, this is `B` and `C`,\n(but if jobs are submitted with a share identifier not covered by this fairshare policy, those would be considered just as `B` and `C` are).\n\nNow a `B` job enters the queue. The number of active fair shares is now 2,\nso (75/100)^2 = .5625 = 56.25% of the maximum vCpus are reserved for all shares that do not have the identifier `A` or `B`.\n\nNow a second `A` job enters the queue. The number of active fair shares is still 2,\nso the percentage reserved is still 56.25%\n\nNow a `C` job enters the queue. The number of active fair shares is now 3,\nso (75/100)^3 = .421875 = 42.1875% of the maximum vCpus are reserved for all shares that do not have the identifier `A`, `B`, or `C`.\n\nIf there are no other shares that your jobs can specify, this means that 42.1875% of your capacity will never be used!\n\nNow, `A`, `B`, and `C` can only consume 100% - 42.1875% = 57.8125% of the maximum vCpus.\nNote that the this percentage is **not** split between `A`, `B`, and `C`.\nInstead, the scheduler will use their `weightFactor`s to decide which jobs to schedule;\nthe only difference is that instead of competing for 100% of the max capacity, jobs compete for 57.8125% of the max capacity.\n\nThis example specifies a `computeReservation` of 75% that will behave as explained in the example above:\n\n```ts\nnew batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy', {\n computeReservation: 75,\n shares: [\n { weightFactor: 1, shareIdentifier: 'A' },\n { weightFactor: 0.5, shareIdentifier: 'B' },\n { weightFactor: 2, shareIdentifier: 'C' },\n ],\n});\n```\n\nYou can specify a `priority` on your `JobDefinition`s to tell the scheduler to prioritize certain jobs that share the same share identifier.\n\n### Configuring Job Retry Policies\n\nCertain workflows may result in Jobs failing due to intermittent issues.\nJobs can specify retry policies to respond to different failures with different actions.\nThere are three different ways information about the way a Job exited can be conveyed;\n\n* `exitCode`: the exit code returned from the process executed by the container. Will only match non-zero exit codes.\n* `reason`: any middleware errors, like your Docker registry being down.\n* `statusReason`: infrastructure errors, most commonly your spot instance being reclaimed.\n\nFor most use cases, only one of these will be associated with a particular action at a time.\nTo specify common `exitCode`s, `reason`s, or `statusReason`s, use the corresponding value from\nthe `Reason` class. This example shows some common failure reasons:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n }),\n retryAttempts: 5,\n retryStrategies: [\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER),\n ],\n});\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.SPOT_INSTANCE_RECLAIMED),\n);\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER),\n);\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.custom({\n onExitCode: '40*',\n onReason: 'some reason',\n })),\n);\n```\n\nWhen specifying a custom reason,\nyou can specify a glob string to match each of these and react to different failures accordingly.\nUp to five different retry strategies can be configured for each Job,\nand each strategy can match against some or all of `exitCode`, `reason`, and `statusReason`.\nYou can optionally configure the number of times a job will be retried,\nbut you cannot configure different retry counts for different strategies; they all share the same count.\nIf multiple conditions are specified in a given retry strategy,\nthey must all match for the action to be taken; the conditions are ANDed together, not ORed.\n\n### Running single-container ECS workflows\n\nBatch can run jobs on ECS or EKS. ECS jobs can be defined as single container or multinode.\nThis example creates a `JobDefinition` that runs a single container with ECS:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nimport * as iam from 'aws-cdk-lib/aws-iam';\nimport * as efs from 'aws-cdk-lib/aws-efs';\n\ndeclare const myFileSystem: efs.IFileSystem;\ndeclare const myJobRole: iam.Role;\nmyFileSystem.grantRead(myJobRole);\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n volumes: [batch.EcsVolume.efs({\n name: 'myVolume',\n fileSystem: myFileSystem,\n containerPath: '/Volumes/myVolume',\n useJobRole: true,\n })],\n jobRole: myJobRole,\n }),\n});\n```\n\nFor workflows that need persistent storage, batch supports mounting `Volume`s to the container.\nYou can both provision the volume and mount it to the container in a single operation:\n\n```ts\nimport * as efs from 'aws-cdk-lib/aws-efs';\n\ndeclare const myFileSystem: efs.IFileSystem;\ndeclare const jobDefn: batch.EcsJobDefinition;\n\njobDefn.container.addVolume(batch.EcsVolume.efs({\n name: 'myVolume',\n fileSystem: myFileSystem,\n containerPath: '/Volumes/myVolume',\n}));\n```\n\n### Secrets\n\nYou can expose SecretsManager Secret ARNs or SSM Parameters to your container as environment variables.\nThe following example defines the `MY_SECRET_ENV_VAR` environment variable that contains the\nARN of the Secret defined by `mySecret`:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\n\ndeclare const mySecret: secretsmanager.ISecret;\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n secrets: {\n MY_SECRET_ENV_VAR: batch.Secret.fromSecretsManager(mySecret),\n }\n }),\n});\n```\n\n### Running Kubernetes Workflows\n\nBatch also supports running workflows on EKS. The following example creates a `JobDefinition` that runs on EKS:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nconst jobDefn = new batch.EksJobDefinition(this, 'eksf2', {\n container: new batch.EksContainerDefinition(this, 'container', {\n image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'),\n volumes: [batch.EksVolume.emptyDir({\n name: 'myEmptyDirVolume',\n mountPath: '/mount/path',\n medium: batch.EmptyDirMediumType.MEMORY,\n readonly: true,\n sizeLimit: cdk.Size.mebibytes(2048),\n })],\n }),\n});\n```\n\nYou can mount `Volume`s to these containers in a single operation:\n\n```ts\ndeclare const jobDefn: batch.EksJobDefinition;\njobDefn.container.addVolume(batch.EksVolume.emptyDir({\n name: 'emptyDir',\n mountPath: '/Volumes/emptyDir',\n}));\njobDefn.container.addVolume(batch.EksVolume.hostPath({\n name: 'hostPath',\n hostPath: '/sys',\n mountPath: '/Volumes/hostPath',\n}));\njobDefn.container.addVolume(batch.EksVolume.secret({\n name: 'secret',\n optional: true,\n mountPath: '/Volumes/secret',\n secretName: 'mySecret',\n}));\n```\n\n### Running Distributed Workflows\n\nSome workflows benefit from parallellization and are most powerful when run in a distributed environment,\nsuch as certain numerical calculations or simulations. Batch offers `MultiNodeJobDefinition`s,\nwhich allow a single job to run on multiple instances in parallel, for this purpose.\nMessage Passing Interface (MPI) is often used with these workflows.\nYou must configure your containers to use MPI properly,\nbut Batch allows different nodes running different containers to communicate easily with one another.\nYou must configure your containers to use certain environment variables that Batch will provide them,\nwhich lets them know which one is the main node, among other information.\nFor an in-depth example on using MPI to perform numerical computations on Batch,\nsee this [blog post](https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/)\nIn particular, the environment variable that tells the containers which one is the main node can be configured on your `MultiNodeJobDefinition` as follows:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nconst multiNodeJob = new batch.MultiNodeJobDefinition(this, 'JobDefinition', {\n instanceType: ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE),\n containers: [{\n container: new batch.EcsEc2ContainerDefinition(this, 'mainMPIContainer', {\n image: ecs.ContainerImage.fromRegistry('yourregsitry.com/yourMPIImage:latest'),\n cpu: 256,\n memory: cdk.Size.mebibytes(2048),\n }),\n startNode: 0,\n endNode: 5,\n }],\n});\n// convenience method\nmultiNodeJob.addContainer({\n startNode: 6,\n endNode: 10,\n container: new batch.EcsEc2ContainerDefinition(this, 'multiContainer', {\n image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'),\n cpu: 256,\n memory: cdk.Size.mebibytes(2048),\n }),\n});\n```\n\nIf you need to set the control node to an index other than 0, specify it in directly:\n\n```ts\nconst multiNodeJob = new batch.MultiNodeJobDefinition(this, 'JobDefinition', {\n mainNode: 5,\n instanceType: ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE),\n});\n```\n\n### Pass Parameters to a Job\n\nBatch allows you define parameters in your `JobDefinition`, which can be referenced in the container command. For example:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nnew batch.EcsJobDefinition(this, 'JobDefn', {\n parameters: { echoParam: 'foobar' },\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n command: [\n 'echo',\n 'Ref::echoParam',\n ],\n }),\n});\n```\n\n### Understanding Progressive Allocation Strategies\n\nAWS Batch uses an [allocation strategy](https://docs.aws.amazon.com/batch/latest/userguide/allocation-strategies.html) to determine what compute resource will efficiently handle incoming job requests. By default, **BEST_FIT** will pick an available compute instance based on vCPU requirements. If none exist, the job will wait until resources become available. However, with this strategy, you may have jobs waiting in the queue unnecessarily despite having more powerful instances available. Below is an example of how that situation might look like:\n\n```plaintext\nCompute Environment:\n\n1. m5.xlarge => 4 vCPU\n2. m5.2xlarge => 8 vCPU\n```\n\n```plaintext\nJob Queue:\n---------\n| A | B |\n---------\n\nJob Requirements:\nA => 4 vCPU - ALLOCATED TO m5.xlarge\nB => 2 vCPU - WAITING\n```\n\nIn this situation, Batch will allocate **Job A** to compute resource #1 because it is the most cost efficient resource that matches the vCPU requirement. However, with this `BEST_FIT` strategy, **Job B** will not be allocated to our other available compute resource even though it is strong enough to handle it. Instead, it will wait until the first job is finished processing or wait a similar `m5.xlarge` resource to be provisioned.\n\nThe alternative would be to use the `BEST_FIT_PROGRESSIVE` strategy in order for the remaining job to be handled in larger containers regardless of vCPU requirement and costs.\n\n### Permissions\n\nYou can grant any Principal the `batch:submitJob` permission on both a job definition and a job queue like this:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nimport * as iam from 'aws-cdk-lib/aws-iam';\n\ndeclare const vpc: ec2.IVpc;\n\nconst ecsJob = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n }),\n});\n\nconst queue = new batch.JobQueue(this, 'JobQueue', {\n computeEnvironments: [{\n computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(this, 'managedEc2CE', {\n vpc,\n }),\n order: 1,\n }],\n priority: 10,\n});\n\nconst user = new iam.User(this, 'MyUser');\necsJob.grantSubmitJob(user, queue);\n```\n" + }, + "repository": { + "directory": "packages/@aws-cdk/aws-batch-alpha", + "type": "git", + "url": "https://github.com/aws/aws-cdk.git" + }, + "schema": "jsii/0.10.0", + "targets": { + "dotnet": { + "iconUrl": "https://raw.githubusercontent.com/aws/aws-cdk/main/logo/default-256-dark.png", + "namespace": "Amazon.CDK.AWS.Batch.Alpha", + "packageId": "Amazon.CDK.AWS.Batch.Alpha" + }, + "go": { + "moduleName": "github.com/aws/aws-cdk-go", + "packageName": "awscdkbatchalpha" + }, + "java": { + "maven": { + "artifactId": "batch-alpha", + "groupId": "software.amazon.awscdk" + }, + "package": "software.amazon.awscdk.services.batch.alpha" + }, + "js": { + "npm": "@aws-cdk/aws-batch-alpha" + }, + "python": { + "classifiers": [ + "Framework :: AWS CDK", + "Framework :: AWS CDK :: 2" + ], + "distName": "aws-cdk.aws-batch-alpha", + "module": "aws_cdk.aws_batch_alpha" + } + }, + "types": { + "@aws-cdk/aws-batch-alpha.Action": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "The Action to take when all specified conditions in a RetryStrategy are met." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Action", + "kind": "enum", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 159 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "The job will not retry." + }, + "name": "EXIT" + }, + { + "docs": { + "remarks": "It can be retried up to the number of times specified in `retryAttempts`.", + "stability": "experimental", + "summary": "The job will retry." + }, + "name": "RETRY" + } + ], + "name": "Action", + "symbolId": "lib/job-definition-base:Action" + }, + "@aws-cdk/aws-batch-alpha.AllocationStrategy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "see": "https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/", + "stability": "experimental", + "summary": "Determines how this compute environment chooses instances to spawn." + }, + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy", + "kind": "enum", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 423 + }, + "members": [ + { + "docs": { + "remarks": "If instances of that type are not available, the queue will not choose a new type;\ninstead, it will wait for the instance to become available.\nThis can stall your `Queue`, with your compute environment only using part of its max capacity\n(or none at all) until the `BEST_FIT` instance becomes available.\nThis allocation strategy keeps costs lower but can limit scaling.\n`BEST_FIT` isn't supported when updating compute environments", + "stability": "experimental", + "summary": "Batch chooses the lowest-cost instance type that fits all the jobs in the queue." + }, + "name": "BEST_FIT" + }, + { + "docs": { + "remarks": "This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements\nof the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`.\nHowever, if not all of the capacity can be filled with this instance type,\nit will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity.\nTo make the most use of this allocation strategy,\nit is recommended to use as many instance classes as is feasible for your workload.", + "stability": "experimental", + "summary": "This is the default Allocation Strategy if `spot` is `false` or unspecified." + }, + "name": "BEST_FIT_PROGRESSIVE" + }, + { + "docs": { + "remarks": "This will tell Batch to choose the instance types from the ones you’ve specified that have\nthe most spot capacity available to minimize the chance of interruption.\nTo get the most benefit from your spot instances,\nyou should allow Batch to choose from as many different instance types as possible.", + "stability": "experimental", + "summary": "If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled)." + }, + "name": "SPOT_CAPACITY_OPTIMIZED" + }, + { + "docs": { + "remarks": "The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances.", + "stability": "experimental", + "summary": "The price and capacity optimized allocation strategy looks at both price and capacity to select the Spot Instance pools that are the least likely to be interrupted and have the lowest possible price." + }, + "name": "SPOT_PRICE_CAPACITY_OPTIMIZED" + } + ], + "name": "AllocationStrategy", + "symbolId": "lib/managed-compute-environment:AllocationStrategy" + }, + "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props common to all ComputeEnvironments." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 50 + }, + "name": "ComputeEnvironmentProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- generated by CloudFormation", + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 56 + }, + "name": "computeEnvironmentName", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 81 + }, + "name": "enabled", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- a serviceRole will be created for managed CEs, none for unmanaged CEs", + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 64 + }, + "name": "serviceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + } + ], + "symbolId": "lib/compute-environment-base:ComputeEnvironmentProps" + }, + "@aws-cdk/aws-batch-alpha.CustomReason": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "The corresponding Action will only be taken if *all* of the conditions specified here are met." + }, + "fqn": "@aws-cdk/aws-batch-alpha.CustomReason", + "kind": "interface", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 173 + }, + "name": "CustomReason", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- will not match on the exit code", + "remarks": "For example, `'40*'` will match 400, 404, 40123456789012", + "stability": "experimental", + "summary": "A glob string that will match on the job exit code." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 179 + }, + "name": "onExitCode", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- will not match on the reason", + "stability": "experimental", + "summary": "A glob string that will match on the reason returned by the exiting job For example, `'CannotPullContainerError*'` indicates that container needed to start the job could not be pulled." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 195 + }, + "name": "onReason", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- will not match on the status reason", + "remarks": "For example, `'Host EC2*'` indicates that the spot instance has been reclaimed.", + "stability": "experimental", + "summary": "A glob string that will match on the statusReason returned by the exiting job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 187 + }, + "name": "onStatusReason", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/job-definition-base:CustomReason" + }, + "@aws-cdk/aws-batch-alpha.Device": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "A container instance host device." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Device", + "kind": "interface", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 143 + }, + "name": "Device", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The path for the device on the host container instance." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 154 + }, + "name": "hostPath", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "Same path as the host", + "stability": "experimental", + "summary": "The path inside the container at which to expose the host device." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 149 + }, + "name": "containerPath", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "Readonly", + "remarks": "By default, the container has permissions for read, write, and mknod for the device.", + "stability": "experimental", + "summary": "The explicit permissions to provide to the container for the device." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 162 + }, + "name": "permissions", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.DevicePermission" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/linux-parameters:Device" + }, + "@aws-cdk/aws-batch-alpha.DevicePermission": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Permissions for device access." + }, + "fqn": "@aws-cdk/aws-batch-alpha.DevicePermission", + "kind": "enum", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 191 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "Read." + }, + "name": "READ" + }, + { + "docs": { + "stability": "experimental", + "summary": "Write." + }, + "name": "WRITE" + }, + { + "docs": { + "stability": "experimental", + "summary": "Make a node." + }, + "name": "MKNOD" + } + ], + "name": "DevicePermission", + "symbolId": "lib/linux-parameters:DevicePermission" + }, + "@aws-cdk/aws-batch-alpha.DnsPolicy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", + "stability": "experimental", + "summary": "The DNS Policy for the pod used by the Job Definition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy", + "kind": "enum", + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 100 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "The Pod inherits the name resolution configuration from the node that the Pods run on." + }, + "name": "DEFAULT" + }, + { + "docs": { + "stability": "experimental", + "summary": "Any DNS query that does not match the configured cluster domain suffix, such as `\"www.kubernetes.io\"`, is forwarded to an upstream nameserver by the DNS server. Cluster administrators may have extra stub-domain and upstream DNS servers configured." + }, + "name": "CLUSTER_FIRST" + }, + { + "docs": { + "remarks": "Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy.", + "stability": "experimental", + "summary": "For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`." + }, + "name": "CLUSTER_FIRST_WITH_HOST_NET" + } + ], + "name": "DnsPolicy", + "symbolId": "lib/eks-job-definition:DnsPolicy" + }, + "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure an EcsContainerDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 472 + }, + "name": "EcsContainerDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", + "stability": "experimental", + "summary": "The number of vCPUs reserved for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 483 + }, + "name": "cpu", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 476 + }, + "name": "image", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "abstract": true, + "docs": { + "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", + "stability": "experimental", + "summary": "The memory hard limit present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 490 + }, + "name": "memory", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "- no command", + "see": "https://docs.docker.com/engine/reference/builder/#cmd", + "stability": "experimental", + "summary": "The command that's passed to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 499 + }, + "name": "command", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no environment variables", + "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", + "stability": "experimental", + "summary": "The environment variables to pass to a container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 508 + }, + "name": "environment", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- a Role will be created", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html", + "stability": "experimental", + "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 517 + }, + "name": "executionRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "- no job role", + "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html", + "stability": "experimental", + "summary": "The role that the container can assume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 526 + }, + "name": "jobRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "stability": "experimental", + "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 533 + }, + "name": "linuxParameters", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" + } + }, + { + "abstract": true, + "docs": { + "default": "- the log configuration of the Docker daemon", + "stability": "experimental", + "summary": "The loging configuration for this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 540 + }, + "name": "logging", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ecs.LogDriver" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Gives the container readonly access to its root filesystem." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 547 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- no secrets", + "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html", + "stability": "experimental", + "summary": "A map from environment variable names to the secrets for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 557 + }, + "name": "secrets", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no user", + "stability": "experimental", + "summary": "The user name to use inside the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 564 + }, + "name": "user", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- no volumes", + "remarks": "Automatically added to the job definition.", + "stability": "experimental", + "summary": "The volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 571 + }, + "name": "volumes", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsContainerDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "constructs.Construct", + "docs": { + "stability": "experimental", + "summary": "A container orchestrated by ECS that uses EC2 resources." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 900 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 895 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Add a ulimit to this container." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 934 + }, + "name": "addUlimit", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "parameters": [ + { + "name": "ulimit", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" + } + } + ] + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a Volume to this container." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 706 + }, + "name": "addVolume", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "parameters": [ + { + "name": "volume", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + } + } + ] + } + ], + "name": "EcsEc2ContainerDefinition", + "properties": [ + { + "docs": { + "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", + "stability": "experimental", + "summary": "The number of vCPUs reserved for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 579 + }, + "name": "cpu", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 583 + }, + "name": "executionRole", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 578 + }, + "name": "image", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "docs": { + "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", + "stability": "experimental", + "summary": "The memory hard limit present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 580 + }, + "name": "memory", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Limits to set for the user this docker container will run as." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 897 + }, + "name": "ulimits", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "Automatically added to the job definition.", + "stability": "experimental", + "summary": "The volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 590 + }, + "name": "volumes", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The command that's passed to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 581 + }, + "name": "command", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", + "stability": "experimental", + "summary": "The environment variables to pass to a container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 582 + }, + "name": "environment", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "docs": { + "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", + "stability": "experimental", + "summary": "The number of physical GPUs to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 898 + }, + "name": "gpu", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role that the container can assume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 584 + }, + "name": "jobRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 585 + }, + "name": "linuxParameters", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The configuration of the log driver." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 586 + }, + "name": "logDriverConfig", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 896 + }, + "name": "privileged", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Gives the container readonly access to its root filesystem." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 587 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", + "stability": "experimental", + "summary": "A map from environment variable names to the secrets for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 588 + }, + "name": "secrets", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + }, + "kind": "map" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The user name to use inside the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 589 + }, + "name": "user", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsEc2ContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure an EcsEc2ContainerDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 867 + }, + "name": "EcsEc2ContainerDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- no gpus", + "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", + "stability": "experimental", + "summary": "The number of physical GPUs to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 889 + }, + "name": "gpu", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 873 + }, + "name": "privileged", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- no ulimits", + "stability": "experimental", + "summary": "Limits to set for the user this docker container will run as." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 880 + }, + "name": "ulimits", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsEc2ContainerDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "constructs.Construct", + "docs": { + "stability": "experimental", + "summary": "A container orchestrated by ECS that uses Fargate resources." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1022 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", + "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1017 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Add a Volume to this container." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 706 + }, + "name": "addVolume", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "parameters": [ + { + "name": "volume", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + } + } + ] + } + ], + "name": "EcsFargateContainerDefinition", + "properties": [ + { + "docs": { + "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", + "stability": "experimental", + "summary": "The number of vCPUs reserved for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 579 + }, + "name": "cpu", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 583 + }, + "name": "executionRole", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 578 + }, + "name": "image", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "docs": { + "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", + "stability": "experimental", + "summary": "The memory hard limit present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 580 + }, + "name": "memory", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "remarks": "Automatically added to the job definition.", + "stability": "experimental", + "summary": "The volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 590 + }, + "name": "volumes", + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", + "stability": "experimental", + "summary": "Indicates whether the job has a public IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1019 + }, + "name": "assignPublicIp", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The command that's passed to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 581 + }, + "name": "command", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", + "stability": "experimental", + "summary": "The environment variables to pass to a container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 582 + }, + "name": "environment", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The size for ephemeral storage." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1020 + }, + "name": "ephemeralStorageSize", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Which version of Fargate to use when running this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1018 + }, + "name": "fargatePlatformVersion", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role that the container can assume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 584 + }, + "name": "jobRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 585 + }, + "name": "linuxParameters", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The configuration of the log driver." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 586 + }, + "name": "logDriverConfig", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Gives the container readonly access to its root filesystem." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 587 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", + "stability": "experimental", + "summary": "A map from environment variable names to the secrets for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 588 + }, + "name": "secrets", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + }, + "kind": "map" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The user name to use inside the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 589 + }, + "name": "user", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsFargateContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure an EcsFargateContainerDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 987 + }, + "name": "EcsFargateContainerDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", + "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html", + "stability": "experimental", + "summary": "Indicates whether the job has a public IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 997 + }, + "name": "assignPublicIp", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- 20 GiB", + "stability": "experimental", + "summary": "The size for ephemeral storage." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1011 + }, + "name": "ephemeralStorageSize", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "LATEST", + "stability": "experimental", + "summary": "Which version of Fargate to use when running this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 1004 + }, + "name": "fargatePlatformVersion", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsFargateContainerDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EcsJobDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::JobDefinition" + }, + "stability": "experimental", + "summary": "A JobDefinition that uses ECS orchestration." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 84 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IJobDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 58 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Import a JobDefinition by its arn." + }, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 62 + }, + "name": "fromJobDefinitionArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "jobDefinitionArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a RetryStrategy to this JobDefinition." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 259 + }, + "name": "addRetryStrategy", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "parameters": [ + { + "name": "strategy", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + } + } + ] + }, + { + "docs": { + "stability": "experimental", + "summary": "Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue`." + }, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 110 + }, + "name": "grantSubmitJob", + "parameters": [ + { + "name": "identity", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IGrantable" + } + }, + { + "name": "queue", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue" + } + } + ] + } + ], + "name": "EcsJobDefinition", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The container that this job will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 78 + }, + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 81 + }, + "name": "jobDefinitionArn", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 82 + }, + "name": "jobDefinitionName", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Defines the retry behavior for this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 243 + }, + "name": "retryStrategies", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 241 + }, + "name": "parameters", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "any" + }, + "kind": "map" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 79 + }, + "name": "propagateTags", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "The job is retried on failure the same number of attempts as the value.", + "stability": "experimental", + "summary": "The number of times to retry a job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 242 + }, + "name": "retryAttempts", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", + "stability": "experimental", + "summary": "The priority of this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 244 + }, + "name": "schedulingPriority", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", + "stability": "experimental", + "summary": "The timeout time for jobs that are submitted with this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 245 + }, + "name": "timeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/ecs-job-definition:EcsJobDefinition" + }, + "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for EcsJobDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.JobDefinitionProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 38 + }, + "name": "EcsJobDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The container that this job will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 42 + }, + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-job-definition.ts", + "line": 50 + }, + "name": "propagateTags", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-job-definition:EcsJobDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EcsMachineImage": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "A Batch MachineImage that is compatible with ECS." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage", + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 367 + }, + "name": "EcsMachineImage", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- chosen by batch", + "stability": "experimental", + "summary": "The machine image to use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 361 + }, + "name": "image", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IMachineImage" + } + }, + { + "abstract": true, + "docs": { + "default": "- 'ECS_AL2' for non-gpu instances, 'ECS_AL2_NVIDIA' for gpu instances", + "stability": "experimental", + "summary": "Tells Batch which instance type to launch this image on." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 373 + }, + "name": "imageType", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImageType" + } + } + ], + "symbolId": "lib/managed-compute-environment:EcsMachineImage" + }, + "@aws-cdk/aws-batch-alpha.EcsMachineImageType": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Maps the image to instance types." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImageType", + "kind": "enum", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 391 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "Tells Batch that this machine image runs on non-GPU instances." + }, + "name": "ECS_AL2" + }, + { + "docs": { + "stability": "experimental", + "summary": "Tells Batch that this machine image runs on GPU instances." + }, + "name": "ECS_AL2_NVIDIA" + } + ], + "name": "EcsMachineImageType", + "symbolId": "lib/managed-compute-environment:EcsMachineImageType" + }, + "@aws-cdk/aws-batch-alpha.EcsVolume": { + "abstract": true, + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Represents a Volume that can be mounted to a container that uses ECS." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 162 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 126 + }, + "methods": [ + { + "docs": { + "remarks": "this volume can grow and shrink as needed", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html", + "stability": "experimental", + "summary": "Creates a Volume that uses an AWS Elastic File System (EFS);" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 132 + }, + "name": "efs", + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EfsVolume" + } + }, + "static": true + }, + { + "docs": { + "remarks": "This volume will persist on the host at the specified `hostPath`.\nIf the `hostPath` is not specified, Docker will choose the host path. In this case,\nthe data may not persist after the containers that use it stop running.", + "stability": "experimental", + "summary": "Creates a Host volume." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 141 + }, + "name": "host", + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostVolume" + } + }, + "static": true + } + ], + "name": "EcsVolume", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The path on the container that this volume will be mounted to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 153 + }, + "name": "containerPath", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 148 + }, + "name": "name", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Whether or not the container has readonly access to this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 160 + }, + "name": "readonly", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsVolume" + }, + "@aws-cdk/aws-batch-alpha.EcsVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Options to configure an EcsVolume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolumeOptions", + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 104 + }, + "name": "EcsVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "the path on the container where this volume is mounted." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 113 + }, + "name": "containerPath", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "the name of this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 108 + }, + "name": "name", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "if set, the container will have readonly access to the volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 120 + }, + "name": "readonly", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:EcsVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.EfsVolume": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "@aws-cdk/aws-batch-alpha.EcsVolume", + "docs": { + "remarks": "this volume can grow and shrink as needed", + "stability": "experimental", + "summary": "A Volume that uses an AWS Elastic File System (EFS);" + }, + "fqn": "@aws-cdk/aws-batch-alpha.EfsVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 297 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 233 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Returns true if x is an EfsVolume, false otherwise." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 237 + }, + "name": "isEfsVolume", + "parameters": [ + { + "name": "x", + "type": { + "primitive": "any" + } + } + ], + "returns": { + "type": { + "primitive": "boolean" + } + }, + "static": true + } + ], + "name": "EfsVolume", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The EFS File System that supports this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 244 + }, + "name": "fileSystem", + "type": { + "fqn": "aws-cdk-lib.aws_efs.IFileSystem" + } + }, + { + "docs": { + "default": "- no accessPointId", + "remarks": "If an access point is specified, `rootDirectory` must either be omitted or set to `/`\nwhich enforces the path set on the EFS access point.\nIf an access point is used, `enableTransitEncryption` must be `true`.", + "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html", + "stability": "experimental", + "summary": "The Amazon EFS access point ID to use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 285 + }, + "name": "accessPointId", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "false", + "see": "https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html", + "stability": "experimental", + "summary": "Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 263 + }, + "name": "enableTransitEncryption", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "default": "- root of the EFS File System", + "remarks": "If this parameter is omitted, the root of the Amazon EFS volume is used instead.\nSpecifying `/` has the same effect as omitting this parameter.\nThe maximum length is 4,096 characters.", + "stability": "experimental", + "summary": "The directory within the Amazon EFS file system to mount as the root directory inside the host." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 254 + }, + "name": "rootDirectory", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "- chosen by the EFS Mount Helper", + "remarks": "The value must be between 0 and 65,535.", + "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html", + "stability": "experimental", + "summary": "The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 273 + }, + "name": "transitEncryptionPort", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "docs": { + "default": "false", + "remarks": "If specified, `enableTransitEncryption` must be `true`.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints", + "stability": "experimental", + "summary": "Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 295 + }, + "name": "useJobRole", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:EfsVolume" + }, + "@aws-cdk/aws-batch-alpha.EfsVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Options for configuring an EfsVolume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 172 + }, + "name": "EfsVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The EFS File System that supports this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 176 + }, + "name": "fileSystem", + "type": { + "fqn": "aws-cdk-lib.aws_efs.IFileSystem" + } + }, + { + "abstract": true, + "docs": { + "default": "- no accessPointId", + "remarks": "If an access point is specified, `rootDirectory` must either be omitted or set to `/`\nwhich enforces the path set on the EFS access point.\nIf an access point is used, `enableTransitEncryption` must be `true`.", + "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html", + "stability": "experimental", + "summary": "The Amazon EFS access point ID to use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 217 + }, + "name": "accessPointId", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "see": "https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html", + "stability": "experimental", + "summary": "Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 195 + }, + "name": "enableTransitEncryption", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- root of the EFS File System", + "remarks": "If this parameter is omitted, the root of the Amazon EFS volume is used instead.\nSpecifying `/` has the same effect as omitting this parameter.\nThe maximum length is 4,096 characters.", + "stability": "experimental", + "summary": "The directory within the Amazon EFS file system to mount as the root directory inside the host." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 186 + }, + "name": "rootDirectory", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- chosen by the EFS Mount Helper", + "remarks": "The value must be between 0 and 65,535.", + "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html", + "stability": "experimental", + "summary": "The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 205 + }, + "name": "transitEncryptionPort", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "If specified, `enableTransitEncryption` must be `true`.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints", + "stability": "experimental", + "summary": "Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 227 + }, + "name": "useJobRole", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:EfsVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.EksContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "constructs.Construct", + "docs": { + "stability": "experimental", + "summary": "A container that can be run with EKS orchestration on EC2 resources." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 555 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEksContainerDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 533 + }, + "methods": [ + { + "docs": { + "remarks": "Automatically added to the Pod.", + "stability": "experimental", + "summary": "Mount a Volume to this container." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 579 + }, + "name": "addVolume", + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "parameters": [ + { + "name": "volume", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" + } + } + ] + } + ], + "name": "EksContainerDefinition", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 534 + }, + "name": "image", + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "docs": { + "remarks": "Automatically added to the Pod.", + "stability": "experimental", + "summary": "The Volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 551 + }, + "name": "volumes", + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", + "stability": "experimental", + "summary": "An array of arguments to the entrypoint." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 535 + }, + "name": "args", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", + "stability": "experimental", + "summary": "The entrypoint for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 536 + }, + "name": "command", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "stability": "experimental", + "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 542 + }, + "name": "cpuLimit", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 543 + }, + "name": "cpuReservation", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", + "stability": "experimental", + "summary": "The environment variables to pass to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 537 + }, + "name": "env", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "docs": { + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "stability": "experimental", + "summary": "The hard limit of GPUs to present to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 544 + }, + "name": "gpuLimit", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 545 + }, + "name": "gpuReservation", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The image pull policy for this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 538 + }, + "name": "imagePullPolicy", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" + } + }, + { + "docs": { + "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "stability": "experimental", + "summary": "The amount (in MiB) of memory to present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 540 + }, + "name": "memoryLimit", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "stability": "experimental", + "summary": "The soft limit (in MiB) of memory to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 541 + }, + "name": "memoryReservation", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 539 + }, + "name": "name", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "stability": "experimental", + "summary": "If specified, gives this container elevated permissions on the host container instance." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 546 + }, + "name": "privileged", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "stability": "experimental", + "summary": "If specified, gives this container readonly access to its root file system." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 547 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "stability": "experimental", + "summary": "If specified, the container is run as the specified group ID (`gid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 548 + }, + "name": "runAsGroup", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "stability": "experimental", + "summary": "If specified, the container is run as a user with a `uid` other than 0." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 549 + }, + "name": "runAsRoot", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "stability": "experimental", + "summary": "If specified, this container is run as the specified user ID (`uid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 550 + }, + "name": "runAsUser", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/eks-container-definition:EksContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure an EksContainerDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 287 + }, + "name": "EksContainerDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 291 + }, + "name": "image", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "abstract": true, + "docs": { + "default": "- no args", + "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", + "see": "https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/", + "stability": "experimental", + "summary": "An array of arguments to the entrypoint." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 308 + }, + "name": "args", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no command", + "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", + "see": "https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint", + "stability": "experimental", + "summary": "The entrypoint for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 327 + }, + "name": "command", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- No CPU limit", + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 411 + }, + "name": "cpuLimit", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- No CPUs reserved", + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 426 + }, + "name": "cpuReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no environment variables", + "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", + "stability": "experimental", + "summary": "The environment variables to pass to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 337 + }, + "name": "env", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- No GPU limit", + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The hard limit of GPUs to present to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 439 + }, + "name": "gpuLimit", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- No GPUs reserved", + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 453 + }, + "name": "gpuReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise", + "see": "https://kubernetes.io/docs/concepts/containers/images/#updating-images", + "stability": "experimental", + "summary": "The image pull policy for this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 346 + }, + "name": "imagePullPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" + } + }, + { + "abstract": true, + "docs": { + "default": "- No memory limit", + "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", + "stability": "experimental", + "summary": "The amount (in MiB) of memory to present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 371 + }, + "name": "memoryLimit", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "- No memory reserved", + "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", + "stability": "experimental", + "summary": "The soft limit (in MiB) of memory to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 396 + }, + "name": "memoryReservation", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": ": `'Default'`", + "stability": "experimental", + "summary": "The name of this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 353 + }, + "name": "name", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", + "stability": "experimental", + "summary": "If specified, gives this container elevated permissions on the host container instance." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 467 + }, + "name": "privileged", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", + "stability": "experimental", + "summary": "If specified, gives this container readonly access to its root file system." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 480 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, the container is run as the specified group ID (`gid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 493 + }, + "name": "runAsGroup", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- the container is *not* required to run as a non-root user", + "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, the container is run as a user with a `uid` other than 0." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 505 + }, + "name": "runAsRoot", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- the user that is specified in the image metadata.", + "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, this container is run as the specified user ID (`uid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 517 + }, + "name": "runAsUser", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no volumes", + "remarks": "Automatically added to the Pod.", + "see": "https://kubernetes.io/docs/concepts/storage/volumes/", + "stability": "experimental", + "summary": "The Volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 527 + }, + "name": "volumes", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/eks-container-definition:EksContainerDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EksJobDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::JobDefinition" + }, + "stability": "experimental", + "summary": "A JobDefinition that uses Eks orchestration." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 151 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "@aws-cdk/aws-batch-alpha.IJobDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 125 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Import an EksJobDefinition by its arn." + }, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 129 + }, + "name": "fromEksJobDefinitionArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "eksJobDefinitionArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IEksJobDefinition" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a RetryStrategy to this JobDefinition." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 259 + }, + "name": "addRetryStrategy", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "parameters": [ + { + "name": "strategy", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + } + } + ] + } + ], + "name": "EksJobDefinition", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The container this Job Definition will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 143 + }, + "name": "container", + "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 148 + }, + "name": "jobDefinitionArn", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 149 + }, + "name": "jobDefinitionName", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Defines the retry behavior for this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 243 + }, + "name": "retryStrategies", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The DNS Policy of the pod used by this Job Definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 144 + }, + "name": "dnsPolicy", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 241 + }, + "name": "parameters", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "any" + }, + "kind": "map" + } + } + }, + { + "docs": { + "remarks": "The job is retried on failure the same number of attempts as the value.", + "stability": "experimental", + "summary": "The number of times to retry a job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 242 + }, + "name": "retryAttempts", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", + "stability": "experimental", + "summary": "The priority of this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 244 + }, + "name": "schedulingPriority", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", + "stability": "experimental", + "summary": "The name of the service account that's used to run the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 146 + }, + "name": "serviceAccount", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", + "stability": "experimental", + "summary": "The timeout time for jobs that are submitted with this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 245 + }, + "name": "timeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "docs": { + "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", + "stability": "experimental", + "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 145 + }, + "name": "useHostNetwork", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-job-definition:EksJobDefinition" + }, + "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for EksJobDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.JobDefinitionProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 54 + }, + "name": "EksJobDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The container this Job Definition will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 58 + }, + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" + } + }, + { + "abstract": true, + "docs": { + "default": "`DnsPolicy.CLUSTER_FIRST`", + "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", + "stability": "experimental", + "summary": "The DNS Policy of the pod used by this Job Definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 67 + }, + "name": "dnsPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" + } + }, + { + "abstract": true, + "docs": { + "default": "- the default service account of the container", + "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", + "see": "https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html", + "stability": "experimental", + "summary": "The name of the service account that's used to run the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 92 + }, + "name": "serviceAccount", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", + "see": "https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking", + "stability": "experimental", + "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 79 + }, + "name": "useHostNetwork", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-job-definition:EksJobDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.EksMachineImage": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "A Batch MachineImage that is compatible with EKS." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage", + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 379 + }, + "name": "EksMachineImage", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- chosen by batch", + "stability": "experimental", + "summary": "The machine image to use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 361 + }, + "name": "image", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IMachineImage" + } + }, + { + "abstract": true, + "docs": { + "default": "- 'EKS_AL2' for non-gpu instances, 'EKS_AL2_NVIDIA' for gpu instances", + "stability": "experimental", + "summary": "Tells Batch which instance type to launch this image on." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 385 + }, + "name": "imageType", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImageType" + } + } + ], + "symbolId": "lib/managed-compute-environment:EksMachineImage" + }, + "@aws-cdk/aws-batch-alpha.EksMachineImageType": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Maps the image to instance types." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImageType", + "kind": "enum", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 406 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "Tells Batch that this machine image runs on non-GPU instances." + }, + "name": "EKS_AL2" + }, + { + "docs": { + "stability": "experimental", + "summary": "Tells Batch that this machine image runs on GPU instances." + }, + "name": "EKS_AL2_NVIDIA" + } + ], + "name": "EksMachineImageType", + "symbolId": "lib/managed-compute-environment:EksMachineImageType" + }, + "@aws-cdk/aws-batch-alpha.EksVolume": { + "abstract": true, + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A Volume that can be mounted to a container supported by EKS." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 717 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 668 + }, + "methods": [ + { + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", + "stability": "experimental", + "summary": "Creates a Kubernetes EmptyDir volume." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 674 + }, + "name": "emptyDir", + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolume" + } + }, + "static": true + }, + { + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", + "stability": "experimental", + "summary": "Creates a Kubernetes HostPath volume." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 682 + }, + "name": "hostPath", + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolume" + } + }, + "static": true + }, + { + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", + "stability": "experimental", + "summary": "Creates a Kubernetes Secret volume." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 690 + }, + "name": "secret", + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolume" + } + }, + "static": true + } + ], + "name": "EksVolume", + "properties": [ + { + "docs": { + "remarks": "The name must be a valid DNS subdomain name.", + "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", + "stability": "experimental", + "summary": "The name of this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 700 + }, + "name": "name", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "- the container is not mounted", + "stability": "experimental", + "summary": "The path on the container where the container is mounted." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 707 + }, + "name": "containerPath", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "false", + "remarks": "Otherwise, the container has read/write access.", + "stability": "experimental", + "summary": "If specified, the container has readonly access to the volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 715 + }, + "name": "readonly", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-container-definition:EksVolume" + }, + "@aws-cdk/aws-batch-alpha.EksVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Options to configure an EksVolume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EksVolumeOptions", + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 640 + }, + "name": "EksVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "The name must be a valid DNS subdomain name.", + "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", + "stability": "experimental", + "summary": "The name of this volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 647 + }, + "name": "name", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- the volume is not mounted", + "stability": "experimental", + "summary": "The path on the container where the volume is mounted." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 654 + }, + "name": "mountPath", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "Otherwise, the container has read/write access.", + "stability": "experimental", + "summary": "If specified, the container has readonly access to the volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 662 + }, + "name": "readonly", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-container-definition:EksVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.EmptyDirMediumType": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "What medium the volume will live in." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType", + "kind": "enum", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 748 + }, + "members": [ + { + "docs": { + "remarks": "Items written here will survive node reboots.", + "stability": "experimental", + "summary": "Use the disk storage of the node." + }, + "name": "DISK" + }, + { + "docs": { + "remarks": "Items written here will *not* survive node reboots.", + "stability": "experimental", + "summary": "Use the `tmpfs` volume that is backed by RAM of the node." + }, + "name": "MEMORY" + } + ], + "name": "EmptyDirMediumType", + "symbolId": "lib/eks-container-definition:EmptyDirMediumType" + }, + "@aws-cdk/aws-batch-alpha.EmptyDirVolume": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "@aws-cdk/aws-batch-alpha.EksVolume", + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", + "stability": "experimental", + "summary": "A Kubernetes EmptyDir volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 789 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 767 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Returns `true` if `x` is an EmptyDirVolume, `false` otherwise." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 771 + }, + "name": "isEmptyDirVolume", + "parameters": [ + { + "name": "x", + "type": { + "primitive": "any" + } + } + ], + "returns": { + "type": { + "primitive": "boolean" + } + }, + "static": true + } + ], + "name": "EmptyDirVolume", + "properties": [ + { + "docs": { + "default": "`EmptyDirMediumType.DISK`", + "stability": "experimental", + "summary": "The storage type to use for this Volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 780 + }, + "name": "medium", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType" + } + }, + { + "docs": { + "default": "- no size limit", + "stability": "experimental", + "summary": "The maximum size for this Volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 787 + }, + "name": "sizeLimit", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + } + ], + "symbolId": "lib/eks-container-definition:EmptyDirVolume" + }, + "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", + "stability": "experimental", + "summary": "Options for a Kubernetes EmptyDir volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EksVolumeOptions" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 729 + }, + "name": "EmptyDirVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "default": "`EmptyDirMediumType.DISK`", + "stability": "experimental", + "summary": "The storage type to use for this Volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 735 + }, + "name": "medium", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType" + } + }, + { + "abstract": true, + "docs": { + "default": "- no size limit", + "stability": "experimental", + "summary": "The maximum size for this Volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 742 + }, + "name": "sizeLimit", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + } + ], + "symbolId": "lib/eks-container-definition:EmptyDirVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::SchedulingPolicy" + }, + "remarks": "The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs.\nThe scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of\neach share are currently being executed by the ComputeEnvironment*. The weight factors associated with\neach share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of\nfairshare policies.", + "stability": "experimental", + "summary": "Represents a Fairshare Scheduling Policy. Instructs the scheduler to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers." + }, + "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 212 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", + "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 191 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Reference an exisiting Scheduling Policy by its ARN." + }, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 195 + }, + "name": "fromFairshareSchedulingPolicyArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "fairshareSchedulingPolicyArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a share this to this Fairshare SchedulingPolicy." + }, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 242 + }, + "name": "addShare", + "parameters": [ + { + "name": "share", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Share" + } + } + ] + } + ], + "name": "FairshareSchedulingPolicy", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The arn of this scheduling policy." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 209 + }, + "name": "schedulingPolicyArn", + "overrides": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this scheduling policy." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 210 + }, + "name": "schedulingPolicyName", + "overrides": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", + "stability": "experimental", + "summary": "The shares that this Scheduling Policy applies to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 208 + }, + "name": "shares", + "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Share" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", + "stability": "experimental", + "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 206 + }, + "name": "computeReservation", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", + "stability": "experimental", + "summary": "The amount of time to use to measure the usage of each job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 207 + }, + "name": "shareDecay", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/scheduling-policy:FairshareSchedulingPolicy" + }, + "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Fairshare SchedulingPolicy configuration." + }, + "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 136 + }, + "name": "FairshareSchedulingPolicyProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- no vCPU is reserved", + "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", + "stability": "experimental", + "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 155 + }, + "name": "computeReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- generated by CloudFormation", + "stability": "experimental", + "summary": "The name of this SchedulingPolicy." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 34 + }, + "name": "schedulingPolicyName", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- 0: only the current job usage is considered", + "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", + "stability": "experimental", + "summary": "The amount of time to use to measure the usage of each job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 167 + }, + "name": "shareDecay", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "abstract": true, + "docs": { + "default": "- no shares", + "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", + "stability": "experimental", + "summary": "The shares that this Scheduling Policy applies to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 176 + }, + "name": "shares", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Share" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/scheduling-policy:FairshareSchedulingPolicyProps" + }, + "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::ComputeEnvironment" + }, + "stability": "experimental", + "summary": "A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances." + }, + "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1096 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1072 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Reference an existing FargateComputeEnvironment by its arn." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1076 + }, + "name": "fromFargateComputeEnvironmentArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "fargateComputeEnvironmentArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment" + } + }, + "static": true + } + ], + "name": "FargateComputeEnvironment", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this compute environment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1094 + }, + "name": "computeEnvironmentArn", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1093 + }, + "name": "computeEnvironmentName", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The network connections associated with this resource." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 210 + }, + "name": "connections", + "overrides": "aws-cdk-lib.aws_ec2.IConnectable", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.Connections" + } + }, + { + "docs": { + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 92 + }, + "name": "enabled", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", + "stability": "experimental", + "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 201 + }, + "name": "maxvCpus", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The security groups this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 206 + }, + "name": "securityGroups", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "TagManager to set, remove and format tags." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 208 + }, + "name": "tags", + "overrides": "aws-cdk-lib.ITaggable", + "type": { + "fqn": "aws-cdk-lib.TagManager" + } + }, + { + "docs": { + "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", + "stability": "experimental", + "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 202 + }, + "name": "replaceComputeEnvironment", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 91 + }, + "name": "serviceRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", + "stability": "experimental", + "summary": "Whether or not to use spot instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 203 + }, + "name": "spot", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", + "stability": "experimental", + "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 205 + }, + "name": "terminateOnUpdate", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", + "stability": "experimental", + "summary": "Only meaningful if `terminateOnUpdate` is `false`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 204 + }, + "name": "updateTimeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "docs": { + "remarks": "If you specify a specific AMI, this property will be ignored.", + "stability": "experimental", + "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 207 + }, + "name": "updateToLatestImageVersion", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:FargateComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for a FargateComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1065 + }, + "name": "FargateComputeEnvironmentProps", + "symbolId": "lib/managed-compute-environment:FargateComputeEnvironmentProps" + }, + "@aws-cdk/aws-batch-alpha.HostPathVolume": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "@aws-cdk/aws-batch-alpha.EksVolume", + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", + "stability": "experimental", + "summary": "A Kubernetes HostPath volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 840 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 823 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "returns `true` if `x` is a HostPathVolume, `false` otherwise." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 827 + }, + "name": "isHostPathVolume", + "parameters": [ + { + "name": "x", + "type": { + "primitive": "any" + } + } + ], + "returns": { + "type": { + "primitive": "boolean" + } + }, + "static": true + } + ], + "name": "HostPathVolume", + "properties": [ + { + "docs": { + "remarks": "*Note*: HothPath Volumes present many security risks, and should be avoided when possible.", + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", + "stability": "experimental", + "summary": "The path of the file or directory on the host to mount into containers on the pod." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 838 + }, + "name": "path", + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/eks-container-definition:HostPathVolume" + }, + "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", + "stability": "experimental", + "summary": "Options for a kubernetes HostPath volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EksVolumeOptions" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 807 + }, + "name": "HostPathVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "*Note*: HothPath Volumes present many security risks, and should be avoided when possible.", + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", + "stability": "experimental", + "summary": "The path of the file or directory on the host to mount into containers on the pod." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 815 + }, + "name": "hostPath", + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/eks-container-definition:HostPathVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.HostVolume": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "@aws-cdk/aws-batch-alpha.EcsVolume", + "docs": { + "remarks": "This volume will persist on the host at the specified `hostPath`.\nIf the `hostPath` is not specified, Docker will choose the host path. In this case,\nthe data may not persist after the containers that use it stop running.", + "stability": "experimental", + "summary": "Creates a Host volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.HostVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 346 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 333 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "returns `true` if `x` is a `HostVolume`, `false` otherwise." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 337 + }, + "name": "isHostVolume", + "parameters": [ + { + "name": "x", + "type": { + "primitive": "any" + } + } + ], + "returns": { + "type": { + "primitive": "boolean" + } + }, + "static": true + } + ], + "name": "HostVolume", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The path on the host machine this container will have access to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 344 + }, + "name": "hostPath", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:HostVolume" + }, + "@aws-cdk/aws-batch-alpha.HostVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Options for configuring an ECS HostVolume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 318 + }, + "name": "HostVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- Docker will choose the host path.\nThe data may not persist after the containers that use it stop running.", + "stability": "experimental", + "summary": "The path on the host machine this container will have access to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 325 + }, + "name": "hostPath", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:HostVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.IComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Represents a ComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "interfaces": [ + "aws-cdk-lib.IResource" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 8 + }, + "name": "IComputeEnvironment", + "properties": [ + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The ARN of this compute environment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 21 + }, + "name": "computeEnvironmentArn", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 14 + }, + "name": "computeEnvironmentName", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 44 + }, + "name": "enabled", + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- a serviceRole will be created for managed CEs, none for unmanaged CEs", + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 29 + }, + "name": "serviceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + } + ], + "symbolId": "lib/compute-environment-base:IComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A container that can be run with ECS orchestration." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", + "interfaces": [ + "constructs.IConstruct" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 361 + }, + "methods": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Add a Volume to this container." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 466 + }, + "name": "addVolume", + "parameters": [ + { + "name": "volume", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + } + } + ] + } + ], + "name": "IEcsContainerDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", + "stability": "experimental", + "summary": "The number of vCPUs reserved for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 372 + }, + "name": "cpu", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "see": "https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html", + "stability": "experimental", + "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 402 + }, + "name": "executionRole", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 365 + }, + "name": "image", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "abstract": true, + "docs": { + "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", + "stability": "experimental", + "summary": "The memory hard limit present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 379 + }, + "name": "memory", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "- no volumes", + "remarks": "Automatically added to the job definition.", + "stability": "experimental", + "summary": "The volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 454 + }, + "name": "volumes", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "see": "https://docs.docker.com/engine/reference/builder/#cmd", + "stability": "experimental", + "summary": "The command that's passed to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 386 + }, + "name": "command", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no environment variables", + "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", + "stability": "experimental", + "summary": "The environment variables to pass to a container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 395 + }, + "name": "environment", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no jobRole", + "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html", + "stability": "experimental", + "summary": "The role that the container can assume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 411 + }, + "name": "jobRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "stability": "experimental", + "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 418 + }, + "name": "linuxParameters", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The configuration of the log driver." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 423 + }, + "name": "logDriverConfig", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Gives the container readonly access to its root filesystem." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 430 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- no secrets", + "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html", + "stability": "experimental", + "summary": "A map from environment variable names to the secrets for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 440 + }, + "name": "secrets", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no user", + "stability": "experimental", + "summary": "The user name to use inside the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 447 + }, + "name": "user", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:IEcsContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A container orchestrated by ECS that uses EC2 resources." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 836 + }, + "methods": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Add a ulimit to this container." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 861 + }, + "name": "addUlimit", + "parameters": [ + { + "name": "ulimit", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" + } + } + ] + } + ], + "name": "IEcsEc2ContainerDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Limits to set for the user this docker container will run as." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 847 + }, + "name": "ulimits", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no gpus", + "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", + "stability": "experimental", + "summary": "The number of physical GPUs to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 856 + }, + "name": "gpu", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 842 + }, + "name": "privileged", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:IEcsEc2ContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A container orchestrated by ECS that uses Fargate resources and is orchestrated by ECS." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 957 + }, + "name": "IEcsFargateContainerDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", + "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html", + "stability": "experimental", + "summary": "Indicates whether the job has a public IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 967 + }, + "name": "assignPublicIp", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- 20 GiB", + "stability": "experimental", + "summary": "The size for ephemeral storage." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 981 + }, + "name": "ephemeralStorageSize", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "LATEST", + "stability": "experimental", + "summary": "Which version of Fargate to use when running this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 974 + }, + "name": "fargatePlatformVersion", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" + } + } + ], + "symbolId": "lib/ecs-container-definition:IEcsFargateContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.IEksContainerDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A container that can be run with EKS orchestration on EC2 resources." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", + "interfaces": [ + "constructs.IConstruct" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 13 + }, + "methods": [ + { + "abstract": true, + "docs": { + "remarks": "Automatically added to the Pod.", + "stability": "experimental", + "summary": "Mount a Volume to this container." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 250 + }, + "name": "addVolume", + "parameters": [ + { + "name": "volume", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" + } + } + ] + } + ], + "name": "IEksContainerDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The image that this container will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 17 + }, + "name": "image", + "type": { + "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" + } + }, + { + "abstract": true, + "docs": { + "remarks": "Automatically added to the Pod.", + "see": "https://kubernetes.io/docs/concepts/storage/volumes/", + "stability": "experimental", + "summary": "The Volumes to mount to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 245 + }, + "name": "volumes", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", + "see": "https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/", + "stability": "experimental", + "summary": "An array of arguments to the entrypoint." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 32 + }, + "name": "args", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", + "see": "https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint", + "stability": "experimental", + "summary": "The entrypoint for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 49 + }, + "name": "command", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- No CPU limit", + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 131 + }, + "name": "cpuLimit", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- No CPUs reserved", + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 146 + }, + "name": "cpuReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", + "stability": "experimental", + "summary": "The environment variables to pass to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 57 + }, + "name": "env", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "string" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- No GPU limit", + "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The hard limit of GPUs to present to this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 159 + }, + "name": "gpuLimit", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- No GPUs reserved", + "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", + "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", + "stability": "experimental", + "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 173 + }, + "name": "gpuReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise", + "see": "https://kubernetes.io/docs/concepts/containers/images/#updating-images", + "stability": "experimental", + "summary": "The image pull policy for this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 66 + }, + "name": "imagePullPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" + } + }, + { + "abstract": true, + "docs": { + "default": "- No memory limit", + "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", + "stability": "experimental", + "summary": "The amount (in MiB) of memory to present to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 91 + }, + "name": "memoryLimit", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "- No memory reserved", + "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", + "stability": "experimental", + "summary": "The soft limit (in MiB) of memory to reserve for the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 116 + }, + "name": "memoryReservation", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": ": `'Default'`", + "stability": "experimental", + "summary": "The name of this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 73 + }, + "name": "name", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", + "stability": "experimental", + "summary": "If specified, gives this container elevated permissions on the host container instance." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 187 + }, + "name": "privileged", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", + "stability": "experimental", + "summary": "If specified, gives this container readonly access to its root file system." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 200 + }, + "name": "readonlyRootFilesystem", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, the container is run as the specified group ID (`gid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 213 + }, + "name": "runAsGroup", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- the container is *not* required to run as a non-root user", + "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, the container is run as a user with a `uid` other than 0." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 225 + }, + "name": "runAsRoot", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- the user that is specified in the image metadata.", + "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", + "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", + "stability": "experimental", + "summary": "If specified, this container is run as the specified user ID (`uid`)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 237 + }, + "name": "runAsUser", + "optional": true, + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/eks-container-definition:IEksContainerDefinition" + }, + "@aws-cdk/aws-batch-alpha.IEksJobDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A JobDefinition that uses Eks orchestration." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IJobDefinition" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 10 + }, + "name": "IEksJobDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The container this Job Definition will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 14 + }, + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" + } + }, + { + "abstract": true, + "docs": { + "default": "`DnsPolicy.CLUSTER_FIRST`", + "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", + "stability": "experimental", + "summary": "The DNS Policy of the pod used by this Job Definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 23 + }, + "name": "dnsPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" + } + }, + { + "abstract": true, + "docs": { + "default": "- the default service account of the container", + "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", + "see": "https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html", + "stability": "experimental", + "summary": "The name of the service account that's used to run the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 48 + }, + "name": "serviceAccount", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", + "see": "https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking", + "stability": "experimental", + "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-job-definition.ts", + "line": 35 + }, + "name": "useHostNetwork", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-job-definition:IEksJobDefinition" + }, + "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "remarks": "The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs.\nIt does this by deciding how many Jobs of each share to schedule *relative to how many jobs of\neach share are currently being executed by the ComputeEnvironment*. The weight factors associated with\neach share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of\nfairshare policies.", + "stability": "experimental", + "summary": "Represents a Fairshare Scheduling Policy. Instructs the scheduler to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 92 + }, + "name": "IFairshareSchedulingPolicy", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", + "stability": "experimental", + "summary": "The shares that this Scheduling Policy applies to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 130 + }, + "name": "shares", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Share" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no vCPU is reserved", + "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", + "stability": "experimental", + "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 111 + }, + "name": "computeReservation", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- 0: only the current job usage is considered", + "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", + "stability": "experimental", + "summary": "The amount of time to use to measure the usage of each job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 123 + }, + "name": "shareDecay", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/scheduling-policy:IFairshareSchedulingPolicy" + }, + "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1060 + }, + "name": "IFargateComputeEnvironment", + "symbolId": "lib/managed-compute-environment:IFargateComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.IJobDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Represents a JobDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "interfaces": [ + "aws-cdk-lib.IResource" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 8 + }, + "methods": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Add a RetryStrategy to this JobDefinition." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 70 + }, + "name": "addRetryStrategy", + "parameters": [ + { + "name": "strategy", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + } + } + ] + } + ], + "name": "IJobDefinition", + "properties": [ + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The ARN of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 14 + }, + "name": "jobDefinitionArn", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The name of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 21 + }, + "name": "jobDefinitionName", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- no `RetryStrategy`", + "stability": "experimental", + "summary": "Defines the retry behavior for this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 47 + }, + "name": "retryStrategies", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters", + "stability": "experimental", + "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 32 + }, + "name": "parameters", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "any" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "1", + "remarks": "The job is retried on failure the same number of attempts as the value.", + "stability": "experimental", + "summary": "The number of times to retry a job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 40 + }, + "name": "retryAttempts", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", + "stability": "experimental", + "summary": "The priority of this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 56 + }, + "name": "schedulingPriority", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no timeout", + "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", + "stability": "experimental", + "summary": "The timeout time for jobs that are submitted with this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 65 + }, + "name": "timeout", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/job-definition-base:IJobDefinition" + }, + "@aws-cdk/aws-batch-alpha.IJobQueue": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Represents a JobQueue." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue", + "interfaces": [ + "aws-cdk-lib.IResource" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 10 + }, + "methods": [ + { + "abstract": true, + "docs": { + "remarks": "The Queue will prefer lower-order `ComputeEnvironment`s.", + "stability": "experimental", + "summary": "Add a `ComputeEnvironment` to this Queue." + }, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 66 + }, + "name": "addComputeEnvironment", + "parameters": [ + { + "name": "computeEnvironment", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + } + }, + { + "name": "order", + "type": { + "primitive": "number" + } + } + ] + } + ], + "name": "IJobQueue", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", + "stability": "experimental", + "summary": "The set of compute environments mapped to a job queue and their order relative to each other." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 37 + }, + "name": "computeEnvironments", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The ARN of this job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 24 + }, + "name": "jobQueueArn", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", + "stability": "experimental", + "summary": "The name of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 17 + }, + "name": "jobQueueName", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1.", + "stability": "experimental", + "summary": "The priority of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 45 + }, + "name": "priority", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", + "stability": "experimental", + "summary": "If the job queue is enabled, it is able to accept jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 53 + }, + "name": "enabled", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- no scheduling policy", + "remarks": "Instructs the Scheduler how to schedule different jobs.", + "stability": "experimental", + "summary": "The SchedulingPolicy for this JobQueue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 60 + }, + "name": "schedulingPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" + } + } + ], + "symbolId": "lib/job-queue:IJobQueue" + }, + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "remarks": "Batch will provision EC2 Instances to\nmeet the requirements of the jobs executing in this ComputeEnvironment.", + "stability": "experimental", + "summary": "Represents a Managed ComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "aws-cdk-lib.aws_ec2.IConnectable", + "aws-cdk-lib.ITaggable" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 14 + }, + "name": "IManagedComputeEnvironment", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", + "stability": "experimental", + "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 23 + }, + "name": "maxvCpus", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The security groups this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 78 + }, + "name": "securityGroups", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", + "see": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html", + "stability": "experimental", + "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 42 + }, + "name": "replaceComputeEnvironment", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", + "stability": "experimental", + "summary": "Whether or not to use spot instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 52 + }, + "name": "spot", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", + "stability": "experimental", + "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 73 + }, + "name": "terminateOnUpdate", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "30 minutes", + "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", + "stability": "experimental", + "summary": "Only meaningful if `terminateOnUpdate` is `false`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 62 + }, + "name": "updateTimeout", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "If you specify a specific AMI, this property will be ignored.", + "stability": "experimental", + "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 93 + }, + "name": "updateToLatestImageVersion", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The VPC Subnets this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 83 + }, + "name": "vpcSubnets", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.SubnetSelection" + } + } + ], + "symbolId": "lib/managed-compute-environment:IManagedComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 235 + }, + "methods": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Add an instance class to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 348 + }, + "name": "addInstanceClass", + "parameters": [ + { + "name": "instanceClass", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + } + } + ] + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Add an instance type to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 343 + }, + "name": "addInstanceType", + "parameters": [ + { + "name": "instanceType", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + } + } + ] + } + ], + "name": "IManagedEc2EcsComputeEnvironment", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the size.", + "stability": "experimental", + "summary": "The instance classes that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 287 + }, + "name": "instanceClasses", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 280 + }, + "name": "instanceTypes", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", + "stability": "experimental", + "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 253 + }, + "name": "allocationStrategy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" + } + }, + { + "abstract": true, + "docs": { + "default": "- ECS_AL2 compatible AMI ids for non-GPU instances, ECS_AL2_NVIDIA compatible AMI ids for GPU instances", + "remarks": "Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches.", + "stability": "experimental", + "summary": "Configure which AMIs this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 244 + }, + "name": "images", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- a role will be created", + "stability": "experimental", + "summary": "The execution Role that instances launched by this Compute Environment will use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 304 + }, + "name": "instanceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "no launch template", + "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", + "stability": "experimental", + "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 317 + }, + "name": "launchTemplate", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" + } + }, + { + "abstract": true, + "docs": { + "default": "0", + "stability": "experimental", + "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 325 + }, + "name": "minvCpus", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no placement group", + "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", + "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", + "stability": "experimental", + "summary": "The EC2 placement group to associate with your compute resources." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 338 + }, + "name": "placementGroup", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" + } + }, + { + "abstract": true, + "docs": { + "default": "- 100%", + "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.", + "stability": "experimental", + "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 265 + }, + "name": "spotBidPercentage", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- a new Role will be created", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html", + "stability": "experimental", + "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 274 + }, + "name": "spotFleetRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", + "stability": "experimental", + "summary": "Whether or not to use batch's optimal instance type." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 297 + }, + "name": "useOptimalInstanceClasses", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:IManagedEc2EcsComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.ISchedulingPolicy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "remarks": "Scheduling Policies tell the Batch\nJob Scheduler how to schedule incoming jobs.", + "stability": "experimental", + "summary": "Represents a Scheduling Policy." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", + "interfaces": [ + "aws-cdk-lib.IResource" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 9 + }, + "name": "ISchedulingPolicy", + "properties": [ + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The arn of this scheduling policy." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 22 + }, + "name": "schedulingPolicyArn", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "custom": { + "attribute": "true" + }, + "stability": "experimental", + "summary": "The name of this scheduling policy." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 15 + }, + "name": "schedulingPolicyName", + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/scheduling-policy:ISchedulingPolicy" + }, + "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "remarks": "Batch will not provision instances on your behalf\nin this ComputeEvironment.", + "stability": "experimental", + "summary": "Represents an UnmanagedComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 11 + }, + "name": "IUnmanagedComputeEnvironment", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", + "stability": "experimental", + "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 19 + }, + "name": "unmanagedvCPUs", + "optional": true, + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/unmanaged-compute-environment:IUnmanagedComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.ImagePullPolicy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Determines when the image is pulled from the registry to launch a container." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy", + "kind": "enum", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 256 + }, + "members": [ + { + "docs": { + "remarks": "If the kubelet has a container image with that exact digest cached locally,\nthe kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest,\nand uses that image to launch the container.", + "see": "https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier", + "stability": "experimental", + "summary": "Every time the kubelet launches a container, the kubelet queries the container image registry to resolve the name to an image digest." + }, + "name": "ALWAYS" + }, + { + "docs": { + "stability": "experimental", + "summary": "The image is pulled only if it is not already present locally." + }, + "name": "IF_NOT_PRESENT" + }, + { + "docs": { + "remarks": "If the image is somehow already present locally,\nthe kubelet attempts to start the container; otherwise, startup fails.\nSee pre-pulled images for more details.", + "see": "https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images", + "stability": "experimental", + "summary": "The kubelet does not try fetching the image." + }, + "name": "NEVER" + } + ], + "name": "ImagePullPolicy", + "symbolId": "lib/eks-container-definition:ImagePullPolicy" + }, + "@aws-cdk/aws-batch-alpha.JobDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props common to all JobDefinitions." + }, + "fqn": "@aws-cdk/aws-batch-alpha.JobDefinitionProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 76 + }, + "name": "JobDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- generated by CloudFormation", + "stability": "experimental", + "summary": "The name of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 82 + }, + "name": "jobDefinitionName", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters", + "stability": "experimental", + "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 93 + }, + "name": "parameters", + "optional": true, + "type": { + "collection": { + "elementtype": { + "primitive": "any" + }, + "kind": "map" + } + } + }, + { + "abstract": true, + "docs": { + "default": "1", + "remarks": "The job is retried on failure the same number of attempts as the value.", + "stability": "experimental", + "summary": "The number of times to retry a job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 101 + }, + "name": "retryAttempts", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no `RetryStrategy`", + "stability": "experimental", + "summary": "Defines the retry behavior for this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 108 + }, + "name": "retryStrategies", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", + "stability": "experimental", + "summary": "The priority of this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 117 + }, + "name": "schedulingPriority", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no timeout", + "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", + "stability": "experimental", + "summary": "The timeout time for jobs that are submitted with this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 126 + }, + "name": "timeout", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/job-definition-base:JobDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.JobQueue": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "remarks": "Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked.", + "stability": "experimental", + "summary": "JobQueues can receive Jobs, which are removed from the queue when sent to the linked ComputeEnvironment(s) to be executed." + }, + "fqn": "@aws-cdk/aws-batch-alpha.JobQueue", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 171 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.JobQueueProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IJobQueue" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 143 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "refer to an existing JobQueue by its arn." + }, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 147 + }, + "name": "fromJobQueueArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "jobQueueArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue" + } + }, + "static": true + }, + { + "docs": { + "remarks": "The Queue will prefer lower-order `ComputeEnvironment`s.", + "stability": "experimental", + "summary": "Add a `ComputeEnvironment` to this Queue." + }, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 206 + }, + "name": "addComputeEnvironment", + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "parameters": [ + { + "name": "computeEnvironment", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + } + }, + { + "name": "order", + "type": { + "primitive": "number" + } + } + ] + } + ], + "name": "JobQueue", + "properties": [ + { + "docs": { + "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", + "stability": "experimental", + "summary": "The set of compute environments mapped to a job queue and their order relative to each other." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 163 + }, + "name": "computeEnvironments", + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 168 + }, + "name": "jobQueueArn", + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", + "stability": "experimental", + "summary": "The name of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 169 + }, + "name": "jobQueueName", + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1.", + "stability": "experimental", + "summary": "The priority of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 164 + }, + "name": "priority", + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", + "stability": "experimental", + "summary": "If the job queue is enabled, it is able to accept jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 165 + }, + "name": "enabled", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "Instructs the Scheduler how to schedule different jobs.", + "stability": "experimental", + "summary": "The SchedulingPolicy for this JobQueue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 166 + }, + "name": "schedulingPolicy", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" + } + } + ], + "symbolId": "lib/job-queue:JobQueue" + }, + "@aws-cdk/aws-batch-alpha.JobQueueProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure a JobQueue." + }, + "fqn": "@aws-cdk/aws-batch-alpha.JobQueueProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 72 + }, + "name": "JobQueueProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", + "stability": "experimental", + "summary": "The set of compute environments mapped to a job queue and their order relative to each other." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 86 + }, + "name": "computeEnvironments", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", + "stability": "experimental", + "summary": "If the job queue is enabled, it is able to accept jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 112 + }, + "name": "enabled", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "- no name", + "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", + "stability": "experimental", + "summary": "The name of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 104 + }, + "name": "jobQueueName", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "1", + "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority of 10 is given scheduling preference over a job queue with a priority of 1.", + "stability": "experimental", + "summary": "The priority of the job queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 96 + }, + "name": "priority", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no scheduling policy", + "remarks": "Instructs the Scheduler how to schedule different jobs.", + "stability": "experimental", + "summary": "The SchedulingPolicy for this JobQueue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 119 + }, + "name": "schedulingPolicy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" + } + } + ], + "symbolId": "lib/job-queue:JobQueueProps" + }, + "@aws-cdk/aws-batch-alpha.LinuxParameters": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "constructs.Construct", + "docs": { + "stability": "experimental", + "summary": "Linux-specific options that are applied to the container." + }, + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters", + "initializer": { + "docs": { + "stability": "experimental", + "summary": "Constructs a new instance of the LinuxParameters class." + }, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 87 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParametersProps" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 53 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Adds one or more host devices to a container." + }, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 111 + }, + "name": "addDevices", + "parameters": [ + { + "name": "device", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Device" + }, + "variadic": true + } + ], + "variadic": true + }, + { + "docs": { + "remarks": "Only works with EC2 launch type.", + "stability": "experimental", + "summary": "Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container." + }, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 120 + }, + "name": "addTmpfs", + "parameters": [ + { + "name": "tmpfs", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs" + }, + "variadic": true + } + ], + "variadic": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Renders the Linux parameters to the Batch version of this resource, which does not have 'capabilities' and requires tmpfs.containerPath to be defined." + }, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 128 + }, + "name": "renderLinuxParameters", + "returns": { + "type": { + "fqn": "aws-cdk-lib.aws_batch.CfnJobDefinition.LinuxParametersProperty" + } + } + } + ], + "name": "LinuxParameters", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "Device mounts." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 77 + }, + "name": "devices", + "protected": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Device" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "TmpFs mounts." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 82 + }, + "name": "tmpfs", + "protected": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Whether the init process is enabled." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 57 + }, + "name": "initProcessEnabled", + "optional": true, + "protected": true, + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The max swap memory." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 67 + }, + "name": "maxSwap", + "optional": true, + "protected": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "remarks": "Not valid for Fargate launch type", + "stability": "experimental", + "summary": "The shared memory size (in MiB)." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 62 + }, + "name": "sharedMemorySize", + "optional": true, + "protected": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The swappiness behavior." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 72 + }, + "name": "swappiness", + "optional": true, + "protected": true, + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/linux-parameters:LinuxParameters" + }, + "@aws-cdk/aws-batch-alpha.LinuxParametersProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "The properties for defining Linux-specific options that are applied to the container." + }, + "fqn": "@aws-cdk/aws-batch-alpha.LinuxParametersProps", + "kind": "interface", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 8 + }, + "name": "LinuxParametersProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Specifies whether to run an init process inside the container that forwards signals and reaps processes." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 14 + }, + "name": "initProcessEnabled", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "No swap.", + "remarks": "This parameter\nwill be translated to the --memory-swap option to docker run.\n\nThis parameter is only supported when you are using the EC2 launch type.\nAccepted values are positive integers.", + "stability": "experimental", + "summary": "The total amount of swap memory a container can use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 32 + }, + "name": "maxSwap", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "No shared memory.", + "stability": "experimental", + "summary": "The value for the size of the /dev/shm volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 21 + }, + "name": "sharedMemorySize", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "60", + "remarks": "This parameter\nmaps to the --memory-swappiness option to docker run. The swappiness relates\nto the kernel's tendency to swap memory. A value of 0 will cause swapping to\nnot happen unless absolutely necessary. A value of 100 will cause pages to\nbe swapped very aggressively.\n\nThis parameter is only supported when you are using the EC2 launch type.\nAccepted values are whole numbers between 0 and 100. If a value is not\nspecified for maxSwap then this parameter is ignored.", + "stability": "experimental", + "summary": "This allows you to tune a container's memory swappiness behavior." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 47 + }, + "name": "swappiness", + "optional": true, + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/linux-parameters:LinuxParametersProps" + }, + "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for a ManagedComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 99 + }, + "name": "ManagedComputeEnvironmentProps", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "VPC in which this Compute Environment will launch Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 169 + }, + "name": "vpc", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IVpc" + } + }, + { + "abstract": true, + "docs": { + "default": "256", + "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", + "stability": "experimental", + "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to. Each vCPU is equivalent to 1024 CPU shares." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 111 + }, + "name": "maxvCpus", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", + "see": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html", + "stability": "experimental", + "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 132 + }, + "name": "replaceComputeEnvironment", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "new security groups will be created", + "stability": "experimental", + "summary": "The security groups this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 176 + }, + "name": "securityGroups", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", + "stability": "experimental", + "summary": "Whether or not to use spot instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 142 + }, + "name": "spot", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", + "stability": "experimental", + "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 164 + }, + "name": "terminateOnUpdate", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "30 minutes", + "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", + "stability": "experimental", + "summary": "Only meaningful if `terminateOnUpdate` is `false`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 153 + }, + "name": "updateTimeout", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "If you specify a specific AMI, this property will be ignored.", + "stability": "experimental", + "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 193 + }, + "name": "updateToLatestImageVersion", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "abstract": true, + "docs": { + "default": "new subnets will be created", + "stability": "experimental", + "summary": "The VPC Subnets this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 183 + }, + "name": "vpcSubnets", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.SubnetSelection" + } + } + ], + "symbolId": "lib/managed-compute-environment:ManagedComputeEnvironmentProps" + }, + "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::ComputeEnvironment" + }, + "stability": "experimental", + "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 635 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 588 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "refer to an existing ComputeEnvironment by its arn." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 592 + }, + "name": "fromManagedEc2EcsComputeEnvironmentArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "managedEc2EcsComputeEnvironmentArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Add an instance class to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 705 + }, + "name": "addInstanceClass", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "parameters": [ + { + "name": "instanceClass", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + } + } + ] + }, + { + "docs": { + "stability": "experimental", + "summary": "Add an instance type to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 701 + }, + "name": "addInstanceType", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "parameters": [ + { + "name": "instanceType", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + } + } + ] + } + ], + "name": "ManagedEc2EcsComputeEnvironment", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this compute environment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 619 + }, + "name": "computeEnvironmentArn", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 620 + }, + "name": "computeEnvironmentName", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The network connections associated with this resource." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 210 + }, + "name": "connections", + "overrides": "aws-cdk-lib.aws_ec2.IConnectable", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.Connections" + } + }, + { + "docs": { + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 92 + }, + "name": "enabled", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the size.", + "stability": "experimental", + "summary": "The instance classes that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 627 + }, + "name": "instanceClasses", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 626 + }, + "name": "instanceTypes", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", + "stability": "experimental", + "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 201 + }, + "name": "maxvCpus", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The security groups this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 206 + }, + "name": "securityGroups", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "TagManager to set, remove and format tags." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 208 + }, + "name": "tags", + "overrides": "aws-cdk-lib.ITaggable", + "type": { + "fqn": "aws-cdk-lib.TagManager" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 623 + }, + "name": "allocationStrategy", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" + } + }, + { + "docs": { + "remarks": "Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches.", + "stability": "experimental", + "summary": "Configure which AMIs this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 622 + }, + "name": "images", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The execution Role that instances launched by this Compute Environment will use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 628 + }, + "name": "instanceRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", + "stability": "experimental", + "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 629 + }, + "name": "launchTemplate", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 630 + }, + "name": "minvCpus", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", + "stability": "experimental", + "summary": "The EC2 placement group to associate with your compute resources." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 631 + }, + "name": "placementGroup", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" + } + }, + { + "docs": { + "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", + "stability": "experimental", + "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 202 + }, + "name": "replaceComputeEnvironment", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 91 + }, + "name": "serviceRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", + "stability": "experimental", + "summary": "Whether or not to use spot instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 203 + }, + "name": "spot", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.", + "stability": "experimental", + "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 624 + }, + "name": "spotBidPercentage", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 625 + }, + "name": "spotFleetRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", + "stability": "experimental", + "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 205 + }, + "name": "terminateOnUpdate", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", + "stability": "experimental", + "summary": "Only meaningful if `terminateOnUpdate` is `false`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 204 + }, + "name": "updateTimeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "docs": { + "remarks": "If you specify a specific AMI, this property will be ignored.", + "stability": "experimental", + "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 207 + }, + "name": "updateToLatestImageVersion", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:ManagedEc2EcsComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for a ManagedEc2EcsComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 469 + }, + "name": "ManagedEc2EcsComputeEnvironmentProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", + "stability": "experimental", + "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 499 + }, + "name": "allocationStrategy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" + } + }, + { + "abstract": true, + "docs": { + "default": "- ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances", + "remarks": "If you specify this property with only `image` specified, then the\n`imageType` will default to `ECS_AL2`. *If your image needs GPU resources,\nspecify `ECS_AL2_NVIDIA`; otherwise, the instances will not be able to properly\njoin the ComputeEnvironment*.", + "stability": "experimental", + "summary": "Configure which AMIs this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 490 + }, + "name": "images", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the instance size.", + "stability": "experimental", + "summary": "The instance classes that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 539 + }, + "name": "instanceClasses", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- a role will be created", + "stability": "experimental", + "summary": "The execution Role that instances launched by this Compute Environment will use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 546 + }, + "name": "instanceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 530 + }, + "name": "instanceTypes", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "no launch template", + "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", + "stability": "experimental", + "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 559 + }, + "name": "launchTemplate", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" + } + }, + { + "abstract": true, + "docs": { + "default": "0", + "stability": "experimental", + "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 567 + }, + "name": "minvCpus", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no placement group", + "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", + "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", + "stability": "experimental", + "summary": "The EC2 placement group to associate with your compute resources." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 580 + }, + "name": "placementGroup", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" + } + }, + { + "abstract": true, + "docs": { + "default": "100%", + "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", + "stability": "experimental", + "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 513 + }, + "name": "spotBidPercentage", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- a new role will be created", + "see": "https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html", + "stability": "experimental", + "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 522 + }, + "name": "spotFleetRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", + "stability": "experimental", + "summary": "Whether or not to use batch's optimal instance type." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 478 + }, + "name": "useOptimalInstanceClasses", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:ManagedEc2EcsComputeEnvironmentProps" + }, + "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::ComputeEnvironment" + }, + "stability": "experimental", + "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 982 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 963 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Add an instance class to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1052 + }, + "name": "addInstanceClass", + "parameters": [ + { + "name": "instanceClass", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + } + } + ] + }, + { + "docs": { + "stability": "experimental", + "summary": "Add an instance type to this compute environment." + }, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 1048 + }, + "name": "addInstanceType", + "parameters": [ + { + "name": "instanceType", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + } + } + ] + } + ], + "name": "ManagedEc2EksComputeEnvironment", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this compute environment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 968 + }, + "name": "computeEnvironmentArn", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 967 + }, + "name": "computeEnvironmentName", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The network connections associated with this resource." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 210 + }, + "name": "connections", + "overrides": "aws-cdk-lib.aws_ec2.IConnectable", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.Connections" + } + }, + { + "docs": { + "remarks": "Please ensure that you have followed the steps at\n\nhttps://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html\n\nbefore attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster.\nIf you do not follow the steps in the link, the deployment fail with a message that the\ncompute environment did not stabilize.", + "stability": "experimental", + "summary": "The cluster that backs this Compute Environment. Required for Compute Environments running Kubernetes jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 965 + }, + "name": "eksCluster", + "type": { + "fqn": "aws-cdk-lib.aws_eks.ICluster" + } + }, + { + "docs": { + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 92 + }, + "name": "enabled", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 974 + }, + "name": "instanceClasses", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 973 + }, + "name": "instanceTypes", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", + "stability": "experimental", + "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 201 + }, + "name": "maxvCpus", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The security groups this Compute Environment will launch instances in." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 206 + }, + "name": "securityGroups", + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "TagManager to set, remove and format tags." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 208 + }, + "name": "tags", + "overrides": "aws-cdk-lib.ITaggable", + "type": { + "fqn": "aws-cdk-lib.TagManager" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 971 + }, + "name": "allocationStrategy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Configure which AMIs this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 970 + }, + "name": "images", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The execution Role that instances launched by this Compute Environment will use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 975 + }, + "name": "instanceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "Cannot be 'default', start with 'kube-', or be longer than 64 characters.", + "stability": "experimental", + "summary": "The namespace of the Cluster." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 964 + }, + "name": "kubernetesNamespace", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", + "stability": "experimental", + "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 976 + }, + "name": "launchTemplate", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 977 + }, + "name": "minvCpus", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", + "stability": "experimental", + "summary": "The EC2 placement group to associate with your compute resources." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 978 + }, + "name": "placementGroup", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" + } + }, + { + "docs": { + "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", + "stability": "experimental", + "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 202 + }, + "name": "replaceComputeEnvironment", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 91 + }, + "name": "serviceRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", + "stability": "experimental", + "summary": "Whether or not to use spot instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 203 + }, + "name": "spot", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", + "stability": "experimental", + "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 972 + }, + "name": "spotBidPercentage", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", + "stability": "experimental", + "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 205 + }, + "name": "terminateOnUpdate", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", + "stability": "experimental", + "summary": "Only meaningful if `terminateOnUpdate` is `false`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 204 + }, + "name": "updateTimeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + }, + { + "docs": { + "remarks": "If you specify a specific AMI, this property will be ignored.", + "stability": "experimental", + "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 207 + }, + "name": "updateToLatestImageVersion", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:ManagedEc2EksComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props for a ManagedEc2EksComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 835 + }, + "name": "ManagedEc2EksComputeEnvironmentProps", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "Please ensure that you have followed the steps at\n\nhttps://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html\n\nbefore attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster.\nIf you do not follow the steps in the link, the deployment fail with a message that the\ncompute environment did not stabilize.", + "stability": "experimental", + "summary": "The cluster that backs this Compute Environment. Required for Compute Environments running Kubernetes jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 853 + }, + "name": "eksCluster", + "type": { + "fqn": "aws-cdk-lib.aws_eks.ICluster" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The namespace of the Cluster." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 839 + }, + "name": "kubernetesNamespace", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", + "stability": "experimental", + "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 883 + }, + "name": "allocationStrategy", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" + } + }, + { + "abstract": true, + "docs": { + "default": "If `imageKubernetesVersion` is specified,\n- EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances,\nOtherwise,\n- ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances,", + "stability": "experimental", + "summary": "Configure which AMIs this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 874 + }, + "name": "images", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the instance size.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 914 + }, + "name": "instanceClasses", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- a role will be created", + "stability": "experimental", + "summary": "The execution Role that instances launched by this Compute Environment will use." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 921 + }, + "name": "instanceRole", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "abstract": true, + "docs": { + "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", + "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", + "stability": "experimental", + "summary": "The instance types that this Compute Environment can launch." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 905 + }, + "name": "instanceTypes", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "- no launch template", + "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.**", + "stability": "experimental", + "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 934 + }, + "name": "launchTemplate", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" + } + }, + { + "abstract": true, + "docs": { + "default": "0", + "stability": "experimental", + "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 942 + }, + "name": "minvCpus", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "- no placement group", + "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", + "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", + "stability": "experimental", + "summary": "The EC2 placement group to associate with your compute resources." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 955 + }, + "name": "placementGroup", + "optional": true, + "type": { + "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" + } + }, + { + "abstract": true, + "docs": { + "default": "- 100%", + "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", + "stability": "experimental", + "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 897 + }, + "name": "spotBidPercentage", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", + "stability": "experimental", + "summary": "Whether or not to use batch's optimal instance type." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/managed-compute-environment.ts", + "line": 863 + }, + "name": "useOptimalInstanceClasses", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/managed-compute-environment:ManagedEc2EksComputeEnvironmentProps" + }, + "@aws-cdk/aws-batch-alpha.MultiNodeContainer": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Runs the container on nodes [startNode, endNode]." + }, + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer", + "kind": "interface", + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 47 + }, + "name": "MultiNodeContainer", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The container that this node range will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 65 + }, + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" + } + }, + { + "abstract": true, + "docs": { + "remarks": "The container is run on all nodes in the range [startNode, endNode] (inclusive)", + "stability": "experimental", + "summary": "The index of the last node to run this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 60 + }, + "name": "endNode", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "remarks": "The container is run on all nodes in the range [startNode, endNode] (inclusive)", + "stability": "experimental", + "summary": "The index of the first node to run this container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 53 + }, + "name": "startNode", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/multinode-job-definition:MultiNodeContainer" + }, + "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::JobDefinition" + }, + "stability": "experimental", + "summary": "A JobDefinition that uses Ecs orchestration to run multiple containers." + }, + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 134 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IJobDefinition" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 109 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "refer to an existing JobDefinition by its arn." + }, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 113 + }, + "name": "fromJobDefinitionArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "jobDefinitionArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a container to this multinode job." + }, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 174 + }, + "name": "addContainer", + "parameters": [ + { + "name": "container", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" + } + } + ] + }, + { + "docs": { + "stability": "experimental", + "summary": "Add a RetryStrategy to this JobDefinition." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 259 + }, + "name": "addRetryStrategy", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "parameters": [ + { + "name": "strategy", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + } + } + ] + } + ], + "name": "MultiNodeJobDefinition", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The containers that this multinode job will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 126 + }, + "name": "containers", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" + }, + "kind": "array" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The instance type that this job definition will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 127 + }, + "name": "instanceType", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 131 + }, + "name": "jobDefinitionArn", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 132 + }, + "name": "jobDefinitionName", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Defines the retry behavior for this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 243 + }, + "name": "retryStrategies", + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + }, + "kind": "array" + } + } + }, + { + "docs": { + "remarks": "The main node is responsible for orchestration.", + "stability": "experimental", + "summary": "The index of the main node in this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 128 + }, + "name": "mainNode", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 241 + }, + "name": "parameters", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "collection": { + "elementtype": { + "primitive": "any" + }, + "kind": "map" + } + } + }, + { + "docs": { + "stability": "experimental", + "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 129 + }, + "name": "propagateTags", + "optional": true, + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "remarks": "The job is retried on failure the same number of attempts as the value.", + "stability": "experimental", + "summary": "The number of times to retry a job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 242 + }, + "name": "retryAttempts", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", + "stability": "experimental", + "summary": "The priority of this Job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 244 + }, + "name": "schedulingPriority", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "primitive": "number" + } + }, + { + "docs": { + "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", + "stability": "experimental", + "summary": "The timeout time for jobs that are submitted with this job definition." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 245 + }, + "name": "timeout", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", + "type": { + "fqn": "aws-cdk-lib.Duration" + } + } + ], + "symbolId": "lib/multinode-job-definition:MultiNodeJobDefinition" + }, + "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Props to configure a MultiNodeJobDefinition." + }, + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.JobDefinitionProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 71 + }, + "name": "MultiNodeJobDefinitionProps", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The instance type that this job definition will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 76 + }, + "name": "instanceType", + "type": { + "fqn": "aws-cdk-lib.aws_ec2.InstanceType" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "see": "https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/", + "stability": "experimental", + "summary": "The containers that this multinode job will run." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 85 + }, + "name": "containers", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" + }, + "kind": "array" + } + } + }, + { + "abstract": true, + "docs": { + "default": "0", + "remarks": "The main node is responsible for orchestration.", + "stability": "experimental", + "summary": "The index of the main node in this job." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 93 + }, + "name": "mainNode", + "optional": true, + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "default": "false", + "stability": "experimental", + "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/multinode-job-definition.ts", + "line": 101 + }, + "name": "propagateTags", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/multinode-job-definition:MultiNodeJobDefinitionProps" + }, + "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "remarks": "The JobQueue will prioritize the lowest-order ComputeEnvironment.", + "stability": "experimental", + "summary": "Assigns an order to a ComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment", + "kind": "interface", + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 126 + }, + "name": "OrderedComputeEnvironment", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The ComputeEnvironment to link to this JobQueue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 130 + }, + "name": "computeEnvironment", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The order associated with `computeEnvironment`." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-queue.ts", + "line": 135 + }, + "name": "order", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/job-queue:OrderedComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.Reason": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Common job exit reasons." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Reason", + "initializer": { + "docs": { + "stability": "experimental" + } + }, + "kind": "class", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 201 + }, + "methods": [ + { + "docs": { + "remarks": "Note that all specified conditions must be met for this reason to match.", + "stability": "experimental", + "summary": "A custom Reason that can match on multiple conditions." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 227 + }, + "name": "custom", + "parameters": [ + { + "name": "customReasonProps", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.CustomReason" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + }, + "static": true + } + ], + "name": "Reason", + "properties": [ + { + "const": true, + "docs": { + "stability": "experimental", + "summary": "Will only match if the Docker container could not be pulled." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 212 + }, + "name": "CANNOT_PULL_CONTAINER", + "static": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + }, + { + "const": true, + "docs": { + "stability": "experimental", + "summary": "Will match any non-zero exit code." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 205 + }, + "name": "NON_ZERO_EXIT_CODE", + "static": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + }, + { + "const": true, + "docs": { + "stability": "experimental", + "summary": "Will only match if the Spot instance executing the job was reclaimed." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 219 + }, + "name": "SPOT_INSTANCE_RECLAIMED", + "static": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + } + ], + "symbolId": "lib/job-definition-base:Reason" + }, + "@aws-cdk/aws-batch-alpha.RetryStrategy": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "Define how Jobs using this JobDefinition respond to different exit conditions." + }, + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 150 + }, + "parameters": [ + { + "name": "action", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Action" + } + }, + { + "name": "on", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 132 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Create a new RetryStrategy." + }, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 136 + }, + "name": "of", + "parameters": [ + { + "name": "action", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Action" + } + }, + { + "name": "on", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" + } + }, + "static": true + } + ], + "name": "RetryStrategy", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The action to take when the job exits with the Reason specified." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 143 + }, + "name": "action", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Action" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "If the job exits with this Reason it will trigger the specified Action." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/job-definition-base.ts", + "line": 148 + }, + "name": "on", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Reason" + } + } + ], + "symbolId": "lib/job-definition-base:RetryStrategy" + }, + "@aws-cdk/aws-batch-alpha.Secret": { + "abstract": true, + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "A secret environment variable." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Secret", + "initializer": { + "docs": { + "stability": "experimental" + } + }, + "kind": "class", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 36 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Creates a environment variable value from a secret stored in AWS Secrets Manager." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 58 + }, + "name": "fromSecretsManager", + "parameters": [ + { + "docs": { + "summary": "the secret stored in AWS Secrets Manager." + }, + "name": "secret", + "type": { + "fqn": "aws-cdk-lib.aws_secretsmanager.ISecret" + } + }, + { + "docs": { + "remarks": "Only values in JSON format are supported.\nIf you do not specify a JSON field, then the full content of the secret is\nused.", + "summary": "the name of the field with the value that you want to set as the environment variable value." + }, + "name": "field", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Creates a environment variable value from a secret stored in AWS Secrets Manager." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 77 + }, + "name": "fromSecretsManagerVersion", + "parameters": [ + { + "docs": { + "summary": "the secret stored in AWS Secrets Manager." + }, + "name": "secret", + "type": { + "fqn": "aws-cdk-lib.aws_secretsmanager.ISecret" + } + }, + { + "docs": { + "summary": "the version information to reference the secret." + }, + "name": "versionInfo", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.SecretVersionInfo" + } + }, + { + "docs": { + "remarks": "Only values in JSON format are supported.\nIf you do not specify a JSON field, then the full content of the secret is\nused.", + "summary": "the name of the field with the value that you want to set as the environment variable value." + }, + "name": "field", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + } + }, + "static": true + }, + { + "docs": { + "stability": "experimental", + "summary": "Creates an environment variable value from a parameter stored in AWS Systems Manager Parameter Store." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 41 + }, + "name": "fromSsmParameter", + "parameters": [ + { + "name": "parameter", + "type": { + "fqn": "aws-cdk-lib.aws_ssm.IParameter" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.Secret" + } + }, + "static": true + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Grants reading the secret to a principal." + }, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 98 + }, + "name": "grantRead", + "parameters": [ + { + "name": "grantee", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IGrantable" + } + } + ], + "returns": { + "type": { + "fqn": "aws-cdk-lib.aws_iam.Grant" + } + } + } + ], + "name": "Secret", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The ARN of the secret." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 88 + }, + "name": "arn", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "Whether this secret uses a specific JSON field." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 93 + }, + "name": "hasField", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/ecs-container-definition:Secret" + }, + "@aws-cdk/aws-batch-alpha.SecretPathVolume": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "@aws-cdk/aws-batch-alpha.EksVolume", + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", + "stability": "experimental", + "summary": "Specifies the configuration of a Kubernetes secret volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolume", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 902 + }, + "parameters": [ + { + "name": "options", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions" + } + } + ] + }, + "kind": "class", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 879 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "returns `true` if `x` is a `SecretPathVolume` and `false` otherwise." + }, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 883 + }, + "name": "isSecretPathVolume", + "parameters": [ + { + "name": "x", + "type": { + "primitive": "any" + } + } + ], + "returns": { + "type": { + "primitive": "boolean" + } + }, + "static": true + } + ], + "name": "SecretPathVolume", + "properties": [ + { + "docs": { + "remarks": "Must be a valid DNS subdomain name.", + "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", + "stability": "experimental", + "summary": "The name of the secret." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 893 + }, + "name": "secretName", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "default": "true", + "stability": "experimental", + "summary": "Specifies whether the secret or the secret's keys must be defined." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 900 + }, + "name": "optional", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-container-definition:SecretPathVolume" + }, + "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", + "stability": "experimental", + "summary": "Options for a Kubernetes SecretPath Volume." + }, + "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.EksVolumeOptions" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 857 + }, + "name": "SecretPathVolumeOptions", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "Must be a valid DNS subdomain name.", + "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", + "stability": "experimental", + "summary": "The name of the secret." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 864 + }, + "name": "secretName", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "true", + "stability": "experimental", + "summary": "Specifies whether the secret or the secret's keys must be defined." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/eks-container-definition.ts", + "line": 871 + }, + "name": "optional", + "optional": true, + "type": { + "primitive": "boolean" + } + } + ], + "symbolId": "lib/eks-container-definition:SecretPathVolumeOptions" + }, + "@aws-cdk/aws-batch-alpha.SecretVersionInfo": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "Specify the secret's version id or version stage." + }, + "fqn": "@aws-cdk/aws-batch-alpha.SecretVersionInfo", + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 18 + }, + "name": "SecretVersionInfo", + "properties": [ + { + "abstract": true, + "docs": { + "default": "- use default version id", + "stability": "experimental", + "summary": "version id of the secret." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 24 + }, + "name": "versionId", + "optional": true, + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "default": "- use default version stage", + "stability": "experimental", + "summary": "version stage of the secret." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 30 + }, + "name": "versionStage", + "optional": true, + "type": { + "primitive": "string" + } + } + ], + "symbolId": "lib/ecs-container-definition:SecretVersionInfo" + }, + "@aws-cdk/aws-batch-alpha.Share": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "remarks": "All Job Definitions that\ndeclare a share identifier will be considered members of the Share\ndefined by that share identifier.\n\nThe Scheduler divides the maximum available vCPUs of the ComputeEnvironment\namong Jobs in the Queue based on their shareIdentifier and the weightFactor\nassociated with that shareIdentifier.", + "stability": "experimental", + "summary": "Represents a group of Job Definitions." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Share", + "kind": "interface", + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 60 + }, + "name": "Share", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "All jobs that specify this share identifier\nwhen submitted to the queue will be considered as part of this Share.", + "stability": "experimental", + "summary": "The identifier of this Share." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 65 + }, + "name": "shareIdentifier", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "remarks": "The Scheduler decides which jobs to put in the Compute Environment\nsuch that the following ratio is equal for each job:\n\n`sharevCpu / weightFactor`,\n\nwhere `sharevCpu` is the total amount of vCPU given to that particular share; that is,\nthe sum of the vCPU of each job currently in the Compute Environment for that share.\n\nSee the readme of this module for a detailed example that shows how these are used,\nhow it relates to `computeReservation`, and how `shareDecay` affects these calculations.", + "stability": "experimental", + "summary": "The weight factor given to this Share." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/scheduling-policy.ts", + "line": 79 + }, + "name": "weightFactor", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/scheduling-policy:Share" + }, + "@aws-cdk/aws-batch-alpha.Tmpfs": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "stability": "experimental", + "summary": "The details of a tmpfs mount for a container." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs", + "kind": "interface", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 168 + }, + "name": "Tmpfs", + "properties": [ + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The absolute file path where the tmpfs volume is to be mounted." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 172 + }, + "name": "containerPath", + "type": { + "primitive": "string" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The size (in MiB) of the tmpfs volume." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 177 + }, + "name": "size", + "type": { + "fqn": "aws-cdk-lib.Size" + } + }, + { + "abstract": true, + "docs": { + "default": "none", + "remarks": "For more information, see\n[TmpfsMountOptions](https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_Tmpfs.html).", + "stability": "experimental", + "summary": "The list of tmpfs volume mount options." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 185 + }, + "name": "mountOptions", + "optional": true, + "type": { + "collection": { + "elementtype": { + "fqn": "@aws-cdk/aws-batch-alpha.TmpfsMountOption" + }, + "kind": "array" + } + } + } + ], + "symbolId": "lib/linux-parameters:Tmpfs" + }, + "@aws-cdk/aws-batch-alpha.TmpfsMountOption": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "The supported options for a tmpfs mount for a container." + }, + "fqn": "@aws-cdk/aws-batch-alpha.TmpfsMountOption", + "kind": "enum", + "locationInModule": { + "filename": "lib/linux-parameters.ts", + "line": 211 + }, + "members": [ + { + "docs": { + "stability": "experimental" + }, + "name": "DEFAULTS" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RO" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RW" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "SUID" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NOSUID" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "DEV" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NODEV" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "EXEC" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NOEXEC" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "SYNC" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "ASYNC" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "DIRSYNC" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "REMOUNT" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "MAND" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NOMAND" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "ATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NOATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "DIRATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NODIRATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "BIND" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RBIND" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "UNBINDABLE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RUNBINDABLE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "PRIVATE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RPRIVATE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "SHARED" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RSHARED" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "SLAVE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RSLAVE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "RELATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NORELATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "STRICTATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NOSTRICTATIME" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "MODE" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "UID" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "GID" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NR_INODES" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "NR_BLOCKS" + }, + { + "docs": { + "stability": "experimental" + }, + "name": "MPOL" + } + ], + "name": "TmpfsMountOption", + "symbolId": "lib/linux-parameters:TmpfsMountOption" + }, + "@aws-cdk/aws-batch-alpha.Ulimit": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "remarks": "Used by the Docker daemon.", + "stability": "experimental", + "summary": "Sets limits for a resource with `ulimit` on linux systems." + }, + "fqn": "@aws-cdk/aws-batch-alpha.Ulimit", + "kind": "interface", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 734 + }, + "name": "Ulimit", + "properties": [ + { + "abstract": true, + "docs": { + "remarks": "The container will\nbe terminated if it exceeds this limit.", + "stability": "experimental", + "summary": "The hard limit for this resource." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 739 + }, + "name": "hardLimit", + "type": { + "primitive": "number" + } + }, + { + "abstract": true, + "docs": { + "stability": "experimental", + "summary": "The resource to limit." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 744 + }, + "name": "name", + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.UlimitName" + } + }, + { + "abstract": true, + "docs": { + "remarks": "The container will\nnot be terminated if it exceeds this limit.", + "stability": "experimental", + "summary": "The reservation for this resource." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 750 + }, + "name": "softLimit", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/ecs-container-definition:Ulimit" + }, + "@aws-cdk/aws-batch-alpha.UlimitName": { + "assembly": "@aws-cdk/aws-batch-alpha", + "docs": { + "stability": "experimental", + "summary": "The resources to be limited." + }, + "fqn": "@aws-cdk/aws-batch-alpha.UlimitName", + "kind": "enum", + "locationInModule": { + "filename": "lib/ecs-container-definition.ts", + "line": 756 + }, + "members": [ + { + "docs": { + "stability": "experimental", + "summary": "max core dump file size." + }, + "name": "CORE" + }, + { + "docs": { + "stability": "experimental", + "summary": "max cpu time (seconds) for a process." + }, + "name": "CPU" + }, + { + "docs": { + "stability": "experimental", + "summary": "max data segment size." + }, + "name": "DATA" + }, + { + "docs": { + "stability": "experimental", + "summary": "max file size." + }, + "name": "FSIZE" + }, + { + "docs": { + "stability": "experimental", + "summary": "max number of file locks." + }, + "name": "LOCKS" + }, + { + "docs": { + "stability": "experimental", + "summary": "max locked memory." + }, + "name": "MEMLOCK" + }, + { + "docs": { + "stability": "experimental", + "summary": "max POSIX message queue size." + }, + "name": "MSGQUEUE" + }, + { + "docs": { + "stability": "experimental", + "summary": "max nice value for any process this user is running." + }, + "name": "NICE" + }, + { + "docs": { + "stability": "experimental", + "summary": "maximum number of open file descriptors." + }, + "name": "NOFILE" + }, + { + "docs": { + "stability": "experimental", + "summary": "maximum number of processes." + }, + "name": "NPROC" + }, + { + "docs": { + "stability": "experimental", + "summary": "size of the process' resident set (in pages)." + }, + "name": "RSS" + }, + { + "docs": { + "stability": "experimental", + "summary": "max realtime priority." + }, + "name": "RTPRIO" + }, + { + "docs": { + "stability": "experimental", + "summary": "timeout for realtime tasks." + }, + "name": "RTTIME" + }, + { + "docs": { + "stability": "experimental", + "summary": "max number of pending signals." + }, + "name": "SIGPENDING" + }, + { + "docs": { + "stability": "experimental", + "summary": "max stack size (in bytes)." + }, + "name": "STACK" + } + ], + "name": "UlimitName", + "symbolId": "lib/ecs-container-definition:UlimitName" + }, + "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironment": { + "assembly": "@aws-cdk/aws-batch-alpha", + "base": "aws-cdk-lib.Resource", + "docs": { + "custom": { + "resource": "AWS::Batch::ComputeEnvironment" + }, + "stability": "experimental", + "summary": "Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf." + }, + "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironment", + "initializer": { + "docs": { + "stability": "experimental" + }, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 68 + }, + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "props", + "optional": true, + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps" + } + } + ] + }, + "interfaces": [ + "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", + "@aws-cdk/aws-batch-alpha.IComputeEnvironment" + ], + "kind": "class", + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 44 + }, + "methods": [ + { + "docs": { + "stability": "experimental", + "summary": "Import an UnmanagedComputeEnvironment by its arn." + }, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 48 + }, + "name": "fromUnmanagedComputeEnvironmentArn", + "parameters": [ + { + "name": "scope", + "type": { + "fqn": "constructs.Construct" + } + }, + { + "name": "id", + "type": { + "primitive": "string" + } + }, + { + "name": "unmanagedComputeEnvironmentArn", + "type": { + "primitive": "string" + } + } + ], + "returns": { + "type": { + "fqn": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment" + } + }, + "static": true + } + ], + "name": "UnmanagedComputeEnvironment", + "properties": [ + { + "docs": { + "stability": "experimental", + "summary": "The ARN of this compute environment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 65 + }, + "name": "computeEnvironmentArn", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The name of the ComputeEnvironment." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 66 + }, + "name": "computeEnvironmentName", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "string" + } + }, + { + "docs": { + "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", + "stability": "experimental", + "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 92 + }, + "name": "enabled", + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "primitive": "boolean" + } + }, + { + "docs": { + "stability": "experimental", + "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/compute-environment-base.ts", + "line": 91 + }, + "name": "serviceRole", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", + "type": { + "fqn": "aws-cdk-lib.aws_iam.IRole" + } + }, + { + "docs": { + "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", + "stability": "experimental", + "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 64 + }, + "name": "unmanagedvCPUs", + "optional": true, + "overrides": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/unmanaged-compute-environment:UnmanagedComputeEnvironment" + }, + "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps": { + "assembly": "@aws-cdk/aws-batch-alpha", + "datatype": true, + "docs": { + "remarks": "Batch will not provision instances on your behalf\nin this ComputeEvironment.", + "stability": "experimental", + "summary": "Represents an UnmanagedComputeEnvironment." + }, + "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps", + "interfaces": [ + "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps" + ], + "kind": "interface", + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 26 + }, + "name": "UnmanagedComputeEnvironmentProps", + "properties": [ + { + "abstract": true, + "docs": { + "default": "0", + "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", + "stability": "experimental", + "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." + }, + "immutable": true, + "locationInModule": { + "filename": "lib/unmanaged-compute-environment.ts", + "line": 36 + }, + "name": "unmanagedvCpus", + "optional": true, + "type": { + "primitive": "number" + } + } + ], + "symbolId": "lib/unmanaged-compute-environment:UnmanagedComputeEnvironmentProps" + } + }, + "version": "0.0.0", + "fingerprint": "oTncRAlRM55jMKT9Vxi1eKfuNXfCgiLRFVfCY18w+gM=" +} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js b/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js new file mode 100644 index 0000000000000..204b2b9e6ead6 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js @@ -0,0 +1,515 @@ +function _aws_cdk_aws_batch_alpha_IComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_ComputeEnvironmentProps(p) { +} +function _aws_cdk_aws_batch_alpha_EcsJobDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.container)) + _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p.container); + if (p.retryStrategies != null) + for (const o of p.retryStrategies) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_RetryStrategy(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EcsJobDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_IEksJobDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_EksJobDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.container)) + _aws_cdk_aws_batch_alpha_EksContainerDefinition(p.container); + if (!visitedObjects.has(p.dnsPolicy)) + _aws_cdk_aws_batch_alpha_DnsPolicy(p.dnsPolicy); + if (p.retryStrategies != null) + for (const o of p.retryStrategies) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_RetryStrategy(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_DnsPolicy(p) { +} +function _aws_cdk_aws_batch_alpha_EksJobDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_SecretVersionInfo(p) { +} +function _aws_cdk_aws_batch_alpha_Secret(p) { +} +function _aws_cdk_aws_batch_alpha_EcsVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_EcsVolume(p) { +} +function _aws_cdk_aws_batch_alpha_EfsVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_EfsVolume(p) { +} +function _aws_cdk_aws_batch_alpha_HostVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_HostVolume(p) { +} +function _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_EcsContainerDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.linuxParameters)) + _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); + if (p.secrets != null) + for (const o of Object.values(p.secrets)) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_Secret(o); + if (p.volumes != null) + for (const o of p.volumes) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EcsVolume(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_Ulimit(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.name)) + _aws_cdk_aws_batch_alpha_UlimitName(p.name); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_UlimitName(p) { +} +function _aws_cdk_aws_batch_alpha_IEcsEc2ContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.ulimits != null) + for (const o of p.ulimits) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_Ulimit(o); + if (!visitedObjects.has(p.linuxParameters)) + _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); + if (p.secrets != null) + for (const o of Object.values(p.secrets)) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_Secret(o); + if (p.volumes != null) + for (const o of p.volumes) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EcsVolume(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_IEcsFargateContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.linuxParameters)) + _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); + if (p.secrets != null) + for (const o of Object.values(p.secrets)) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_Secret(o); + if (p.volumes != null) + for (const o of p.volumes) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EcsVolume(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_IEksContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_ImagePullPolicy(p) { +} +function _aws_cdk_aws_batch_alpha_EksContainerDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.imagePullPolicy)) + _aws_cdk_aws_batch_alpha_ImagePullPolicy(p.imagePullPolicy); + if (p.volumes != null) + for (const o of p.volumes) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EksVolume(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EksContainerDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_EksVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_EksVolume(p) { +} +function _aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.medium)) + _aws_cdk_aws_batch_alpha_EmptyDirMediumType(p.medium); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EmptyDirMediumType(p) { +} +function _aws_cdk_aws_batch_alpha_EmptyDirVolume(p) { +} +function _aws_cdk_aws_batch_alpha_HostPathVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_HostPathVolume(p) { +} +function _aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(p) { +} +function _aws_cdk_aws_batch_alpha_SecretPathVolume(p) { +} +function _aws_cdk_aws_batch_alpha_IJobDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_JobDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.retryStrategies != null) + for (const o of p.retryStrategies) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_RetryStrategy(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_RetryStrategy(p) { +} +function _aws_cdk_aws_batch_alpha_Action(p) { +} +function _aws_cdk_aws_batch_alpha_CustomReason(p) { +} +function _aws_cdk_aws_batch_alpha_Reason(p) { +} +function _aws_cdk_aws_batch_alpha_IJobQueue(p) { +} +function _aws_cdk_aws_batch_alpha_JobQueueProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.computeEnvironments != null) + for (const o of p.computeEnvironments) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment(o); + if (!visitedObjects.has(p.schedulingPolicy)) + _aws_cdk_aws_batch_alpha_ISchedulingPolicy(p.schedulingPolicy); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.computeEnvironment)) + _aws_cdk_aws_batch_alpha_IComputeEnvironment(p.computeEnvironment); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_JobQueue(p) { +} +function _aws_cdk_aws_batch_alpha_LinuxParametersProps(p) { +} +function _aws_cdk_aws_batch_alpha_LinuxParameters(p) { +} +function _aws_cdk_aws_batch_alpha_Device(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.permissions != null) + for (const o of p.permissions) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_DevicePermission(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_Tmpfs(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.mountOptions != null) + for (const o of p.mountOptions) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_TmpfsMountOption(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_DevicePermission(p) { +} +function _aws_cdk_aws_batch_alpha_TmpfsMountOption(p) { +} +function _aws_cdk_aws_batch_alpha_IManagedComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_ManagedComputeEnvironmentProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.securityGroups != null) + for (const o of p.securityGroups) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_IManagedEc2EcsComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_EcsMachineImage(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.imageType)) + _aws_cdk_aws_batch_alpha_EcsMachineImageType(p.imageType); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EksMachineImage(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.imageType)) + _aws_cdk_aws_batch_alpha_EksMachineImageType(p.imageType); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_EcsMachineImageType(p) { +} +function _aws_cdk_aws_batch_alpha_EksMachineImageType(p) { +} +function _aws_cdk_aws_batch_alpha_AllocationStrategy(p) { +} +function _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.allocationStrategy)) + _aws_cdk_aws_batch_alpha_AllocationStrategy(p.allocationStrategy); + if (p.images != null) + for (const o of p.images) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EcsMachineImage(o); + if (p.instanceClasses != null) + for (const o of p.instanceClasses) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceClass(o); + if (p.instanceTypes != null) + for (const o of p.instanceTypes) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceType(o); + if (p.securityGroups != null) + for (const o of p.securityGroups) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.allocationStrategy)) + _aws_cdk_aws_batch_alpha_AllocationStrategy(p.allocationStrategy); + if (p.images != null) + for (const o of p.images) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_EksMachineImage(o); + if (p.instanceClasses != null) + for (const o of p.instanceClasses) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceClass(o); + if (p.instanceTypes != null) + for (const o of p.instanceTypes) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceType(o); + if (p.securityGroups != null) + for (const o of p.securityGroups) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_IFargateComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.securityGroups != null) + for (const o of p.securityGroups) + if (!visitedObjects.has(o)) + require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_FargateComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_MultiNodeContainer(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (!visitedObjects.has(p.container)) + _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p.container); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.containers != null) + for (const o of p.containers) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_MultiNodeContainer(o); + if (p.retryStrategies != null) + for (const o of p.retryStrategies) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_RetryStrategy(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_MultiNodeJobDefinition(p) { +} +function _aws_cdk_aws_batch_alpha_ISchedulingPolicy(p) { +} +function _aws_cdk_aws_batch_alpha_Share(p) { +} +function _aws_cdk_aws_batch_alpha_IFairshareSchedulingPolicy(p) { +} +function _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps(p) { + if (p == null) + return; + visitedObjects.add(p); + try { + if (p.shares != null) + for (const o of p.shares) + if (!visitedObjects.has(o)) + _aws_cdk_aws_batch_alpha_Share(o); + } + finally { + visitedObjects.delete(p); + } +} +function _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicy(p) { +} +function _aws_cdk_aws_batch_alpha_IUnmanagedComputeEnvironment(p) { +} +function _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps(p) { +} +function _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironment(p) { +} +function print(name, deprecationMessage) { + const deprecated = process.env.JSII_DEPRECATED; + const deprecationMode = ["warn", "fail", "quiet"].includes(deprecated) ? deprecated : "warn"; + const message = `${name} is deprecated.\n ${deprecationMessage.trim()}\n This API will be removed in the next major release.`; + switch (deprecationMode) { + case "fail": + throw new DeprecationError(message); + case "warn": + console.warn("[WARNING]", message); + break; + } +} +function getPropertyDescriptor(obj, prop) { + const descriptor = Object.getOwnPropertyDescriptor(obj, prop); + if (descriptor) { + return descriptor; + } + const proto = Object.getPrototypeOf(obj); + const prototypeDescriptor = proto && getPropertyDescriptor(proto, prop); + if (prototypeDescriptor) { + return prototypeDescriptor; + } + return {}; +} +const visitedObjects = new Set(); +class DeprecationError extends Error { + constructor(...args) { + super(...args); + Object.defineProperty(this, "name", { + configurable: false, + enumerable: true, + value: "DeprecationError", + writable: false, + }); + } +} +module.exports = { print, getPropertyDescriptor, DeprecationError, _aws_cdk_aws_batch_alpha_IComputeEnvironment, _aws_cdk_aws_batch_alpha_ComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_EcsJobDefinitionProps, _aws_cdk_aws_batch_alpha_EcsJobDefinition, _aws_cdk_aws_batch_alpha_IEksJobDefinition, _aws_cdk_aws_batch_alpha_EksJobDefinitionProps, _aws_cdk_aws_batch_alpha_DnsPolicy, _aws_cdk_aws_batch_alpha_EksJobDefinition, _aws_cdk_aws_batch_alpha_SecretVersionInfo, _aws_cdk_aws_batch_alpha_Secret, _aws_cdk_aws_batch_alpha_EcsVolumeOptions, _aws_cdk_aws_batch_alpha_EcsVolume, _aws_cdk_aws_batch_alpha_EfsVolumeOptions, _aws_cdk_aws_batch_alpha_EfsVolume, _aws_cdk_aws_batch_alpha_HostVolumeOptions, _aws_cdk_aws_batch_alpha_HostVolume, _aws_cdk_aws_batch_alpha_IEcsContainerDefinition, _aws_cdk_aws_batch_alpha_EcsContainerDefinitionProps, _aws_cdk_aws_batch_alpha_Ulimit, _aws_cdk_aws_batch_alpha_UlimitName, _aws_cdk_aws_batch_alpha_IEcsEc2ContainerDefinition, _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinition, _aws_cdk_aws_batch_alpha_IEcsFargateContainerDefinition, _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinition, _aws_cdk_aws_batch_alpha_IEksContainerDefinition, _aws_cdk_aws_batch_alpha_ImagePullPolicy, _aws_cdk_aws_batch_alpha_EksContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EksContainerDefinition, _aws_cdk_aws_batch_alpha_EksVolumeOptions, _aws_cdk_aws_batch_alpha_EksVolume, _aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions, _aws_cdk_aws_batch_alpha_EmptyDirMediumType, _aws_cdk_aws_batch_alpha_EmptyDirVolume, _aws_cdk_aws_batch_alpha_HostPathVolumeOptions, _aws_cdk_aws_batch_alpha_HostPathVolume, _aws_cdk_aws_batch_alpha_SecretPathVolumeOptions, _aws_cdk_aws_batch_alpha_SecretPathVolume, _aws_cdk_aws_batch_alpha_IJobDefinition, _aws_cdk_aws_batch_alpha_JobDefinitionProps, _aws_cdk_aws_batch_alpha_RetryStrategy, _aws_cdk_aws_batch_alpha_Action, _aws_cdk_aws_batch_alpha_CustomReason, _aws_cdk_aws_batch_alpha_Reason, _aws_cdk_aws_batch_alpha_IJobQueue, _aws_cdk_aws_batch_alpha_JobQueueProps, _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment, _aws_cdk_aws_batch_alpha_JobQueue, _aws_cdk_aws_batch_alpha_LinuxParametersProps, _aws_cdk_aws_batch_alpha_LinuxParameters, _aws_cdk_aws_batch_alpha_Device, _aws_cdk_aws_batch_alpha_Tmpfs, _aws_cdk_aws_batch_alpha_DevicePermission, _aws_cdk_aws_batch_alpha_TmpfsMountOption, _aws_cdk_aws_batch_alpha_IManagedComputeEnvironment, _aws_cdk_aws_batch_alpha_ManagedComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_IManagedEc2EcsComputeEnvironment, _aws_cdk_aws_batch_alpha_EcsMachineImage, _aws_cdk_aws_batch_alpha_EksMachineImage, _aws_cdk_aws_batch_alpha_EcsMachineImageType, _aws_cdk_aws_batch_alpha_EksMachineImageType, _aws_cdk_aws_batch_alpha_AllocationStrategy, _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironment, _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironment, _aws_cdk_aws_batch_alpha_IFargateComputeEnvironment, _aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_FargateComputeEnvironment, _aws_cdk_aws_batch_alpha_MultiNodeContainer, _aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps, _aws_cdk_aws_batch_alpha_MultiNodeJobDefinition, _aws_cdk_aws_batch_alpha_ISchedulingPolicy, _aws_cdk_aws_batch_alpha_Share, _aws_cdk_aws_batch_alpha_IFairshareSchedulingPolicy, _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps, _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicy, _aws_cdk_aws_batch_alpha_IUnmanagedComputeEnvironment, _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironment }; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts new file mode 100644 index 0000000000000..61426345d5a13 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts @@ -0,0 +1,87 @@ +import * as iam from 'aws-cdk-lib/aws-iam'; +import { IResource, Resource } from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +/** + * Represents a ComputeEnvironment + */ +export interface IComputeEnvironment extends IResource { + /** + * The name of the ComputeEnvironment + * + * @attribute + */ + readonly computeEnvironmentName: string; + /** + * The ARN of this compute environment. + * + * @attribute + */ + readonly computeEnvironmentArn: string; + /** + * The role Batch uses to perform actions on your behalf + * in your account, such as provision instances to run your jobs + * + * @default - a serviceRole will be created for managed CEs, none for unmanaged CEs + */ + readonly serviceRole?: iam.IRole; + /** + * Whether or not this ComputeEnvironment can accept jobs from a Queue. + * Enabled ComputeEnvironments can accept jobs from a Queue and + * can scale instances up or down. + * Disabled ComputeEnvironments cannot accept jobs from a Queue or + * scale instances up or down. + * + * If you change a ComputeEnvironment from enabled to disabled while it is executing jobs, + * Jobs in the `STARTED` or `RUNNING` states will not + * be interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`. + * + * To ensure you aren't billed for unused capacity, set `minvCpus` to `0`. + */ + readonly enabled: boolean; +} +/** + * Props common to all ComputeEnvironments + */ +export interface ComputeEnvironmentProps { + /** + * The name of the ComputeEnvironment + * + * @default - generated by CloudFormation + */ + readonly computeEnvironmentName?: string; + /** + * The role Batch uses to perform actions on your behalf + * in your account, such as provision instances to run your jobs + * + * @default - a serviceRole will be created for managed CEs, none for unmanaged CEs + */ + readonly serviceRole?: iam.IRole; + /** + * Whether or not this ComputeEnvironment can accept jobs from a Queue. + * Enabled ComputeEnvironments can accept jobs from a Queue and + * can scale instances up or down. + * Disabled ComputeEnvironments cannot accept jobs from a Queue or + * scale instances up or down. + * + * If you change a ComputeEnvironment from enabled to disabled while it is executing jobs, + * Jobs in the `STARTED` or `RUNNING` states will not + * be interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`. + * + * To ensure you aren't billed for unused capacity, set `minvCpus` to `0`. + * + * @default true + */ + readonly enabled?: boolean; +} +/** + * Abstract base class for ComputeEnvironments + * + * @internal + */ +export declare abstract class ComputeEnvironmentBase extends Resource implements IComputeEnvironment { + abstract readonly computeEnvironmentName: string; + readonly serviceRole?: iam.IRole | undefined; + readonly enabled: boolean; + abstract readonly computeEnvironmentArn: string; + constructor(scope: Construct, id: string, props?: ComputeEnvironmentProps); +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js new file mode 100644 index 0000000000000..4af677e1944ac --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js @@ -0,0 +1,20 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.ComputeEnvironmentBase = void 0; +const core_1 = require("aws-cdk-lib/core"); +/** + * Abstract base class for ComputeEnvironments + * + * @internal + */ +class ComputeEnvironmentBase extends core_1.Resource { + constructor(scope, id, props) { + super(scope, id, { + physicalName: props?.computeEnvironmentName, + }); + this.serviceRole = props?.serviceRole; + this.enabled = props?.enabled ?? true; + } +} +exports.ComputeEnvironmentBase = ComputeEnvironmentBase; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcHV0ZS1lbnZpcm9ubWVudC1iYXNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiY29tcHV0ZS1lbnZpcm9ubWVudC1iYXNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUNBLDJDQUF1RDtBQWtGdkQ7Ozs7R0FJRztBQUNILE1BQXNCLHNCQUF1QixTQUFRLGVBQVE7SUFNM0QsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxLQUErQjtRQUN2RSxLQUFLLENBQUMsS0FBSyxFQUFFLEVBQUUsRUFBR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udmlyb25tZW50QXJuOiBzdHJpbmc7XG5cbiAgY29uc3RydWN0b3Ioc2NvcGU6IENvbnN0cnVjdCwgaWQ6IHN0cmluZywgcHJvcHM/OiBDb21wdXRlRW52aXJvbm1lbnRQcm9wcykge1xuICAgIHN1cGVyKHNjb3BlLCBpZCwge1xuICAgICAgcGh5c2ljYWxOYW1lOiBwcm9wcz8uY29tcHV0ZUVudmlyb25tZW50TmFtZSxcbiAgICB9KTtcblxuICAgIHRoaXMuc2VydmljZVJvbGUgPSBwcm9wcz8uc2VydmljZVJvbGU7XG4gICAgdGhpcy5lbmFibGVkID0gcHJvcHM/LmVuYWJsZWQgPz8gdHJ1ZTtcbiAgfVxufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts new file mode 100644 index 0000000000000..4d545c302aeec --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts @@ -0,0 +1,726 @@ +import * as ecs from 'aws-cdk-lib/aws-ecs'; +import { IFileSystem } from 'aws-cdk-lib/aws-efs'; +import * as iam from 'aws-cdk-lib/aws-iam'; +import * as ssm from 'aws-cdk-lib/aws-ssm'; +import * as secretsmanager from 'aws-cdk-lib/aws-secretsmanager'; +import { Size } from 'aws-cdk-lib/core'; +import { Construct, IConstruct } from 'constructs'; +import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; +import { LinuxParameters } from './linux-parameters'; +/** + * Specify the secret's version id or version stage + */ +export interface SecretVersionInfo { + /** + * version id of the secret + * + * @default - use default version id + */ + readonly versionId?: string; + /** + * version stage of the secret + * + * @default - use default version stage + */ + readonly versionStage?: string; +} +/** + * A secret environment variable. + */ +export declare abstract class Secret { + /** + * Creates an environment variable value from a parameter stored in AWS + * Systems Manager Parameter Store. + */ + static fromSsmParameter(parameter: ssm.IParameter): Secret; + /** + * Creates a environment variable value from a secret stored in AWS Secrets + * Manager. + * + * @param secret the secret stored in AWS Secrets Manager + * @param field the name of the field with the value that you want to set as + * the environment variable value. Only values in JSON format are supported. + * If you do not specify a JSON field, then the full content of the secret is + * used. + */ + static fromSecretsManager(secret: secretsmanager.ISecret, field?: string): Secret; + /** + * Creates a environment variable value from a secret stored in AWS Secrets + * Manager. + * + * @param secret the secret stored in AWS Secrets Manager + * @param versionInfo the version information to reference the secret + * @param field the name of the field with the value that you want to set as + * the environment variable value. Only values in JSON format are supported. + * If you do not specify a JSON field, then the full content of the secret is + * used. + */ + static fromSecretsManagerVersion(secret: secretsmanager.ISecret, versionInfo: SecretVersionInfo, field?: string): Secret; + /** + * The ARN of the secret + */ + abstract readonly arn: string; + /** + * Whether this secret uses a specific JSON field + */ + abstract readonly hasField?: boolean; + /** + * Grants reading the secret to a principal + */ + abstract grantRead(grantee: iam.IGrantable): iam.Grant; +} +/** + * Options to configure an EcsVolume + */ +export interface EcsVolumeOptions { + /** + * the name of this volume + */ + readonly name: string; + /** + * the path on the container where this volume is mounted + */ + readonly containerPath: string; + /** + * if set, the container will have readonly access to the volume + * + * @default false + */ + readonly readonly?: boolean; +} +/** + * Represents a Volume that can be mounted to a container that uses ECS + */ +export declare abstract class EcsVolume { + /** + * Creates a Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html + */ + static efs(options: EfsVolumeOptions): EfsVolume; + /** + * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. + * If the `hostPath` is not specified, Docker will choose the host path. In this case, + * the data may not persist after the containers that use it stop running. + */ + static host(options: HostVolumeOptions): HostVolume; + /** + * The name of this volume + */ + readonly name: string; + /** + * The path on the container that this volume will be mounted to + */ + readonly containerPath: string; + /** + * Whether or not the container has readonly access to this volume + * + * @default false + */ + readonly readonly?: boolean; + constructor(options: EcsVolumeOptions); +} +/** + * Options for configuring an EfsVolume + */ +export interface EfsVolumeOptions extends EcsVolumeOptions { + /** + * The EFS File System that supports this volume + */ + readonly fileSystem: IFileSystem; + /** + * The directory within the Amazon EFS file system to mount as the root directory inside the host. + * If this parameter is omitted, the root of the Amazon EFS volume is used instead. + * Specifying `/` has the same effect as omitting this parameter. + * The maximum length is 4,096 characters. + * + * @default - root of the EFS File System + */ + readonly rootDirectory?: string; + /** + * Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server + * + * @see https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html + * + * @default false + */ + readonly enableTransitEncryption?: boolean; + /** + * The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server. + * The value must be between 0 and 65,535. + * + * @see https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html + * + * @default - chosen by the EFS Mount Helper + */ + readonly transitEncryptionPort?: number; + /** + * The Amazon EFS access point ID to use. + * If an access point is specified, `rootDirectory` must either be omitted or set to `/` + * which enforces the path set on the EFS access point. + * If an access point is used, `enableTransitEncryption` must be `true`. + * + * @see https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html + * + * @default - no accessPointId + */ + readonly accessPointId?: string; + /** + * Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system. + * If specified, `enableTransitEncryption` must be `true`. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints + * + * @default false + */ + readonly useJobRole?: boolean; +} +/** + * A Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed + */ +export declare class EfsVolume extends EcsVolume { + /** + * Returns true if x is an EfsVolume, false otherwise + */ + static isEfsVolume(x: any): x is EfsVolume; + /** + * The EFS File System that supports this volume + */ + readonly fileSystem: IFileSystem; + /** + * The directory within the Amazon EFS file system to mount as the root directory inside the host. + * If this parameter is omitted, the root of the Amazon EFS volume is used instead. + * Specifying `/` has the same effect as omitting this parameter. + * The maximum length is 4,096 characters. + * + * @default - root of the EFS File System + */ + readonly rootDirectory?: string; + /** + * Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server + * + * @see https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html + * + * @default false + */ + readonly enableTransitEncryption?: boolean; + /** + * The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server. + * The value must be between 0 and 65,535. + * + * @see https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html + * + * @default - chosen by the EFS Mount Helper + */ + readonly transitEncryptionPort?: number; + /** + * The Amazon EFS access point ID to use. + * If an access point is specified, `rootDirectory` must either be omitted or set to `/` + * which enforces the path set on the EFS access point. + * If an access point is used, `enableTransitEncryption` must be `true`. + * + * @see https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html + * + * @default - no accessPointId + */ + readonly accessPointId?: string; + /** + * Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system. + * If specified, `enableTransitEncryption` must be `true`. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints + * + * @default false + */ + readonly useJobRole?: boolean; + constructor(options: EfsVolumeOptions); +} +/** + * Options for configuring an ECS HostVolume + */ +export interface HostVolumeOptions extends EcsVolumeOptions { + /** + * The path on the host machine this container will have access to + * + * @default - Docker will choose the host path. + * The data may not persist after the containers that use it stop running. + */ + readonly hostPath?: string; +} +/** + * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. + * If the `hostPath` is not specified, Docker will choose the host path. In this case, + * the data may not persist after the containers that use it stop running. + */ +export declare class HostVolume extends EcsVolume { + /** + * returns `true` if `x` is a `HostVolume`, `false` otherwise + */ + static isHostVolume(x: any): x is HostVolume; + /** + * The path on the host machine this container will have access to + */ + readonly hostPath?: string; + constructor(options: HostVolumeOptions); +} +/** + * A container that can be run with ECS orchestration + */ +export interface IEcsContainerDefinition extends IConstruct { + /** + * The image that this container will run + */ + readonly image: ecs.ContainerImage; + /** + * The number of vCPUs reserved for the container. + * Each vCPU is equivalent to 1,024 CPU shares. + * For containers running on EC2 resources, you must specify at least one vCPU. + */ + readonly cpu: number; + /** + * The memory hard limit present to the container. + * If your container attempts to exceed the memory specified, the container is terminated. + * You must specify at least 4 MiB of memory for a job. + */ + readonly memory: Size; + /** + * The command that's passed to the container + * + * @see https://docs.docker.com/engine/reference/builder/#cmd + */ + readonly command?: string[]; + /** + * The environment variables to pass to a container. + * Cannot start with `AWS_BATCH`. + * We don't recommend using plaintext environment variables for sensitive information, such as credential data. + * + * @default - no environment variables + */ + readonly environment?: { + [key: string]: string; + }; + /** + * The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html + */ + readonly executionRole: iam.IRole; + /** + * The role that the container can assume. + * + * @default - no jobRole + * + * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html + */ + readonly jobRole?: iam.IRole; + /** + * Linux-specific modifications that are applied to the container, such as details for device mappings. + * + * @default none + */ + readonly linuxParameters?: LinuxParameters; + /** + * The configuration of the log driver + */ + readonly logDriverConfig?: ecs.LogDriverConfig; + /** + * Gives the container readonly access to its root filesystem. + * + * @default false + */ + readonly readonlyRootFilesystem?: boolean; + /** + * A map from environment variable names to the secrets for the container. Allows your job definitions + * to reference the secret by the environment variable name defined in this property. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html + * + * @default - no secrets + */ + readonly secrets?: { + [envVarName: string]: Secret; + }; + /** + * The user name to use inside the container + * + * @default - no user + */ + readonly user?: string; + /** + * The volumes to mount to this container. Automatically added to the job definition. + * + * @default - no volumes + */ + readonly volumes: EcsVolume[]; + /** + * Renders this container to CloudFormation + * + * @internal + */ + _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; + /** + * Add a Volume to this container + */ + addVolume(volume: EcsVolume): void; +} +/** + * Props to configure an EcsContainerDefinition + */ +export interface EcsContainerDefinitionProps { + /** + * The image that this container will run + */ + readonly image: ecs.ContainerImage; + /** + * The number of vCPUs reserved for the container. + * Each vCPU is equivalent to 1,024 CPU shares. + * For containers running on EC2 resources, you must specify at least one vCPU. + */ + readonly cpu: number; + /** + * The memory hard limit present to the container. + * If your container attempts to exceed the memory specified, the container is terminated. + * You must specify at least 4 MiB of memory for a job. + */ + readonly memory: Size; + /** + * The command that's passed to the container + * + * @see https://docs.docker.com/engine/reference/builder/#cmd + * + * @default - no command + */ + readonly command?: string[]; + /** + * The environment variables to pass to a container. + * Cannot start with `AWS_BATCH`. + * We don't recommend using plaintext environment variables for sensitive information, such as credential data. + * + * @default - no environment variables + */ + readonly environment?: { + [key: string]: string; + }; + /** + * The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html + * + * @default - a Role will be created + */ + readonly executionRole?: iam.IRole; + /** + * The role that the container can assume. + * + * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html + * + * @default - no job role + */ + readonly jobRole?: iam.IRole; + /** + * Linux-specific modifications that are applied to the container, such as details for device mappings. + * + * @default none + */ + readonly linuxParameters?: LinuxParameters; + /** + * The loging configuration for this Job + * + * @default - the log configuration of the Docker daemon + */ + readonly logging?: ecs.LogDriver; + /** + * Gives the container readonly access to its root filesystem. + * + * @default false + */ + readonly readonlyRootFilesystem?: boolean; + /** + * A map from environment variable names to the secrets for the container. Allows your job definitions + * to reference the secret by the environment variable name defined in this property. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html + * + * @default - no secrets + */ + readonly secrets?: { + [envVarName: string]: Secret; + }; + /** + * The user name to use inside the container + * + * @default - no user + */ + readonly user?: string; + /** + * The volumes to mount to this container. Automatically added to the job definition. + * + * @default - no volumes + */ + readonly volumes?: EcsVolume[]; +} +/** + * Abstract base class for ECS Containers + */ +declare abstract class EcsContainerDefinitionBase extends Construct implements IEcsContainerDefinition { + readonly image: ecs.ContainerImage; + readonly cpu: number; + readonly memory: Size; + readonly command?: string[]; + readonly environment?: { + [key: string]: string; + }; + readonly executionRole: iam.IRole; + readonly jobRole?: iam.IRole; + readonly linuxParameters?: LinuxParameters; + readonly logDriverConfig?: ecs.LogDriverConfig; + readonly readonlyRootFilesystem?: boolean; + readonly secrets?: { + [envVarName: string]: Secret; + }; + readonly user?: string; + readonly volumes: EcsVolume[]; + private readonly imageConfig; + constructor(scope: Construct, id: string, props: EcsContainerDefinitionProps); + /** + * @internal + */ + _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; + addVolume(volume: EcsVolume): void; + /** + * @internal + */ + protected _renderResourceRequirements(): { + type: string; + value: string; + }[]; +} +/** + * Sets limits for a resource with `ulimit` on linux systems. + * Used by the Docker daemon. + */ +export interface Ulimit { + /** + * The hard limit for this resource. The container will + * be terminated if it exceeds this limit. + */ + readonly hardLimit: number; + /** + * The resource to limit + */ + readonly name: UlimitName; + /** + * The reservation for this resource. The container will + * not be terminated if it exceeds this limit. + */ + readonly softLimit: number; +} +/** + * The resources to be limited + */ +export declare enum UlimitName { + /** + * max core dump file size + */ + CORE = "core", + /** + * max cpu time (seconds) for a process + */ + CPU = "cpu", + /** + * max data segment size + */ + DATA = "data", + /** + * max file size + */ + FSIZE = "fsize", + /** + * max number of file locks + */ + LOCKS = "locks", + /** + * max locked memory + */ + MEMLOCK = "memlock", + /** + * max POSIX message queue size + */ + MSGQUEUE = "msgqueue", + /** + * max nice value for any process this user is running + */ + NICE = "nice", + /** + * maximum number of open file descriptors + */ + NOFILE = "nofile", + /** + * maximum number of processes + */ + NPROC = "nproc", + /** + * size of the process' resident set (in pages) + */ + RSS = "rss", + /** + * max realtime priority + */ + RTPRIO = "rtprio", + /** + * timeout for realtime tasks + */ + RTTIME = "rttime", + /** + * max number of pending signals + */ + SIGPENDING = "sigpending", + /** + * max stack size (in bytes) + */ + STACK = "stack" +} +/** + * A container orchestrated by ECS that uses EC2 resources + */ +export interface IEcsEc2ContainerDefinition extends IEcsContainerDefinition { + /** + * When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user). + * + * @default false + */ + readonly privileged?: boolean; + /** + * Limits to set for the user this docker container will run as + */ + readonly ulimits: Ulimit[]; + /** + * The number of physical GPUs to reserve for the container. + * Make sure that the number of GPUs reserved for all containers in a job doesn't exceed + * the number of available GPUs on the compute resource that the job is launched on. + * + * @default - no gpus + */ + readonly gpu?: number; + /** + * Add a ulimit to this container + */ + addUlimit(ulimit: Ulimit): void; +} +/** + * Props to configure an EcsEc2ContainerDefinition + */ +export interface EcsEc2ContainerDefinitionProps extends EcsContainerDefinitionProps { + /** + * When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user). + * + * @default false + */ + readonly privileged?: boolean; + /** + * Limits to set for the user this docker container will run as + * + * @default - no ulimits + */ + readonly ulimits?: Ulimit[]; + /** + * The number of physical GPUs to reserve for the container. + * Make sure that the number of GPUs reserved for all containers in a job doesn't exceed + * the number of available GPUs on the compute resource that the job is launched on. + * + * @default - no gpus + */ + readonly gpu?: number; +} +/** + * A container orchestrated by ECS that uses EC2 resources + */ +export declare class EcsEc2ContainerDefinition extends EcsContainerDefinitionBase implements IEcsEc2ContainerDefinition { + readonly privileged?: boolean; + readonly ulimits: Ulimit[]; + readonly gpu?: number; + constructor(scope: Construct, id: string, props: EcsEc2ContainerDefinitionProps); + /** + * @internal + */ + _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; + /** + * Add a ulimit to this container + */ + addUlimit(ulimit: Ulimit): void; + /** + * @internal + */ + protected _renderResourceRequirements(): { + type: string; + value: string; + }[]; +} +/** + * A container orchestrated by ECS that uses Fargate resources and is orchestrated by ECS + */ +export interface IEcsFargateContainerDefinition extends IEcsContainerDefinition { + /** + * Indicates whether the job has a public IP address. + * For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet + * (for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet. + * + * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html + * + * @default false + */ + readonly assignPublicIp?: boolean; + /** + * Which version of Fargate to use when running this container + * + * @default LATEST + */ + readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; + /** + * The size for ephemeral storage. + * + * @default - 20 GiB + */ + readonly ephemeralStorageSize?: Size; +} +/** + * Props to configure an EcsFargateContainerDefinition + */ +export interface EcsFargateContainerDefinitionProps extends EcsContainerDefinitionProps { + /** + * Indicates whether the job has a public IP address. + * For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet + * (for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet. + * + * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html + * + * @default false + */ + readonly assignPublicIp?: boolean; + /** + * Which version of Fargate to use when running this container + * + * @default LATEST + */ + readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; + /** + * The size for ephemeral storage. + * + * @default - 20 GiB + */ + readonly ephemeralStorageSize?: Size; +} +/** + * A container orchestrated by ECS that uses Fargate resources + */ +export declare class EcsFargateContainerDefinition extends EcsContainerDefinitionBase implements IEcsFargateContainerDefinition { + readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; + readonly assignPublicIp?: boolean; + readonly ephemeralStorageSize?: Size; + constructor(scope: Construct, id: string, props: EcsFargateContainerDefinitionProps); + /** + * @internal + */ + _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; +} +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js new file mode 100644 index 0000000000000..1153535f13eac --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js @@ -0,0 +1,531 @@ +"use strict"; +var _a, _b, _c, _d, _e, _f; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.EcsFargateContainerDefinition = exports.EcsEc2ContainerDefinition = exports.UlimitName = exports.HostVolume = exports.EfsVolume = exports.EcsVolume = exports.Secret = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const iam = require("aws-cdk-lib/aws-iam"); +const core_1 = require("aws-cdk-lib/core"); +const constructs_1 = require("constructs"); +const aws_logs_1 = require("aws-cdk-lib/aws-logs"); +const EFS_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/container-definition.EfsVolume'); +const HOST_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/container-definition.HostVolume'); +/** + * A secret environment variable. + */ +class Secret { + /** + * Creates an environment variable value from a parameter stored in AWS + * Systems Manager Parameter Store. + */ + static fromSsmParameter(parameter) { + return { + arn: parameter.parameterArn, + grantRead: grantee => parameter.grantRead(grantee), + }; + } + /** + * Creates a environment variable value from a secret stored in AWS Secrets + * Manager. + * + * @param secret the secret stored in AWS Secrets Manager + * @param field the name of the field with the value that you want to set as + * the environment variable value. Only values in JSON format are supported. + * If you do not specify a JSON field, then the full content of the secret is + * used. + */ + static fromSecretsManager(secret, field) { + return { + arn: field ? `${secret.secretArn}:${field}::` : secret.secretArn, + hasField: !!field, + grantRead: grantee => secret.grantRead(grantee), + }; + } + /** + * Creates a environment variable value from a secret stored in AWS Secrets + * Manager. + * + * @param secret the secret stored in AWS Secrets Manager + * @param versionInfo the version information to reference the secret + * @param field the name of the field with the value that you want to set as + * the environment variable value. Only values in JSON format are supported. + * If you do not specify a JSON field, then the full content of the secret is + * used. + */ + static fromSecretsManagerVersion(secret, versionInfo, field) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretVersionInfo(versionInfo); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.fromSecretsManagerVersion); + } + throw error; + } + return { + arn: `${secret.secretArn}:${field ?? ''}:${versionInfo.versionStage ?? ''}:${versionInfo.versionId ?? ''}`, + hasField: !!field, + grantRead: grantee => secret.grantRead(grantee), + }; + } +} +exports.Secret = Secret; +_a = JSII_RTTI_SYMBOL_1; +Secret[_a] = { fqn: "@aws-cdk/aws-batch-alpha.Secret", version: "0.0.0" }; +/** + * Represents a Volume that can be mounted to a container that uses ECS + */ +class EcsVolume { + /** + * Creates a Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html + */ + static efs(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EfsVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.efs); + } + throw error; + } + return new EfsVolume(options); + } + /** + * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. + * If the `hostPath` is not specified, Docker will choose the host path. In this case, + * the data may not persist after the containers that use it stop running. + */ + static host(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.host); + } + throw error; + } + return new HostVolume(options); + } + constructor(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EcsVolume); + } + throw error; + } + this.name = options.name; + this.containerPath = options.containerPath; + this.readonly = options.readonly; + } +} +exports.EcsVolume = EcsVolume; +_b = JSII_RTTI_SYMBOL_1; +EcsVolume[_b] = { fqn: "@aws-cdk/aws-batch-alpha.EcsVolume", version: "0.0.0" }; +/** + * A Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed + */ +class EfsVolume extends EcsVolume { + /** + * Returns true if x is an EfsVolume, false otherwise + */ + static isEfsVolume(x) { + return x !== null && typeof (x) === 'object' && EFS_VOLUME_SYMBOL in x; + } + constructor(options) { + super(options); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EfsVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EfsVolume); + } + throw error; + } + this.fileSystem = options.fileSystem; + this.rootDirectory = options.rootDirectory; + this.enableTransitEncryption = options.enableTransitEncryption; + this.transitEncryptionPort = options.transitEncryptionPort; + this.accessPointId = options.accessPointId; + this.useJobRole = options.useJobRole; + } +} +exports.EfsVolume = EfsVolume; +_c = JSII_RTTI_SYMBOL_1; +EfsVolume[_c] = { fqn: "@aws-cdk/aws-batch-alpha.EfsVolume", version: "0.0.0" }; +Object.defineProperty(EfsVolume.prototype, EFS_VOLUME_SYMBOL, { + value: true, + enumerable: false, + writable: false, +}); +/** + * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. + * If the `hostPath` is not specified, Docker will choose the host path. In this case, + * the data may not persist after the containers that use it stop running. + */ +class HostVolume extends EcsVolume { + /** + * returns `true` if `x` is a `HostVolume`, `false` otherwise + */ + static isHostVolume(x) { + return x !== null && typeof (x) === 'object' && HOST_VOLUME_SYMBOL in x; + } + constructor(options) { + super(options); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, HostVolume); + } + throw error; + } + this.hostPath = options.hostPath; + } +} +exports.HostVolume = HostVolume; +_d = JSII_RTTI_SYMBOL_1; +HostVolume[_d] = { fqn: "@aws-cdk/aws-batch-alpha.HostVolume", version: "0.0.0" }; +Object.defineProperty(HostVolume.prototype, HOST_VOLUME_SYMBOL, { + value: true, + enumerable: false, + writable: false, +}); +/** + * Abstract base class for ECS Containers + */ +class EcsContainerDefinitionBase extends constructs_1.Construct { + constructor(scope, id, props) { + super(scope, id); + this.image = props.image; + this.cpu = props.cpu; + this.command = props.command; + this.environment = props.environment; + this.executionRole = props.executionRole ?? createExecutionRole(this, 'ExecutionRole', props.logging ? true : false); + this.jobRole = props.jobRole; + this.linuxParameters = props.linuxParameters; + this.memory = props.memory; + if (props.logging) { + this.logDriverConfig = props.logging.bind(this, { + ...this, + // TS! + taskDefinition: { + obtainExecutionRole: () => this.executionRole, + }, + }); + } + this.readonlyRootFilesystem = props.readonlyRootFilesystem ?? false; + this.secrets = props.secrets; + this.user = props.user; + this.volumes = props.volumes ?? []; + this.imageConfig = props.image.bind(this, { + ...this, + taskDefinition: { + obtainExecutionRole: () => this.executionRole, + }, + }); + } + /** + * @internal + */ + _renderContainerDefinition() { + return { + image: this.imageConfig.imageName, + command: this.command, + environment: Object.keys(this.environment ?? {}).map((envKey) => ({ + name: envKey, + value: (this.environment ?? {})[envKey], + })), + jobRoleArn: this.jobRole?.roleArn, + executionRoleArn: this.executionRole?.roleArn, + linuxParameters: this.linuxParameters && this.linuxParameters.renderLinuxParameters(), + logConfiguration: this.logDriverConfig, + readonlyRootFilesystem: this.readonlyRootFilesystem, + resourceRequirements: this._renderResourceRequirements(), + secrets: this.secrets ? Object.entries(this.secrets).map(([name, secret]) => { + secret.grantRead(this.executionRole); + return { + name, + valueFrom: secret.arn, + }; + }) : undefined, + mountPoints: core_1.Lazy.any({ + produce: () => { + if (this.volumes.length === 0) { + return undefined; + } + return this.volumes.map((volume) => { + return { + containerPath: volume.containerPath, + readOnly: volume.readonly, + sourceVolume: volume.name, + }; + }); + }, + }), + volumes: core_1.Lazy.any({ + produce: () => { + if (this.volumes.length === 0) { + return undefined; + } + return this.volumes.map((volume) => { + if (EfsVolume.isEfsVolume(volume)) { + return { + name: volume.name, + efsVolumeConfiguration: { + fileSystemId: volume.fileSystem.fileSystemId, + rootDirectory: volume.rootDirectory, + transitEncryption: volume.enableTransitEncryption ? 'ENABLED' : (volume.enableTransitEncryption === false ? 'DISABLED' : undefined), + transitEncryptionPort: volume.transitEncryptionPort, + authorizationConfig: volume.accessPointId || volume.useJobRole ? { + accessPointId: volume.accessPointId, + iam: volume.useJobRole ? 'ENABLED' : (volume.useJobRole === false ? 'DISABLED' : undefined), + } : undefined, + }, + }; + } + else if (HostVolume.isHostVolume(volume)) { + return { + name: volume.name, + host: { + sourcePath: volume.hostPath, + }, + }; + } + throw new Error('unsupported Volume encountered'); + }); + }, + }), + user: this.user, + }; + } + addVolume(volume) { + this.volumes.push(volume); + } + /** + * @internal + */ + _renderResourceRequirements() { + const resourceRequirements = []; + resourceRequirements.push({ + type: 'MEMORY', + value: this.memory.toMebibytes().toString(), + }); + resourceRequirements.push({ + type: 'VCPU', + value: this.cpu.toString(), + }); + return resourceRequirements; + } +} +/** + * The resources to be limited + */ +var UlimitName; +(function (UlimitName) { + /** + * max core dump file size + */ + UlimitName["CORE"] = "core"; + /** + * max cpu time (seconds) for a process + */ + UlimitName["CPU"] = "cpu"; + /** + * max data segment size + */ + UlimitName["DATA"] = "data"; + /** + * max file size + */ + UlimitName["FSIZE"] = "fsize"; + /** + * max number of file locks + */ + UlimitName["LOCKS"] = "locks"; + /** + * max locked memory + */ + UlimitName["MEMLOCK"] = "memlock"; + /** + * max POSIX message queue size + */ + UlimitName["MSGQUEUE"] = "msgqueue"; + /** + * max nice value for any process this user is running + */ + UlimitName["NICE"] = "nice"; + /** + * maximum number of open file descriptors + */ + UlimitName["NOFILE"] = "nofile"; + /** + * maximum number of processes + */ + UlimitName["NPROC"] = "nproc"; + /** + * size of the process' resident set (in pages) + */ + UlimitName["RSS"] = "rss"; + /** + * max realtime priority + */ + UlimitName["RTPRIO"] = "rtprio"; + /** + * timeout for realtime tasks + */ + UlimitName["RTTIME"] = "rttime"; + /** + * max number of pending signals + */ + UlimitName["SIGPENDING"] = "sigpending"; + /** + * max stack size (in bytes) + */ + UlimitName["STACK"] = "stack"; +})(UlimitName || (exports.UlimitName = UlimitName = {})); +/** + * A container orchestrated by ECS that uses EC2 resources + */ +class EcsEc2ContainerDefinition extends EcsContainerDefinitionBase { + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EcsEc2ContainerDefinition); + } + throw error; + } + this.privileged = props.privileged; + this.ulimits = props.ulimits ?? []; + this.gpu = props.gpu; + } + /** + * @internal + */ + _renderContainerDefinition() { + return { + ...super._renderContainerDefinition(), + ulimits: core_1.Lazy.any({ + produce: () => { + if (this.ulimits.length === 0) { + return undefined; + } + return this.ulimits.map((ulimit) => ({ + hardLimit: ulimit.hardLimit, + name: ulimit.name, + softLimit: ulimit.softLimit, + })); + }, + }), + privileged: this.privileged, + resourceRequirements: this._renderResourceRequirements(), + }; + } + ; + /** + * Add a ulimit to this container + */ + addUlimit(ulimit) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Ulimit(ulimit); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addUlimit); + } + throw error; + } + this.ulimits.push(ulimit); + } + /** + * @internal + */ + _renderResourceRequirements() { + const resourceRequirements = super._renderResourceRequirements(); + if (this.gpu) { + resourceRequirements.push({ + type: 'GPU', + value: this.gpu.toString(), + }); + } + return resourceRequirements; + } +} +exports.EcsEc2ContainerDefinition = EcsEc2ContainerDefinition; +_e = JSII_RTTI_SYMBOL_1; +EcsEc2ContainerDefinition[_e] = { fqn: "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition", version: "0.0.0" }; +/** + * A container orchestrated by ECS that uses Fargate resources + */ +class EcsFargateContainerDefinition extends EcsContainerDefinitionBase { + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EcsFargateContainerDefinition); + } + throw error; + } + this.assignPublicIp = props.assignPublicIp; + this.fargatePlatformVersion = props.fargatePlatformVersion; + this.ephemeralStorageSize = props.ephemeralStorageSize; + // validates ephemeralStorageSize is within limits + if (props.ephemeralStorageSize) { + if (props.ephemeralStorageSize.toGibibytes() > 200) { + throw new Error(`ECS Fargate container '${id}' specifies 'ephemeralStorageSize' at ${props.ephemeralStorageSize.toGibibytes()} > 200 GB`); + } + else if (props.ephemeralStorageSize.toGibibytes() < 21) { + throw new Error(`ECS Fargate container '${id}' specifies 'ephemeralStorageSize' at ${props.ephemeralStorageSize.toGibibytes()} < 21 GB`); + } + } + } + /** + * @internal + */ + _renderContainerDefinition() { + return { + ...super._renderContainerDefinition(), + ephemeralStorage: this.ephemeralStorageSize ? { + sizeInGiB: this.ephemeralStorageSize?.toGibibytes(), + } : undefined, + fargatePlatformConfiguration: { + platformVersion: this.fargatePlatformVersion?.toString(), + }, + networkConfiguration: { + assignPublicIp: this.assignPublicIp ? 'ENABLED' : 'DISABLED', + }, + }; + } + ; +} +exports.EcsFargateContainerDefinition = EcsFargateContainerDefinition; +_f = JSII_RTTI_SYMBOL_1; +EcsFargateContainerDefinition[_f] = { fqn: "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition", version: "0.0.0" }; +function createExecutionRole(scope, id, logging) { + const execRole = new iam.Role(scope, id, { + assumedBy: new iam.ServicePrincipal('ecs-tasks.amazonaws.com'), + // needed for cross-account access with TagParameterContainerImage + roleName: core_1.PhysicalName.GENERATE_IF_NEEDED, + }); + if (!logging) { + // all jobs will fail without this if they produce any output at all when no logging is specified + aws_logs_1.LogGroup.fromLogGroupName(scope, 'batchDefaultLogGroup', '/aws/batch/job').grantWrite(execRole); + } + return execRole; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUVBLDJDQUEyQztBQUczQywyQ0FBNEQ7QUFDNUQsMkNBQW1EO0FBR25ELG1EQUFnRDtBQU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c2VjcmV0cyA/IE9iamVjdC5lbnRyaWVzKHRoaXMuc2VjcmV0cykubWFwKChbbmFtZSwgc2VjcmV0XSkgPT4ge1xuICAgICAgICBzZWNyZXQuZ3JhbnRSZWFkKHRoaXMuZXhlY3V0aW9uUm9sZSk7XG5cbiAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICBuYW1lLFxuICAgICAgICAgIHZhbHVlRnJvbTogc2VjcmV0LmFybixcbiAgICAgICAgfTtcbiAgICAgIH0pIDogdW5kZWZpbmVkLFxuICAgICAgbW91bnRQb2ludHM6IExhenkuYW55KHtcbiAgICAgICAgcHJvZHVjZTogKCkgPT4ge1xuICAgICAgICAgIGlmICh0aGlzLnZvbHVtZXMubGVuZ3RoID09PSAwKSB7XG4gICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gdGhpcy52b2x1bWVzLm1hcCgodm9sdW1lKSA9PiB7XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICBjb250YWluZXJQYXRoOiB2b2x1bWUuY29udGFpbmVyUGF0aCxcbiAgICAgICAgICAgICAgcmVhZE9ubHk6IHZvbHVtZS5yZWFkb25seSxcbiAgICAgICAgICAgICAgc291cmNlVm9sdW1lOiB2b2x1bWUubmFtZSxcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgfSk7XG4gICAgICAgIH0sXG4gICAgICB9KSxcbiAgICAgIHZvbHVtZXM6IExhenkuYW55KHtcbiAgICAgICAgcHJvZHVjZTogKCkgPT4ge1xuICAgICAgICAgIGlmICh0aGlzLnZvbHVtZXMubGVuZ3RoID09PSAwKSB7XG4gICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xuICAgICAgICAgIH1cblxuICAgICAgICAgIHJldHVybiB0aGlzLnZvbHVtZXMubWFwKCh2b2x1bWUpID0+IHtcbiAgICAgICAgICAgIGlmIChFZnNWb2x1bWUuaXNFZnNWb2x1bWUodm9sdW1l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dnaW5nKSB7XG4gICAgLy8gYWxsIGpvYnMgd2lsbCBmYWlsIHdpdGhvdXQgdGhpcyBpZiB0aGV5IHByb2R1Y2UgYW55IG91dHB1dCBhdCBhbGwgd2hlbiBubyBsb2dnaW5nIGlzIHNwZWNpZmllZFxuICAgIExvZ0dyb3VwLmZyb21Mb2dHcm91cE5hbWUoc2NvcGUsICdiYXRjaERlZmF1bHRMb2dHcm91cCcsICcvYXdzL2JhdGNoL2pvYicpLmdyYW50V3JpdGUoZXhlY1JvbGUpO1xuICB9XG5cbiAgcmV0dXJuIGV4ZWNSb2xlO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts new file mode 100644 index 0000000000000..f387b11752d75 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts @@ -0,0 +1,67 @@ +import { Construct } from 'constructs'; +import { IEcsContainerDefinition } from './ecs-container-definition'; +import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; +import * as iam from 'aws-cdk-lib/aws-iam'; +import { IJobQueue } from './job-queue'; +/** + * A JobDefinition that uses ECS orchestration + */ +interface IEcsJobDefinition extends IJobDefinition { + /** + * The container that this job will run + */ + readonly container: IEcsContainerDefinition; + /** + * Whether to propogate tags from the JobDefinition + * to the ECS task that Batch spawns + * + * @default false + */ + readonly propagateTags?: boolean; +} +/** + * @internal + */ +export declare enum Compatibility { + EC2 = "EC2", + FARGATE = "FARGATE" +} +/** + * Props for EcsJobDefinition + */ +export interface EcsJobDefinitionProps extends JobDefinitionProps { + /** + * The container that this job will run + */ + readonly container: IEcsContainerDefinition; + /** + * Whether to propogate tags from the JobDefinition + * to the ECS task that Batch spawns + * + * @default false + */ + readonly propagateTags?: boolean; +} +/** + * A JobDefinition that uses ECS orchestration + * + * @resource AWS::Batch::JobDefinition + */ +export declare class EcsJobDefinition extends JobDefinitionBase implements IEcsJobDefinition { + /** + * Import a JobDefinition by its arn. + */ + static fromJobDefinitionArn(scope: Construct, id: string, jobDefinitionArn: string): IJobDefinition; + private static getJobDefinitionName; + readonly container: IEcsContainerDefinition; + readonly propagateTags?: boolean; + readonly jobDefinitionArn: string; + readonly jobDefinitionName: string; + constructor(scope: Construct, id: string, props: EcsJobDefinitionProps); + /** + * Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue` + */ + grantSubmitJob(identity: iam.IGrantable, queue: IJobQueue): void; + private renderPlatformCapabilities; +} +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js new file mode 100644 index 0000000000000..e10f4f02ae1a9 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js @@ -0,0 +1,102 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.EcsJobDefinition = exports.Compatibility = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +const ecs_container_definition_1 = require("./ecs-container-definition"); +const job_definition_base_1 = require("./job-definition-base"); +const iam = require("aws-cdk-lib/aws-iam"); +/** + * @internal + */ +var Compatibility; +(function (Compatibility) { + Compatibility["EC2"] = "EC2"; + Compatibility["FARGATE"] = "FARGATE"; +})(Compatibility || (exports.Compatibility = Compatibility = {})); +/** + * A JobDefinition that uses ECS orchestration + * + * @resource AWS::Batch::JobDefinition + */ +class EcsJobDefinition extends job_definition_base_1.JobDefinitionBase { + /** + * Import a JobDefinition by its arn. + */ + static fromJobDefinitionArn(scope, id, jobDefinitionArn) { + class Import extends job_definition_base_1.JobDefinitionBase { + constructor() { + super(...arguments); + this.jobDefinitionArn = jobDefinitionArn; + this.jobDefinitionName = EcsJobDefinition.getJobDefinitionName(this, jobDefinitionArn); + this.enabled = true; + this.container = {}; + } + } + return new Import(scope, id); + } + static getJobDefinitionName(scope, jobDefinitionArn) { + const resourceName = core_1.Stack.of(scope).splitArn(jobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + return resourceName.split(':')[0]; + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsJobDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EcsJobDefinition); + } + throw error; + } + this.container = props.container; + this.propagateTags = props?.propagateTags; + const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { + ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), + type: 'container', + jobDefinitionName: props.jobDefinitionName, + containerProperties: this.container?._renderContainerDefinition(), + platformCapabilities: this.renderPlatformCapabilities(), + propagateTags: this.propagateTags, + }); + this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { + service: 'batch', + resource: 'job-definition', + resourceName: this.physicalName, + }); + this.jobDefinitionName = EcsJobDefinition.getJobDefinitionName(scope, this.jobDefinitionArn); + } + /** + * Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue` + */ + grantSubmitJob(identity, queue) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_IJobQueue(queue); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.grantSubmitJob); + } + throw error; + } + iam.Grant.addToPrincipal({ + actions: ['batch:SubmitJob'], + grantee: identity, + resourceArns: [this.jobDefinitionArn, queue.jobQueueArn], + }); + } + renderPlatformCapabilities() { + if (this.container instanceof ecs_container_definition_1.EcsEc2ContainerDefinition) { + return [Compatibility.EC2]; + } + return [Compatibility.FARGATE]; + } +} +exports.EcsJobDefinition = EcsJobDefinition; +_a = JSII_RTTI_SYMBOL_1; +EcsJobDefinition[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sm9iKGlkZW50aXR5OiBpYW0uSUdyYW50YWJsZSwgcXVldWU6IElKb2JRdWV1ZSkge1xuICAgIGlhbS5HcmFudC5hZGRUb1ByaW5jaXBhbCh7XG4gICAgICBhY3Rpb25zOiBbJ2JhdGNoOlN1Ym1pdEpvYiddLFxuICAgICAgZ3JhbnRlZTogaWRlbnRpdHksXG4gICAgICByZXNvdXJjZUFybnM6IFt0aGlzLmpvYkRlZmluaXRpb25Bcm4sIHF1ZXVlLmpvYlF1ZXVlQXJuXSxcbiAgICB9KTtcbiAgfVxuXG4gIHByaXZhdGUgcmVuZGVyUGxhdGZvcm1DYXBhYmlsaXRpZXMoKSB7XG4gICAgaWYgKHRoaXMuY29udGFpbmVyIGluc3RhbmNlb2YgRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbikge1xuICAgICAgcmV0dXJuIFtDb21wYXRpYmlsaXR5LkVDMl07XG4gICAgfVxuXG4gICAgcmV0dXJuIFtDb21wYXRpYmlsaXR5LkZBUkdBVEVdO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts new file mode 100644 index 0000000000000..4e12fa25a1851 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts @@ -0,0 +1,728 @@ +import * as ecs from 'aws-cdk-lib/aws-ecs'; +import { Size } from 'aws-cdk-lib/core'; +import { Construct, IConstruct } from 'constructs'; +import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; +/** + * A container that can be run with EKS orchestration on EC2 resources + */ +export interface IEksContainerDefinition extends IConstruct { + /** + * The image that this container will run + */ + readonly image: ecs.ContainerImage; + /** + * An array of arguments to the entrypoint. + * If this isn't specified, the CMD of the container image is used. + * This corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes. + * Environment variable references are expanded using the container's environment. + * If the referenced environment variable doesn't exist, the reference in the command isn't changed. + * For example, if the reference is to "$(NAME1)" and the NAME1 environment variable doesn't exist, + * the command string will remain "$(NAME1)." $$ is replaced with $, and the resulting string isn't expanded. + * or example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists. + * + * @see https://docs.docker.com/engine/reference/builder/#cmd + * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ + */ + readonly args?: string[]; + /** + * The entrypoint for the container. This isn't run within a shell. + * If this isn't specified, the `ENTRYPOINT` of the container image is used. + * Environment variable references are expanded using the container's environment. + * If the referenced environment variable doesn't exist, the reference in the command isn't changed. + * For example, if the reference is to `"$(NAME1)"` and the `NAME1` environment variable doesn't exist, + * the command string will remain `"$(NAME1)."` `$$` is replaced with `$` and the resulting string isn't expanded. + * For example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists. + + * The entrypoint can't be updated. + * + * @see https://docs.docker.com/engine/reference/builder/#entrypoint + * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ + * @see https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint + */ + readonly command?: string[]; + /** + * The environment variables to pass to this container. + * + * *Note*: Environment variables cannot start with "AWS_BATCH". + * This naming convention is reserved for variables that AWS Batch sets. + */ + readonly env?: { + [key: string]: string; + }; + /** + * The image pull policy for this container + * + * @see https://kubernetes.io/docs/concepts/containers/images/#updating-images + * + * @default - `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise + */ + readonly imagePullPolicy?: ImagePullPolicy; + /** + * The name of this container + * + * @default: `'Default'` + */ + readonly name?: string; + /** + * The amount (in MiB) of memory to present to the container. + * If your container attempts to exceed the allocated memory, it will be terminated. + * + * Must be larger that 4 MiB + * + * At least one of `memoryLimit` and `memoryReservation` is required + * + * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible + * for the specific instance type that you are using. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html + * + * @default - No memory limit + */ + readonly memoryLimit?: Size; + /** + * The soft limit (in MiB) of memory to reserve for the container. + * Your container will be given at least this much memory, but may consume more. + * + * Must be larger that 4 MiB + * + * When system memory is under heavy contention, Docker attempts to keep the + * container memory to this soft limit. However, your container can consume more + * memory when it needs to, up to either the hard limit specified with the memory + * parameter (if applicable), or all of the available memory on the container + * instance, whichever comes first. + * + * At least one of `memoryLimit` and `memoryReservation` is required. + * If both are specified, then `memoryLimit` must be equal to `memoryReservation` + * + * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible + * for the specific instance type that you are using. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html + * + * @default - No memory reserved + */ + readonly memoryReservation?: Size; + /** + * The hard limit of CPUs to present to this container. + * Must be an even multiple of 0.25 + * + * If your container attempts to exceed this limit, it will be terminated. + * + * At least one of `cpuReservation` and `cpuLimit` is required. + * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No CPU limit + */ + readonly cpuLimit?: number; + /** + * The soft limit of CPUs to reserve for the container + * Must be an even multiple of 0.25 + * + * The container will given at least this many CPUs, but may consume more. + * + * At least one of `cpuReservation` and `cpuLimit` is required. + * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No CPUs reserved + */ + readonly cpuReservation?: number; + /** + * The hard limit of GPUs to present to this container. + * + * If your container attempts to exceed this limit, it will be terminated. + * + * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No GPU limit + */ + readonly gpuLimit?: number; + /** + * The soft limit of CPUs to reserve for the container + * Must be an even multiple of 0.25 + * + * The container will given at least this many CPUs, but may consume more. + * + * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No GPUs reserved + */ + readonly gpuReservation?: number; + /** + * If specified, gives this container elevated permissions on the host container instance. + * The level of permissions are similar to the root user permissions. + * + * This parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems + * + * @default false + */ + readonly privileged?: boolean; + /** + * If specified, gives this container readonly access to its root file system. + * + * This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems + * + * @default false + */ + readonly readonlyRootFilesystem?: boolean; + /** + * If specified, the container is run as the specified group ID (`gid`). + * If this parameter isn't specified, the default is the group that's specified in the image metadata. + * This parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default none + */ + readonly runAsGroup?: number; + /** + * If specified, the container is run as a user with a `uid` other than 0. Otherwise, no such rule is enforced. + * This parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default - the container is *not* required to run as a non-root user + */ + readonly runAsRoot?: boolean; + /** + * If specified, this container is run as the specified user ID (`uid`). + * This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default - the user that is specified in the image metadata. + */ + readonly runAsUser?: number; + /** + * The Volumes to mount to this container. + * Automatically added to the Pod. + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/ + */ + readonly volumes: EksVolume[]; + /** + * Mount a Volume to this container. Automatically added to the Pod. + */ + addVolume(volume: EksVolume): void; +} +/** + * Determines when the image is pulled from the registry to launch a container + */ +export declare enum ImagePullPolicy { + /** + * Every time the kubelet launches a container, + * the kubelet queries the container image registry to resolve the name to an image digest. + * If the kubelet has a container image with that exact digest cached locally, + * the kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest, + * and uses that image to launch the container. + * + * @see https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier + */ + ALWAYS = "Always", + /** + * The image is pulled only if it is not already present locally + */ + IF_NOT_PRESENT = "IfNotPresent", + /** + * The kubelet does not try fetching the image. + * If the image is somehow already present locally, + * the kubelet attempts to start the container; otherwise, startup fails. + * See pre-pulled images for more details. + * + * @see https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images + */ + NEVER = "Never" +} +/** + * Props to configure an EksContainerDefinition + */ +export interface EksContainerDefinitionProps { + /** + * The image that this container will run + */ + readonly image: ecs.ContainerImage; + /** + * An array of arguments to the entrypoint. + * If this isn't specified, the CMD of the container image is used. + * This corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes. + * Environment variable references are expanded using the container's environment. + * If the referenced environment variable doesn't exist, the reference in the command isn't changed. + * For example, if the reference is to "$(NAME1)" and the NAME1 environment variable doesn't exist, + * the command string will remain "$(NAME1)." $$ is replaced with $, and the resulting string isn't expanded. + * or example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists. + * + * @see https://docs.docker.com/engine/reference/builder/#cmd + * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ + * + * @default - no args + */ + readonly args?: string[]; + /** + * The entrypoint for the container. This isn't run within a shell. + * If this isn't specified, the `ENTRYPOINT` of the container image is used. + * Environment variable references are expanded using the container's environment. + * If the referenced environment variable doesn't exist, the reference in the command isn't changed. + * For example, if the reference is to `"$(NAME1)"` and the `NAME1` environment variable doesn't exist, + * the command string will remain `"$(NAME1)."` `$$` is replaced with `$` and the resulting string isn't expanded. + * For example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists. + + * The entrypoint can't be updated. + * + * @see https://docs.docker.com/engine/reference/builder/#entrypoint + * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ + * @see https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint + * + * @default - no command + */ + readonly command?: string[]; + /** + * The environment variables to pass to this container. + * + * *Note*: Environment variables cannot start with "AWS_BATCH". + * This naming convention is reserved for variables that AWS Batch sets. + * + * @default - no environment variables + */ + readonly env?: { + [key: string]: string; + }; + /** + * The image pull policy for this container + * + * @see https://kubernetes.io/docs/concepts/containers/images/#updating-images + * + * @default - `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise + */ + readonly imagePullPolicy?: ImagePullPolicy; + /** + * The name of this container + * + * @default: `'Default'` + */ + readonly name?: string; + /** + * The amount (in MiB) of memory to present to the container. + * If your container attempts to exceed the allocated memory, it will be terminated. + * + * Must be larger that 4 MiB + * + * At least one of `memoryLimit` and `memoryReservation` is required + * + * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible + * for the specific instance type that you are using. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html + * + * @default - No memory limit + */ + readonly memoryLimit?: Size; + /** + * The soft limit (in MiB) of memory to reserve for the container. + * Your container will be given at least this much memory, but may consume more. + * + * Must be larger that 4 MiB + * + * When system memory is under heavy contention, Docker attempts to keep the + * container memory to this soft limit. However, your container can consume more + * memory when it needs to, up to either the hard limit specified with the memory + * parameter (if applicable), or all of the available memory on the container + * instance, whichever comes first. + * + * At least one of `memoryLimit` and `memoryReservation` is required. + * If both are specified, then `memoryLimit` must be equal to `memoryReservation` + * + * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible + * for the specific instance type that you are using. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html + * + * @default - No memory reserved + */ + readonly memoryReservation?: Size; + /** + * The hard limit of CPUs to present to this container. + * Must be an even multiple of 0.25 + * + * If your container attempts to exceed this limit, it will be terminated. + * + * At least one of `cpuReservation` and `cpuLimit` is required. + * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No CPU limit + */ + readonly cpuLimit?: number; + /** + * The soft limit of CPUs to reserve for the container + * Must be an even multiple of 0.25 + * + * The container will given at least this many CPUs, but may consume more. + * + * At least one of `cpuReservation` and `cpuLimit` is required. + * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No CPUs reserved + */ + readonly cpuReservation?: number; + /** + * The hard limit of GPUs to present to this container. + * + * If your container attempts to exceed this limit, it will be terminated. + * + * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No GPU limit + */ + readonly gpuLimit?: number; + /** + * The soft limit of CPUs to reserve for the container + * Must be an even multiple of 0.25 + * + * The container will given at least this many CPUs, but may consume more. + * + * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. + * + * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ + * + * @default - No GPUs reserved + */ + readonly gpuReservation?: number; + /** + * If specified, gives this container elevated permissions on the host container instance. + * The level of permissions are similar to the root user permissions. + * + * This parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems + * + * @default false + */ + readonly privileged?: boolean; + /** + * If specified, gives this container readonly access to its root file system. + * + * This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems + * + * @default false + */ + readonly readonlyRootFilesystem?: boolean; + /** + * If specified, the container is run as the specified group ID (`gid`). + * If this parameter isn't specified, the default is the group that's specified in the image metadata. + * This parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default none + */ + readonly runAsGroup?: number; + /** + * If specified, the container is run as a user with a `uid` other than 0. Otherwise, no such rule is enforced. + * This parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default - the container is *not* required to run as a non-root user + */ + readonly runAsRoot?: boolean; + /** + * If specified, this container is run as the specified user ID (`uid`). + * This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. + * + * *Note*: this is only compatible with Kubernetes < v1.25 + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups + * + * @default - the user that is specified in the image metadata. + */ + readonly runAsUser?: number; + /** + * The Volumes to mount to this container. + * Automatically added to the Pod. + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/ + * + * @default - no volumes + */ + readonly volumes?: EksVolume[]; +} +/** + * A container that can be run with EKS orchestration on EC2 resources + */ +export declare class EksContainerDefinition extends Construct implements IEksContainerDefinition { + readonly image: ecs.ContainerImage; + readonly args?: string[]; + readonly command?: string[]; + readonly env?: { + [key: string]: string; + }; + readonly imagePullPolicy?: ImagePullPolicy; + readonly name?: string; + readonly memoryLimit?: Size; + readonly memoryReservation?: Size; + readonly cpuLimit?: number; + readonly cpuReservation?: number; + readonly gpuLimit?: number; + readonly gpuReservation?: number; + readonly privileged?: boolean; + readonly readonlyRootFilesystem?: boolean; + readonly runAsGroup?: number; + readonly runAsRoot?: boolean; + readonly runAsUser?: number; + readonly volumes: EksVolume[]; + private readonly imageConfig; + constructor(scope: Construct, id: string, props: EksContainerDefinitionProps); + addVolume(volume: EksVolume): void; + /** + * + * @internal + */ + _renderContainerDefinition(): CfnJobDefinition.EksContainerProperty; +} +/** + * Options to configure an EksVolume + */ +export interface EksVolumeOptions { + /** + * The name of this volume. + * The name must be a valid DNS subdomain name. + * + * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names + */ + readonly name: string; + /** + * The path on the container where the volume is mounted. + * + * @default - the volume is not mounted + */ + readonly mountPath?: string; + /** + * If specified, the container has readonly access to the volume. + * Otherwise, the container has read/write access. + * + * @default false + */ + readonly readonly?: boolean; +} +/** + * A Volume that can be mounted to a container supported by EKS + */ +export declare abstract class EksVolume { + /** + * Creates a Kubernetes EmptyDir volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir + */ + static emptyDir(options: EmptyDirVolumeOptions): EmptyDirVolume; + /** + * Creates a Kubernetes HostPath volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ + static hostPath(options: HostPathVolumeOptions): HostPathVolume; + /** + * Creates a Kubernetes Secret volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret + */ + static secret(options: SecretPathVolumeOptions): SecretPathVolume; + /** + * The name of this volume. + * The name must be a valid DNS subdomain name. + * + * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names + */ + readonly name: string; + /** + * The path on the container where the container is mounted. + * + * @default - the container is not mounted + */ + readonly containerPath?: string; + /** + * If specified, the container has readonly access to the volume. + * Otherwise, the container has read/write access. + * + * @default false + */ + readonly readonly?: boolean; + constructor(options: EksVolumeOptions); +} +/** + * Options for a Kubernetes EmptyDir volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir + */ +export interface EmptyDirVolumeOptions extends EksVolumeOptions { + /** + * The storage type to use for this Volume. + * + * @default `EmptyDirMediumType.DISK` + */ + readonly medium?: EmptyDirMediumType; + /** + * The maximum size for this Volume + * + * @default - no size limit + */ + readonly sizeLimit?: Size; +} +/** + * What medium the volume will live in + */ +export declare enum EmptyDirMediumType { + /** + * Use the disk storage of the node. + * Items written here will survive node reboots. + */ + DISK = "", + /** + * Use the `tmpfs` volume that is backed by RAM of the node. + * Items written here will *not* survive node reboots. + */ + MEMORY = "Memory" +} +/** + * A Kubernetes EmptyDir volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir + */ +export declare class EmptyDirVolume extends EksVolume { + /** + * Returns `true` if `x` is an EmptyDirVolume, `false` otherwise + */ + static isEmptyDirVolume(x: any): x is EmptyDirVolume; + /** + * The storage type to use for this Volume. + * + * @default `EmptyDirMediumType.DISK` + */ + readonly medium?: EmptyDirMediumType; + /** + * The maximum size for this Volume + * + * @default - no size limit + */ + readonly sizeLimit?: Size; + constructor(options: EmptyDirVolumeOptions); +} +/** + * Options for a kubernetes HostPath volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ +export interface HostPathVolumeOptions extends EksVolumeOptions { + /** + * The path of the file or directory on the host to mount into containers on the pod. + * + * *Note*: HothPath Volumes present many security risks, and should be avoided when possible. + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ + readonly hostPath: string; +} +/** + * A Kubernetes HostPath volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ +export declare class HostPathVolume extends EksVolume { + /** + * returns `true` if `x` is a HostPathVolume, `false` otherwise + */ + static isHostPathVolume(x: any): x is HostPathVolume; + /** + * The path of the file or directory on the host to mount into containers on the pod. + * + * *Note*: HothPath Volumes present many security risks, and should be avoided when possible. + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ + readonly path: string; + constructor(options: HostPathVolumeOptions); +} +/** + * Options for a Kubernetes SecretPath Volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret + */ +export interface SecretPathVolumeOptions extends EksVolumeOptions { + /** + * The name of the secret. + * Must be a valid DNS subdomain name. + * + * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names + */ + readonly secretName: string; + /** + * Specifies whether the secret or the secret's keys must be defined + * + * @default true + */ + readonly optional?: boolean; +} +/** + * Specifies the configuration of a Kubernetes secret volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret + */ +export declare class SecretPathVolume extends EksVolume { + /** + * returns `true` if `x` is a `SecretPathVolume` and `false` otherwise + */ + static isSecretPathVolume(x: any): x is SecretPathVolume; + /** + * The name of the secret. + * Must be a valid DNS subdomain name. + * + * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names + */ + readonly secretName: string; + /** + * Specifies whether the secret or the secret's keys must be defined + * + * @default true + */ + readonly optional?: boolean; + constructor(options: SecretPathVolumeOptions); +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js new file mode 100644 index 0000000000000..bd9b7beec7a4d --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js @@ -0,0 +1,338 @@ +"use strict"; +var _a, _b, _c, _d, _e; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.SecretPathVolume = exports.HostPathVolume = exports.EmptyDirVolume = exports.EmptyDirMediumType = exports.EksVolume = exports.EksContainerDefinition = exports.ImagePullPolicy = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const constructs_1 = require("constructs"); +const EMPTY_DIR_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.EmptyDirVolume'); +const HOST_PATH_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.HostPathVolume'); +const SECRET_PATH_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.SecretVolume'); +/** + * Determines when the image is pulled from the registry to launch a container + */ +var ImagePullPolicy; +(function (ImagePullPolicy) { + /** + * Every time the kubelet launches a container, + * the kubelet queries the container image registry to resolve the name to an image digest. + * If the kubelet has a container image with that exact digest cached locally, + * the kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest, + * and uses that image to launch the container. + * + * @see https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier + */ + ImagePullPolicy["ALWAYS"] = "Always"; + /** + * The image is pulled only if it is not already present locally + */ + ImagePullPolicy["IF_NOT_PRESENT"] = "IfNotPresent"; + /** + * The kubelet does not try fetching the image. + * If the image is somehow already present locally, + * the kubelet attempts to start the container; otherwise, startup fails. + * See pre-pulled images for more details. + * + * @see https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images + */ + ImagePullPolicy["NEVER"] = "Never"; +})(ImagePullPolicy || (exports.ImagePullPolicy = ImagePullPolicy = {})); +/** + * A container that can be run with EKS orchestration on EC2 resources + */ +class EksContainerDefinition extends constructs_1.Construct { + constructor(scope, id, props) { + super(scope, id); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksContainerDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EksContainerDefinition); + } + throw error; + } + this.image = props.image; + this.args = props.args; + this.command = props.command; + this.env = props.env; + this.imagePullPolicy = props.imagePullPolicy; + this.name = props.name; + this.memoryLimit = props.memoryLimit; + this.memoryReservation = props.memoryReservation; + this.cpuLimit = props.cpuLimit; + this.cpuReservation = props.cpuReservation; + this.gpuLimit = props.gpuLimit; + this.gpuReservation = props.gpuReservation; + this.privileged = props.privileged; + this.readonlyRootFilesystem = props.readonlyRootFilesystem; + this.runAsGroup = props.runAsGroup; + this.runAsRoot = props.runAsRoot; + this.runAsUser = props.runAsUser; + this.volumes = props.volumes ?? []; + this.imageConfig = props.image.bind(this, this); + } + addVolume(volume) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksVolume(volume); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addVolume); + } + throw error; + } + this.volumes.push(volume); + } + /** + * + * @internal + */ + _renderContainerDefinition() { + return { + image: this.imageConfig.imageName, + command: this.command, + args: this.args, + env: Object.keys(this.env ?? {}).map((key) => { + return { + name: key, + value: this.env[key], + }; + }), + name: this.name, + imagePullPolicy: this.imagePullPolicy, + resources: { + limits: { + 'cpu': this.cpuLimit, + 'memory': this.memoryLimit ? this.memoryLimit.toMebibytes() + 'Mi' : undefined, + 'nvidia.com/gpu': this.gpuLimit, + }, + requests: { + 'cpu': this.cpuReservation, + 'memory': this.memoryReservation ? this.memoryReservation.toMebibytes() + 'Mi' : undefined, + 'nvidia.com/gpu': this.gpuReservation, + }, + }, + securityContext: { + privileged: this.privileged, + readOnlyRootFilesystem: this.readonlyRootFilesystem, + runAsGroup: this.runAsGroup, + runAsNonRoot: !this.runAsRoot, + runAsUser: this.runAsUser, + }, + volumeMounts: core_1.Lazy.any({ + produce: () => { + if (this.volumes.length === 0) { + return undefined; + } + return this.volumes.map((volume) => { + return { + name: volume.name, + mountPath: volume.containerPath, + readOnly: volume.readonly, + }; + }); + }, + }), + }; + } + ; +} +exports.EksContainerDefinition = EksContainerDefinition; +_a = JSII_RTTI_SYMBOL_1; +EksContainerDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.EksContainerDefinition", version: "0.0.0" }; +/** + * A Volume that can be mounted to a container supported by EKS + */ +class EksVolume { + /** + * Creates a Kubernetes EmptyDir volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir + */ + static emptyDir(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.emptyDir); + } + throw error; + } + return new EmptyDirVolume(options); + } + /** + * Creates a Kubernetes HostPath volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ + static hostPath(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostPathVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.hostPath); + } + throw error; + } + return new HostPathVolume(options); + } + /** + * Creates a Kubernetes Secret volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret + */ + static secret(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.secret); + } + throw error; + } + return new SecretPathVolume(options); + } + constructor(options) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EksVolume); + } + throw error; + } + this.name = options.name; + this.containerPath = options.mountPath; + this.readonly = options.readonly; + } +} +exports.EksVolume = EksVolume; +_b = JSII_RTTI_SYMBOL_1; +EksVolume[_b] = { fqn: "@aws-cdk/aws-batch-alpha.EksVolume", version: "0.0.0" }; +/** + * What medium the volume will live in + */ +var EmptyDirMediumType; +(function (EmptyDirMediumType) { + /** + * Use the disk storage of the node. + * Items written here will survive node reboots. + */ + EmptyDirMediumType["DISK"] = ""; + /** + * Use the `tmpfs` volume that is backed by RAM of the node. + * Items written here will *not* survive node reboots. + */ + EmptyDirMediumType["MEMORY"] = "Memory"; +})(EmptyDirMediumType || (exports.EmptyDirMediumType = EmptyDirMediumType = {})); +/** + * A Kubernetes EmptyDir volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir + */ +class EmptyDirVolume extends EksVolume { + /** + * Returns `true` if `x` is an EmptyDirVolume, `false` otherwise + */ + static isEmptyDirVolume(x) { + return x !== null && typeof (x) === 'object' && EMPTY_DIR_VOLUME_SYMBOL in x; + } + constructor(options) { + super(options); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EmptyDirVolume); + } + throw error; + } + this.medium = options.medium; + this.sizeLimit = options.sizeLimit; + } +} +exports.EmptyDirVolume = EmptyDirVolume; +_c = JSII_RTTI_SYMBOL_1; +EmptyDirVolume[_c] = { fqn: "@aws-cdk/aws-batch-alpha.EmptyDirVolume", version: "0.0.0" }; +Object.defineProperty(EmptyDirVolume.prototype, EMPTY_DIR_VOLUME_SYMBOL, { + value: true, + enumerable: false, + writable: false, +}); +/** + * A Kubernetes HostPath volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath + */ +class HostPathVolume extends EksVolume { + /** + * returns `true` if `x` is a HostPathVolume, `false` otherwise + */ + static isHostPathVolume(x) { + return x !== null && typeof (x) === 'object' && HOST_PATH_VOLUME_SYMBOL in x; + } + constructor(options) { + super(options); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostPathVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, HostPathVolume); + } + throw error; + } + this.path = options.hostPath; + } +} +exports.HostPathVolume = HostPathVolume; +_d = JSII_RTTI_SYMBOL_1; +HostPathVolume[_d] = { fqn: "@aws-cdk/aws-batch-alpha.HostPathVolume", version: "0.0.0" }; +Object.defineProperty(HostPathVolume.prototype, HOST_PATH_VOLUME_SYMBOL, { + value: true, + enumerable: false, + writable: false, +}); +/** + * Specifies the configuration of a Kubernetes secret volume + * + * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret + */ +class SecretPathVolume extends EksVolume { + /** + * returns `true` if `x` is a `SecretPathVolume` and `false` otherwise + */ + static isSecretPathVolume(x) { + return x !== null && typeof (x) === 'object' && SECRET_PATH_VOLUME_SYMBOL in x; + } + constructor(options) { + super(options); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(options); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, SecretPathVolume); + } + throw error; + } + this.secretName = options.secretName; + this.optional = options.optional ?? true; + } +} +exports.SecretPathVolume = SecretPathVolume; +_e = JSII_RTTI_SYMBOL_1; +SecretPathVolume[_e] = { fqn: "@aws-cdk/aws-batch-alpha.SecretPathVolume", version: "0.0.0" }; +Object.defineProperty(SecretPathVolume.prototype, SECRET_PATH_VOLUME_SYMBOL, { + value: true, + enumerable: false, + writable: false, +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUNBLDJDQUE4QztBQUM5QywyQ0FBbUQ7QUFHbkQsTUFBTSx1QkFBdUIsR0FBRyxNQUFNLENBQUMsR0FBRyxDQUFDLG1FQUFtRSxDQUFDLENBQUM7QUFDaEgsTUFBTSx1QkFBdUIsR0FBRyxNQUFNLENBQUMsR0FBRyxDQUFDLG1FQUFtRSxDQUFDLENBQUM7QUFDaEgsT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PTCwge1xuICB2YWx1ZTogdHJ1ZSxcbiAgZW51bWVyYWJsZTogZmFsc2UsXG4gIHdyaXRhYmxlOiBmYWxzZSxcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts new file mode 100644 index 0000000000000..02e0bf442017d --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts @@ -0,0 +1,123 @@ +import { Construct } from 'constructs'; +import { EksContainerDefinition } from './eks-container-definition'; +import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; +/** + * A JobDefinition that uses Eks orchestration + */ +export interface IEksJobDefinition extends IJobDefinition { + /** + * The container this Job Definition will run + */ + readonly container: EksContainerDefinition; + /** + * The DNS Policy of the pod used by this Job Definition + * + * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy + * + * @default `DnsPolicy.CLUSTER_FIRST` + */ + readonly dnsPolicy?: DnsPolicy; + /** + * If specified, the Pod used by this Job Definition will use the host's network IP address. + * Otherwise, the Kubernetes pod networking model is enabled. + * Most AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections. + * + * @default true + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#host-namespaces + * @see https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking + */ + readonly useHostNetwork?: boolean; + /** + * The name of the service account that's used to run the container. + * service accounts are Kubernetes method of identification and authentication, + * roughly analogous to IAM users. + * + * @see https://docs.aws.amazon.com/eks/latest/userguide/service-accounts.html + * @see https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ + * @see https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html + * + * @default - the default service account of the container + */ + readonly serviceAccount?: string; +} +/** + * Props for EksJobDefinition + */ +export interface EksJobDefinitionProps extends JobDefinitionProps { + /** + * The container this Job Definition will run + */ + readonly container: EksContainerDefinition; + /** + * The DNS Policy of the pod used by this Job Definition + * + * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy + * + * @default `DnsPolicy.CLUSTER_FIRST` + */ + readonly dnsPolicy?: DnsPolicy; + /** + * If specified, the Pod used by this Job Definition will use the host's network IP address. + * Otherwise, the Kubernetes pod networking model is enabled. + * Most AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections. + * + * @default true + * + * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#host-namespaces + * @see https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking + */ + readonly useHostNetwork?: boolean; + /** + * The name of the service account that's used to run the container. + * service accounts are Kubernetes method of identification and authentication, + * roughly analogous to IAM users. + * + * @see https://docs.aws.amazon.com/eks/latest/userguide/service-accounts.html + * @see https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ + * @see https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html + * + * @default - the default service account of the container + */ + readonly serviceAccount?: string; +} +/** + * The DNS Policy for the pod used by the Job Definition + * + * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy + */ +export declare enum DnsPolicy { + /** + * The Pod inherits the name resolution configuration from the node that the Pods run on + */ + DEFAULT = "Default", + /** + * Any DNS query that does not match the configured cluster domain suffix, such as `"www.kubernetes.io"`, + * is forwarded to an upstream nameserver by the DNS server. + * Cluster administrators may have extra stub-domain and upstream DNS servers configured. + */ + CLUSTER_FIRST = "ClusterFirst", + /** + * For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`. + * Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy. + */ + CLUSTER_FIRST_WITH_HOST_NET = "ClusterFirstWithHostNet" +} +/** + * A JobDefinition that uses Eks orchestration + * + * @resource AWS::Batch::JobDefinition + */ +export declare class EksJobDefinition extends JobDefinitionBase implements IEksJobDefinition { + /** + * Import an EksJobDefinition by its arn + */ + static fromEksJobDefinitionArn(scope: Construct, id: string, eksJobDefinitionArn: string): IEksJobDefinition; + readonly container: EksContainerDefinition; + readonly dnsPolicy?: DnsPolicy; + readonly useHostNetwork?: boolean; + readonly serviceAccount?: string; + readonly jobDefinitionArn: string; + readonly jobDefinitionName: string; + constructor(scope: Construct, id: string, props: EksJobDefinitionProps); +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js new file mode 100644 index 0000000000000..cb23b62ee18c9 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js @@ -0,0 +1,134 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.EksJobDefinition = exports.DnsPolicy = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +const eks_container_definition_1 = require("./eks-container-definition"); +const job_definition_base_1 = require("./job-definition-base"); +/** + * The DNS Policy for the pod used by the Job Definition + * + * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy + */ +var DnsPolicy; +(function (DnsPolicy) { + /** + * The Pod inherits the name resolution configuration from the node that the Pods run on + */ + DnsPolicy["DEFAULT"] = "Default"; + /** + * Any DNS query that does not match the configured cluster domain suffix, such as `"www.kubernetes.io"`, + * is forwarded to an upstream nameserver by the DNS server. + * Cluster administrators may have extra stub-domain and upstream DNS servers configured. + */ + DnsPolicy["CLUSTER_FIRST"] = "ClusterFirst"; + /** + * For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`. + * Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy. + */ + DnsPolicy["CLUSTER_FIRST_WITH_HOST_NET"] = "ClusterFirstWithHostNet"; +})(DnsPolicy || (exports.DnsPolicy = DnsPolicy = {})); +/** + * A JobDefinition that uses Eks orchestration + * + * @resource AWS::Batch::JobDefinition + */ +class EksJobDefinition extends job_definition_base_1.JobDefinitionBase { + /** + * Import an EksJobDefinition by its arn + */ + static fromEksJobDefinitionArn(scope, id, eksJobDefinitionArn) { + const stack = core_1.Stack.of(scope); + const jobDefinitionName = stack.splitArn(eksJobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + class Import extends job_definition_base_1.JobDefinitionBase { + constructor() { + super(...arguments); + this.jobDefinitionArn = eksJobDefinitionArn; + this.jobDefinitionName = jobDefinitionName; + this.enabled = true; + this.container = {}; + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksJobDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, EksJobDefinition); + } + throw error; + } + this.container = props.container; + this.dnsPolicy = props.dnsPolicy; + this.useHostNetwork = props.useHostNetwork; + this.serviceAccount = props.serviceAccount; + const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { + ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), + type: 'container', + jobDefinitionName: props.jobDefinitionName, + eksProperties: { + podProperties: { + containers: [ + this.container._renderContainerDefinition(), + ], + dnsPolicy: this.dnsPolicy, + hostNetwork: this.useHostNetwork, + serviceAccountName: this.serviceAccount, + volumes: core_1.Lazy.any({ + produce: () => { + if (this.container.volumes.length === 0) { + return undefined; + } + return this.container.volumes.map((volume) => { + if (eks_container_definition_1.EmptyDirVolume.isEmptyDirVolume(volume)) { + return { + name: volume.name, + emptyDir: { + medium: volume.medium, + sizeLimit: volume.sizeLimit ? volume.sizeLimit.toMebibytes().toString() + 'Mi' : undefined, + }, + }; + } + if (eks_container_definition_1.HostPathVolume.isHostPathVolume(volume)) { + return { + name: volume.name, + hostPath: { + path: volume.path, + }, + }; + } + if (eks_container_definition_1.SecretPathVolume.isSecretPathVolume(volume)) { + return { + name: volume.name, + secret: { + optional: volume.optional, + secretName: volume.secretName, + }, + }; + } + throw new Error('unknown volume type'); + }); + }, + }), + }, + }, + }); + this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { + service: 'batch', + resource: 'job-definition', + resourceName: this.physicalName, + }); + this.jobDefinitionName = this.getResourceNameAttribute(resource.ref); + } +} +exports.EksJobDefinition = EksJobDefinition; +_a = JSII_RTTI_SYMBOL_1; +EksJobDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.EksJobDefinition", version: "0.0.0" }; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWtzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUEwRDtBQUUxRCxxREFBeUQ7QUFDekQseUVBQXNIO0FBQ3RILCtEQUEySDtBQTBGM0g7Ozs7R0FJRztBQUNILElBQVksU0FrQlg7QUFsQkQsV0FBWSxTQUFTO0lBQ25COztPQUVHO0lBQ0gsZ0NBQW1CLENBQUE7SUFFbkI7Ozs7T0FJRztJQUNILDJDQUE4QixDQUFBO0lBRTlCOzs7T0FHRztJQUNILG9FQUF1RCxDQUFBO0FBQ3pELENBQUMsRUFsQlcsU0FBUyx5QkFBVCxTQUFTLFFBa0JwQjtBQUVEOzs7O0dBSUc7QUFDSCxNQUFhLGdCQUFpQixTQUFRLHVDQUFpQjtJQUNyRDs7T0FFRztJQUNJLE1BQU0sQ0FBQyx1QkFBdUIsQ0FBQyxLQUFnQixFQUFFLEVBQVUsRUFBRSxtQkFBMkI7UUFDN0YsTUFBTSxLQUFLLEdBQUcsWUFBSyxDQU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cm9kdWNlOiAoKSA9PiB7XG4gICAgICAgICAgICAgIGlmICh0aGlzLmNvbnRhaW5lci52b2x1bWVzLmxlbmd0aCA9PT0gMCkge1xuICAgICAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuY29udGFpbmVyLnZvbHVtZXMubWFwKCh2b2x1bWUpID0+IHtcbiAgICAgICAgICAgICAgICBpZiAoRW1wdHlEaXJWb2x1bWUuaXNFbXB0eURpclZvbHVtZSh2b2x1bWUpKSB7XG4gICAgICAgICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAgICAgICBuYW1lOiB2b2x1bWUubmFtZSxcbiAgICAgICAgICAgICAgICAgICAgZW1wdHlEaXI6IHtcbiAgICAgICAgICAgICAgICAgICAgICBtZWRpdW06IHZvbHVtZS5tZWRpdW0sXG4gICAgICAgICAgICAgICAgICAgICAgc2l6ZUxpbWl0OiB2b2x1bWUuc2l6ZUxpbWl0ID8gdm9sdW1lLnNpemVMaW1pdC50b01lYmlieXRlcygpLnRvU3RyaW5nKCkgKyAnTWknIDogdW5kZWZpbmVkLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgaWYgKEhvc3RQYXRoVm9sdW1lLmlzSG9zdFBhdGhWb2x1bWUodm9sdW1lKSkge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgbmFtZTogdm9sdW1lLm5hbWUsXG4gICAgICAgICAgICAgICAgICAgIGhvc3RQYXRoOiB7XG4gICAgICAgICAgICAgICAgICAgICAgcGF0aDogdm9sdW1lLnBhdGgsXG4gICAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAoU2VjcmV0UGF0aFZvbHVtZS5pc1NlY3JldFBhdGhWb2x1bWUodm9sdW1lKSkge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgbmFtZTogdm9sdW1lLm5hbWUsXG4gICAgICAgICAgICAgICAgICAgIHNlY3JldDoge1xuICAgICAgICAgICAgICAgICAgICAgIG9wdGlvbmFsOiB2b2x1bWUub3B0aW9uYWwsXG4gICAgICAgICAgICAgICAgICAgICAgc2VjcmV0TmFtZTogdm9sdW1lLnNlY3JldE5hbWUsXG4gICAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcigndW5rbm93biB2b2x1bWUgdHlwZScpO1xuICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSksXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICAgIHRoaXMuam9iRGVmaW5pdGlvbkFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UucmVmLCB7XG4gICAgICBzZXJ2aWNlOiAnYmF0Y2gnLFxuICAgICAgcmVzb3VyY2U6ICdqb2ItZGVmaW5pdGlvbicsXG4gICAgICByZXNvdXJjZU5hbWU6IHRoaXMucGh5c2ljYWxOYW1lLFxuICAgIH0pO1xuICAgIHRoaXMuam9iRGVmaW5pdGlvbk5hbWUgPSB0aGlzLmdldFJlc291cmNlTmFtZUF0dHJpYnV0ZShyZXNvdXJjZS5yZWYpO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts new file mode 100644 index 0000000000000..ffad48bef4c02 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts @@ -0,0 +1,12 @@ +export * from './ecs-job-definition'; +export { IComputeEnvironment, ComputeEnvironmentProps } from './compute-environment-base'; +export * from './eks-job-definition'; +export * from './ecs-container-definition'; +export * from './eks-container-definition'; +export * from './job-definition-base'; +export * from './job-queue'; +export * from './linux-parameters'; +export * from './managed-compute-environment'; +export * from './multinode-job-definition'; +export * from './scheduling-policy'; +export * from './unmanaged-compute-environment'; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/index.js b/packages/@aws-cdk/aws-batch-alpha/lib/index.js new file mode 100644 index 0000000000000..586a60b134365 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/index.js @@ -0,0 +1,29 @@ +"use strict"; +var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + var desc = Object.getOwnPropertyDescriptor(m, k); + if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { + desc = { enumerable: true, get: function() { return m[k]; } }; + } + Object.defineProperty(o, k2, desc); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +})); +var __exportStar = (this && this.__exportStar) || function(m, exports) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); +}; +Object.defineProperty(exports, "__esModule", { value: true }); +// AWS::Batch CloudFormation Resources: +__exportStar(require("./ecs-job-definition"), exports); +__exportStar(require("./eks-job-definition"), exports); +__exportStar(require("./ecs-container-definition"), exports); +__exportStar(require("./eks-container-definition"), exports); +__exportStar(require("./job-definition-base"), exports); +__exportStar(require("./job-queue"), exports); +__exportStar(require("./linux-parameters"), exports); +__exportStar(require("./managed-compute-environment"), exports); +__exportStar(require("./multinode-job-definition"), exports); +__exportStar(require("./scheduling-policy"), exports); +__exportStar(require("./unmanaged-compute-environment"), exports); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50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newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts new file mode 100644 index 0000000000000..27ab7a53f3600 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts @@ -0,0 +1,217 @@ +import { Duration, IResource, Resource } from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +import { CfnJobDefinitionProps } from 'aws-cdk-lib/aws-batch'; +/** + * Represents a JobDefinition + */ +export interface IJobDefinition extends IResource { + /** + * The ARN of this job definition + * + * @attribute + */ + readonly jobDefinitionArn: string; + /** + * The name of this job definition + * + * @attribute + */ + readonly jobDefinitionName: string; + /** + * The default parameters passed to the container + * These parameters can be referenced in the `command` that + * you give to the container + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters + * + * @default none + */ + readonly parameters?: { + [key: string]: any; + }; + /** + * The number of times to retry a job. + * The job is retried on failure the same number of attempts as the value. + * + * @default 1 + */ + readonly retryAttempts?: number; + /** + * Defines the retry behavior for this job + * + * @default - no `RetryStrategy` + */ + readonly retryStrategies: RetryStrategy[]; + /** + * The priority of this Job. Only used in Fairshare Scheduling + * to decide which job to run first when there are multiple jobs + * with the same share identifier. + * + * @default none + */ + readonly schedulingPriority?: number; + /** + * The timeout time for jobs that are submitted with this job definition. + * After the amount of time you specify passes, + * Batch terminates your jobs if they aren't finished. + * + * @default - no timeout + */ + readonly timeout?: Duration; + /** + * Add a RetryStrategy to this JobDefinition + */ + addRetryStrategy(strategy: RetryStrategy): void; +} +/** + * Props common to all JobDefinitions + */ +export interface JobDefinitionProps { + /** + * The name of this job definition + * + * @default - generated by CloudFormation + */ + readonly jobDefinitionName?: string; + /** + * The default parameters passed to the container + * These parameters can be referenced in the `command` that + * you give to the container + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters + * + * @default none + */ + readonly parameters?: { + [key: string]: any; + }; + /** + * The number of times to retry a job. + * The job is retried on failure the same number of attempts as the value. + * + * @default 1 + */ + readonly retryAttempts?: number; + /** + * Defines the retry behavior for this job + * + * @default - no `RetryStrategy` + */ + readonly retryStrategies?: RetryStrategy[]; + /** + * The priority of this Job. Only used in Fairshare Scheduling + * to decide which job to run first when there are multiple jobs + * with the same share identifier. + * + * @default none + */ + readonly schedulingPriority?: number; + /** + * The timeout time for jobs that are submitted with this job definition. + * After the amount of time you specify passes, + * Batch terminates your jobs if they aren't finished. + * + * @default - no timeout + */ + readonly timeout?: Duration; +} +/** + * Define how Jobs using this JobDefinition respond to different exit conditions + */ +export declare class RetryStrategy { + /** + * Create a new RetryStrategy + */ + static of(action: Action, on: Reason): RetryStrategy; + /** + * The action to take when the job exits with the Reason specified + */ + readonly action: Action; + /** + * If the job exits with this Reason it will trigger the specified Action + */ + readonly on: Reason; + constructor(action: Action, on: Reason); +} +/** + * The Action to take when all specified conditions in a RetryStrategy are met + */ +export declare enum Action { + /** + * The job will not retry + */ + EXIT = "EXIT", + /** + * The job will retry. It can be retried up to the number of times specified in `retryAttempts`. + */ + RETRY = "RETRY" +} +/** + * The corresponding Action will only be taken if *all* of the conditions specified here are met. + */ +export interface CustomReason { + /** + * A glob string that will match on the job exit code. For example, `'40*'` will match 400, 404, 40123456789012 + * + * @default - will not match on the exit code + */ + readonly onExitCode?: string; + /** + * A glob string that will match on the statusReason returned by the exiting job. + * For example, `'Host EC2*'` indicates that the spot instance has been reclaimed. + * + * @default - will not match on the status reason + */ + readonly onStatusReason?: string; + /** + * A glob string that will match on the reason returned by the exiting job + * For example, `'CannotPullContainerError*'` indicates that container needed to start the job could not be pulled. + * + * @default - will not match on the reason + */ + readonly onReason?: string; +} +/** + * Common job exit reasons + */ +export declare class Reason { + /** + * Will match any non-zero exit code + */ + static readonly NON_ZERO_EXIT_CODE: Reason; + /** + * Will only match if the Docker container could not be pulled + */ + static readonly CANNOT_PULL_CONTAINER: Reason; + /** + * Will only match if the Spot instance executing the job was reclaimed + */ + static readonly SPOT_INSTANCE_RECLAIMED: Reason; + /** + * A custom Reason that can match on multiple conditions. + * Note that all specified conditions must be met for this reason to match. + */ + static custom(customReasonProps: CustomReason): Reason; +} +/** + * Abstract base class for JobDefinitions + * + * @internal + */ +export declare abstract class JobDefinitionBase extends Resource implements IJobDefinition { + abstract readonly jobDefinitionArn: string; + abstract readonly jobDefinitionName: string; + readonly parameters?: { + [key: string]: any; + }; + readonly retryAttempts?: number; + readonly retryStrategies: RetryStrategy[]; + readonly schedulingPriority?: number; + readonly timeout?: Duration; + constructor(scope: Construct, id: string, props?: JobDefinitionProps); + addRetryStrategy(strategy: RetryStrategy): void; +} +/** + * @internal + */ +export declare function baseJobDefinitionProperties(baseJobDefinition: JobDefinitionBase): CfnJobDefinitionProps; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js new file mode 100644 index 0000000000000..14745de9bb71c --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js @@ -0,0 +1,153 @@ +"use strict"; +var _a, _b; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.baseJobDefinitionProperties = exports.JobDefinitionBase = exports.Reason = exports.Action = exports.RetryStrategy = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +/** + * Define how Jobs using this JobDefinition respond to different exit conditions + */ +class RetryStrategy { + /** + * Create a new RetryStrategy + */ + static of(action, on) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Action(action); + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Reason(on); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.of); + } + throw error; + } + return new RetryStrategy(action, on); + } + constructor(action, on) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Action(action); + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Reason(on); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, RetryStrategy); + } + throw error; + } + this.action = action; + this.on = on; + } +} +exports.RetryStrategy = RetryStrategy; +_a = JSII_RTTI_SYMBOL_1; +RetryStrategy[_a] = { fqn: "@aws-cdk/aws-batch-alpha.RetryStrategy", version: "0.0.0" }; +/** + * The Action to take when all specified conditions in a RetryStrategy are met + */ +var Action; +(function (Action) { + /** + * The job will not retry + */ + Action["EXIT"] = "EXIT"; + /** + * The job will retry. It can be retried up to the number of times specified in `retryAttempts`. + */ + Action["RETRY"] = "RETRY"; +})(Action || (exports.Action = Action = {})); +/** + * Common job exit reasons + */ +class Reason { + /** + * A custom Reason that can match on multiple conditions. + * Note that all specified conditions must be met for this reason to match. + */ + static custom(customReasonProps) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_CustomReason(customReasonProps); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.custom); + } + throw error; + } + return customReasonProps; + } +} +exports.Reason = Reason; +_b = JSII_RTTI_SYMBOL_1; +Reason[_b] = { fqn: "@aws-cdk/aws-batch-alpha.Reason", version: "0.0.0" }; +/** + * Will match any non-zero exit code + */ +Reason.NON_ZERO_EXIT_CODE = { + onExitCode: '*', +}; +/** + * Will only match if the Docker container could not be pulled + */ +Reason.CANNOT_PULL_CONTAINER = { + onReason: 'CannotPullContainerError:*', +}; +/** + * Will only match if the Spot instance executing the job was reclaimed + */ +Reason.SPOT_INSTANCE_RECLAIMED = { + onStatusReason: 'Host EC2*', +}; +/** + * Abstract base class for JobDefinitions + * + * @internal + */ +class JobDefinitionBase extends core_1.Resource { + constructor(scope, id, props) { + super(scope, id, { + physicalName: props?.jobDefinitionName, + }); + this.parameters = props?.parameters; + this.retryAttempts = props?.retryAttempts; + this.retryStrategies = props?.retryStrategies ?? []; + this.schedulingPriority = props?.schedulingPriority; + this.timeout = props?.timeout; + } + addRetryStrategy(strategy) { + this.retryStrategies.push(strategy); + } +} +exports.JobDefinitionBase = JobDefinitionBase; +/** + * @internal + */ +function baseJobDefinitionProperties(baseJobDefinition) { + return { + parameters: baseJobDefinition.parameters, + retryStrategy: { + attempts: baseJobDefinition.retryAttempts, + evaluateOnExit: core_1.Lazy.any({ + produce: () => { + if (baseJobDefinition.retryStrategies.length === 0) { + return undefined; + } + return baseJobDefinition.retryStrategies.map((strategy) => { + return { + action: strategy.action, + ...strategy.on, + }; + }); + }, + }), + }, + schedulingPriority: baseJobDefinition.schedulingPriority, + timeout: { + attemptDurationSeconds: baseJobDefinition.timeout?.toSeconds(), + }, + type: 'dummy', + }; +} +exports.baseJobDefinitionProperties = baseJobDefinitionProperties; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLWRlZmluaXRpb24tYmFzZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImpvYi1kZWZpbml0aW9uLWJhc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsMkNBQXVFO0FBZ0l2RTs7R0FFRztBQUNILE1BQWEsYUFBYTtJQUN4Qjs7T0FFRztJQUNJLE1BQU0sQ0FBQyxFQUFFLENBQUMsTUFBYyxFQUFFLEVBQVU7Ozs7Ozs7Ozs7O1FBQ3pDLE9BQU8sSUFBSSxhQUFhLENBQUMsTUFBTSxFQUFFLEVBQUUsQ0FBQyxDQUFDO0tBQ3RDO0lBWUQsWUFBWSxNQUFjLEVBQUUsRUFBVTs7Ozs7OzsrQ0FsQjNCLGFBQWE7Ozs7UUFtQnRCLElBQUksQ0FBQyxNQUFNLEdBQUcsTUFBTSxDQUFDO1FBQ3JCLElBQUksQ0FBQyxFQUFFLEdBQUcsRUFBRSxDQUFDO0tBQ2Q7O0FBckJILHNDQXNCQzs7O0FBRU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MsXG4gICAgICBldmFsdWF0ZU9uRXhpdDogTGF6eS5hbnkoe1xuICAgICAgICBwcm9kdWNlOiAoKSA9PiB7XG4gICAgICAgICAgaWYgKGJhc2VKb2JEZWZpbml0aW9uLnJldHJ5U3RyYXRlZ2llcy5sZW5ndGggPT09IDApIHtcbiAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XG4gICAgICAgICAgfVxuICAgICAgICAgIHJldHVybiBiYXNlSm9iRGVmaW5pdGlvbi5yZXRyeVN0cmF0ZWdpZXMubWFwKChzdHJhdGVneSkgPT4ge1xuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgYWN0aW9uOiBzdHJhdGVneS5hY3Rpb24sXG4gICAgICAgICAgICAgIC4uLnN0cmF0ZWd5Lm9uLFxuICAgICAgICAgICAgfTtcbiAgICAgICAgICB9KTtcbiAgICAgICAgfSxcbiAgICAgIH0pLFxuICAgIH0sXG4gICAgc2NoZWR1bGluZ1ByaW9yaXR5OiBiYXNlSm9iRGVmaW5pdGlvbi5zY2hlZHVsaW5nUHJpb3JpdHksXG4gICAgdGltZW91dDoge1xuICAgICAgYXR0ZW1wdER1cmF0aW9uU2Vjb25kczogYmFzZUpvYkRlZmluaXRpb24udGltZW91dD8udG9TZWNvbmRzKCksXG4gICAgfSxcbiAgICB0eXBlOiAnZHVtbXknLFxuICB9O1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts new file mode 100644 index 0000000000000..d72695ba8bdbb --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts @@ -0,0 +1,140 @@ +import { IResource, Resource } from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +import { IComputeEnvironment } from './compute-environment-base'; +import { ISchedulingPolicy } from './scheduling-policy'; +/** + * Represents a JobQueue + */ +export interface IJobQueue extends IResource { + /** + * The name of the job queue. It can be up to 128 letters long. + * It can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_) + * + * @attribute + */ + readonly jobQueueName: string; + /** + * The ARN of this job queue + * + * @attribute + */ + readonly jobQueueArn: string; + /** + * The set of compute environments mapped to a job queue and their order relative to each other. + * The job scheduler uses this parameter to determine which compute environment runs a specific job. + * Compute environments must be in the VALID state before you can associate them with a job queue. + * You can associate up to three compute environments with a job queue. + * All of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT); + * EC2 and Fargate compute environments can't be mixed. + * + * *Note*: All compute environments that are associated with a job queue must share the same architecture. + * AWS Batch doesn't support mixing compute environment architecture types in a single job queue. + */ + readonly computeEnvironments: OrderedComputeEnvironment[]; + /** + * The priority of the job queue. + * Job queues with a higher priority are evaluated first when associated with the same compute environment. + * Priority is determined in descending order. + * For example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1. + */ + readonly priority: number; + /** + * If the job queue is enabled, it is able to accept jobs. + * Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish. + * + * @default true + */ + readonly enabled?: boolean; + /** + * The SchedulingPolicy for this JobQueue. Instructs the Scheduler how to schedule different jobs. + * + * @default - no scheduling policy + */ + readonly schedulingPolicy?: ISchedulingPolicy; + /** + * Add a `ComputeEnvironment` to this Queue. + * The Queue will prefer lower-order `ComputeEnvironment`s. + */ + addComputeEnvironment(computeEnvironment: IComputeEnvironment, order: number): void; +} +/** + * Props to configure a JobQueue + */ +export interface JobQueueProps { + /** + * The set of compute environments mapped to a job queue and their order relative to each other. + * The job scheduler uses this parameter to determine which compute environment runs a specific job. + * Compute environments must be in the VALID state before you can associate them with a job queue. + * You can associate up to three compute environments with a job queue. + * All of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT); + * EC2 and Fargate compute environments can't be mixed. + * + * *Note*: All compute environments that are associated with a job queue must share the same architecture. + * AWS Batch doesn't support mixing compute environment architecture types in a single job queue. + * + * @default none + */ + readonly computeEnvironments?: OrderedComputeEnvironment[]; + /** + * The priority of the job queue. + * Job queues with a higher priority are evaluated first when associated with the same compute environment. + * Priority is determined in descending order. + * For example, a job queue with a priority of 10 is given scheduling preference over a job queue with a priority of 1. + * + * @default 1 + */ + readonly priority?: number; + /** + * The name of the job queue. It can be up to 128 letters long. + * It can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_) + * + * @default - no name + */ + readonly jobQueueName?: string; + /** + * If the job queue is enabled, it is able to accept jobs. + * Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish. + * + * @default true + */ + readonly enabled?: boolean; + /** + * The SchedulingPolicy for this JobQueue. Instructs the Scheduler how to schedule different jobs. + * + * @default - no scheduling policy + */ + readonly schedulingPolicy?: ISchedulingPolicy; +} +/** + * Assigns an order to a ComputeEnvironment. + * The JobQueue will prioritize the lowest-order ComputeEnvironment. + */ +export interface OrderedComputeEnvironment { + /** + * The ComputeEnvironment to link to this JobQueue + */ + readonly computeEnvironment: IComputeEnvironment; + /** + * The order associated with `computeEnvironment` + */ + readonly order: number; +} +/** + * JobQueues can receive Jobs, which are removed from the queue when + * sent to the linked ComputeEnvironment(s) to be executed. + * Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked. + */ +export declare class JobQueue extends Resource implements IJobQueue { + /** + * refer to an existing JobQueue by its arn + */ + static fromJobQueueArn(scope: Construct, id: string, jobQueueArn: string): IJobQueue; + readonly computeEnvironments: OrderedComputeEnvironment[]; + readonly priority: number; + readonly enabled?: boolean; + readonly schedulingPolicy?: ISchedulingPolicy; + readonly jobQueueArn: string; + readonly jobQueueName: string; + constructor(scope: Construct, id: string, props?: JobQueueProps); + addComputeEnvironment(computeEnvironment: IComputeEnvironment, order: number): void; +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js new file mode 100644 index 0000000000000..a769e9e07cb5e --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js @@ -0,0 +1,102 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.JobQueue = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +/** + * JobQueues can receive Jobs, which are removed from the queue when + * sent to the linked ComputeEnvironment(s) to be executed. + * Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked. + */ +class JobQueue extends core_1.Resource { + /** + * refer to an existing JobQueue by its arn + */ + static fromJobQueueArn(scope, id, jobQueueArn) { + const stack = core_1.Stack.of(scope); + class Import extends core_1.Resource { + constructor() { + super(...arguments); + this.computeEnvironments = []; + this.priority = 1; + this.jobQueueArn = jobQueueArn; + this.jobQueueName = stack.splitArn(jobQueueArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + } + addComputeEnvironment(_computeEnvironment, _order) { + throw new Error(`cannot add ComputeEnvironments to imported JobQueue '${id}'`); + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, { + physicalName: props?.jobQueueName, + }); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_JobQueueProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, JobQueue); + } + throw error; + } + this.computeEnvironments = props?.computeEnvironments ?? []; + this.priority = props?.priority ?? 1; + this.enabled = props?.enabled; + this.schedulingPolicy = props?.schedulingPolicy; + const resource = new aws_batch_1.CfnJobQueue(this, 'Resource', { + computeEnvironmentOrder: core_1.Lazy.any({ + produce: () => this.computeEnvironments.map((ce) => { + return { + computeEnvironment: ce.computeEnvironment.computeEnvironmentArn, + order: ce.order, + }; + }), + }), + priority: this.priority, + jobQueueName: props?.jobQueueName, + state: (this.enabled ?? true) ? 'ENABLED' : 'DISABLED', + schedulingPolicyArn: this.schedulingPolicy?.schedulingPolicyArn, + }); + this.jobQueueArn = this.getResourceArnAttribute(resource.attrJobQueueArn, { + service: 'batch', + resource: 'job-queue', + resourceName: this.physicalName, + }); + this.jobQueueName = core_1.Stack.of(this).splitArn(this.jobQueueArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + this.node.addValidation({ validate: () => validateOrderedComputeEnvironments(this.computeEnvironments) }); + } + addComputeEnvironment(computeEnvironment, order) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_IComputeEnvironment(computeEnvironment); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addComputeEnvironment); + } + throw error; + } + this.computeEnvironments.push({ + computeEnvironment, + order, + }); + } +} +exports.JobQueue = JobQueue; +_a = JSII_RTTI_SYMBOL_1; +JobQueue[_a] = { fqn: "@aws-cdk/aws-batch-alpha.JobQueue", version: "0.0.0" }; +function validateOrderedComputeEnvironments(computeEnvironments) { + const seenOrders = []; + for (const ce of computeEnvironments) { + if (seenOrders.includes(ce.order)) { + return ['assigns the same order to different ComputeEnvironments']; + } + seenOrders.push(ce.order); + } + return seenOrders.length === 0 ? ['This JobQueue does not link any ComputeEnvironments'] : []; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLXF1ZXVlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiam9iLXF1ZXVlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUErRTtBQUUvRSxxREFBb0Q7QUF1SXBEOzs7O0dBSUc7QUFDSCxNQUFhLFFBQVMsU0FBUSxlQUFRO0lBQ3BDOztPQUVHO0lBQ0ksTUFBTSxDQUFDLGVBQWUsQ0FBQyxLQUFnQixFQUFFLEVBQVUsRUFBRSxXQUFtQjtRQUM3RSxNQUFNLEtBQUssR0FBRyxZQUFLLENBQUMsRUFBRSxDQUFDLEtBQ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ZUVudmlyb25tZW50cyddIDogW107XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts new file mode 100644 index 0000000000000..e9336be95bd7a --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts @@ -0,0 +1,196 @@ +import * as cdk from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; +/** + * The properties for defining Linux-specific options that are applied to the container. + */ +export interface LinuxParametersProps { + /** + * Specifies whether to run an init process inside the container that forwards signals and reaps processes. + * + * @default false + */ + readonly initProcessEnabled?: boolean; + /** + * The value for the size of the /dev/shm volume. + * + * @default No shared memory. + */ + readonly sharedMemorySize?: cdk.Size; + /** + * The total amount of swap memory a container can use. This parameter + * will be translated to the --memory-swap option to docker run. + * + * This parameter is only supported when you are using the EC2 launch type. + * Accepted values are positive integers. + * + * @default No swap. + */ + readonly maxSwap?: cdk.Size; + /** + * This allows you to tune a container's memory swappiness behavior. This parameter + * maps to the --memory-swappiness option to docker run. The swappiness relates + * to the kernel's tendency to swap memory. A value of 0 will cause swapping to + * not happen unless absolutely necessary. A value of 100 will cause pages to + * be swapped very aggressively. + * + * This parameter is only supported when you are using the EC2 launch type. + * Accepted values are whole numbers between 0 and 100. If a value is not + * specified for maxSwap then this parameter is ignored. + * + * @default 60 + */ + readonly swappiness?: number; +} +/** + * Linux-specific options that are applied to the container. + */ +export declare class LinuxParameters extends Construct { + /** + * Whether the init process is enabled + */ + protected readonly initProcessEnabled?: boolean; + /** + * The shared memory size (in MiB). Not valid for Fargate launch type + */ + protected readonly sharedMemorySize?: cdk.Size; + /** + * The max swap memory + */ + protected readonly maxSwap?: cdk.Size; + /** + * The swappiness behavior + */ + protected readonly swappiness?: number; + /** + * Device mounts + */ + protected readonly devices: Device[]; + /** + * TmpFs mounts + */ + protected readonly tmpfs: Tmpfs[]; + /** + * Constructs a new instance of the LinuxParameters class. + */ + constructor(scope: Construct, id: string, props?: LinuxParametersProps); + private validateProps; + /** + * Adds one or more host devices to a container. + */ + addDevices(...device: Device[]): void; + /** + * Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container. + * + * Only works with EC2 launch type. + */ + addTmpfs(...tmpfs: Tmpfs[]): void; + /** + * Renders the Linux parameters to the Batch version of this resource, + * which does not have 'capabilities' and requires tmpfs.containerPath to be defined. + */ + renderLinuxParameters(): CfnJobDefinition.LinuxParametersProperty; +} +/** + * A container instance host device. + */ +export interface Device { + /** + * The path inside the container at which to expose the host device. + * + * @default Same path as the host + */ + readonly containerPath?: string; + /** + * The path for the device on the host container instance. + */ + readonly hostPath: string; + /** + * The explicit permissions to provide to the container for the device. + * By default, the container has permissions for read, write, and mknod for the device. + * + * @default Readonly + */ + readonly permissions?: DevicePermission[]; +} +/** + * The details of a tmpfs mount for a container. + */ +export interface Tmpfs { + /** + * The absolute file path where the tmpfs volume is to be mounted. + */ + readonly containerPath: string; + /** + * The size (in MiB) of the tmpfs volume. + */ + readonly size: cdk.Size; + /** + * The list of tmpfs volume mount options. For more information, see + * [TmpfsMountOptions](https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_Tmpfs.html). + * + * @default none + */ + readonly mountOptions?: TmpfsMountOption[]; +} +/** + * Permissions for device access + */ +export declare enum DevicePermission { + /** + * Read + */ + READ = "read", + /** + * Write + */ + WRITE = "write", + /** + * Make a node + */ + MKNOD = "mknod" +} +/** + * The supported options for a tmpfs mount for a container. + */ +export declare enum TmpfsMountOption { + DEFAULTS = "defaults", + RO = "ro", + RW = "rw", + SUID = "suid", + NOSUID = "nosuid", + DEV = "dev", + NODEV = "nodev", + EXEC = "exec", + NOEXEC = "noexec", + SYNC = "sync", + ASYNC = "async", + DIRSYNC = "dirsync", + REMOUNT = "remount", + MAND = "mand", + NOMAND = "nomand", + ATIME = "atime", + NOATIME = "noatime", + DIRATIME = "diratime", + NODIRATIME = "nodiratime", + BIND = "bind", + RBIND = "rbind", + UNBINDABLE = "unbindable", + RUNBINDABLE = "runbindable", + PRIVATE = "private", + RPRIVATE = "rprivate", + SHARED = "shared", + RSHARED = "rshared", + SLAVE = "slave", + RSLAVE = "rslave", + RELATIME = "relatime", + NORELATIME = "norelatime", + STRICTATIME = "strictatime", + NOSTRICTATIME = "nostrictatime", + MODE = "mode", + UID = "uid", + GID = "gid", + NR_INODES = "nr_inodes", + NR_BLOCKS = "nr_blocks", + MPOL = "mpol" +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js new file mode 100644 index 0000000000000..2a00173e4d6da --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js @@ -0,0 +1,175 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.TmpfsMountOption = exports.DevicePermission = exports.LinuxParameters = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const cdk = require("aws-cdk-lib/core"); +const constructs_1 = require("constructs"); +/** + * Linux-specific options that are applied to the container. + */ +class LinuxParameters extends constructs_1.Construct { + /** + * Constructs a new instance of the LinuxParameters class. + */ + constructor(scope, id, props = {}) { + super(scope, id); + /** + * Device mounts + */ + this.devices = new Array(); + /** + * TmpFs mounts + */ + this.tmpfs = new Array(); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_LinuxParametersProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, LinuxParameters); + } + throw error; + } + this.validateProps(props); + this.sharedMemorySize = props.sharedMemorySize; + this.initProcessEnabled = props.initProcessEnabled; + this.maxSwap = props.maxSwap; + this.swappiness = props.maxSwap ? props.swappiness : undefined; + } + validateProps(props) { + if (!cdk.Token.isUnresolved(props.swappiness) && + props.swappiness !== undefined && + (!Number.isInteger(props.swappiness) || props.swappiness < 0 || props.swappiness > 100)) { + throw new Error(`swappiness: Must be an integer between 0 and 100; received ${props.swappiness}.`); + } + } + /** + * Adds one or more host devices to a container. + */ + addDevices(...device) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Device(device); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addDevices); + } + throw error; + } + this.devices.push(...device); + } + /** + * Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container. + * + * Only works with EC2 launch type. + */ + addTmpfs(...tmpfs) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Tmpfs(tmpfs); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addTmpfs); + } + throw error; + } + this.tmpfs.push(...tmpfs); + } + /** + * Renders the Linux parameters to the Batch version of this resource, + * which does not have 'capabilities' and requires tmpfs.containerPath to be defined. + */ + renderLinuxParameters() { + return { + initProcessEnabled: this.initProcessEnabled, + sharedMemorySize: this.sharedMemorySize?.toMebibytes(), + maxSwap: this.maxSwap?.toMebibytes(), + swappiness: this.swappiness, + devices: cdk.Lazy.any({ produce: () => this.devices.map(renderDevice) }, { omitEmptyArray: true }), + tmpfs: cdk.Lazy.any({ produce: () => this.tmpfs.map(renderTmpfs) }, { omitEmptyArray: true }), + }; + } +} +exports.LinuxParameters = LinuxParameters; +_a = JSII_RTTI_SYMBOL_1; +LinuxParameters[_a] = { fqn: "@aws-cdk/aws-batch-alpha.LinuxParameters", version: "0.0.0" }; +/** + * Permissions for device access + */ +var DevicePermission; +(function (DevicePermission) { + /** + * Read + */ + DevicePermission["READ"] = "read"; + /** + * Write + */ + DevicePermission["WRITE"] = "write"; + /** + * Make a node + */ + DevicePermission["MKNOD"] = "mknod"; +})(DevicePermission || (exports.DevicePermission = DevicePermission = {})); +/** + * The supported options for a tmpfs mount for a container. + */ +var TmpfsMountOption; +(function (TmpfsMountOption) { + TmpfsMountOption["DEFAULTS"] = "defaults"; + TmpfsMountOption["RO"] = "ro"; + TmpfsMountOption["RW"] = "rw"; + TmpfsMountOption["SUID"] = "suid"; + TmpfsMountOption["NOSUID"] = "nosuid"; + TmpfsMountOption["DEV"] = "dev"; + TmpfsMountOption["NODEV"] = "nodev"; + TmpfsMountOption["EXEC"] = "exec"; + TmpfsMountOption["NOEXEC"] = "noexec"; + TmpfsMountOption["SYNC"] = "sync"; + TmpfsMountOption["ASYNC"] = "async"; + TmpfsMountOption["DIRSYNC"] = "dirsync"; + TmpfsMountOption["REMOUNT"] = "remount"; + TmpfsMountOption["MAND"] = "mand"; + TmpfsMountOption["NOMAND"] = "nomand"; + TmpfsMountOption["ATIME"] = "atime"; + TmpfsMountOption["NOATIME"] = "noatime"; + TmpfsMountOption["DIRATIME"] = "diratime"; + TmpfsMountOption["NODIRATIME"] = "nodiratime"; + TmpfsMountOption["BIND"] = "bind"; + TmpfsMountOption["RBIND"] = "rbind"; + TmpfsMountOption["UNBINDABLE"] = "unbindable"; + TmpfsMountOption["RUNBINDABLE"] = "runbindable"; + TmpfsMountOption["PRIVATE"] = "private"; + TmpfsMountOption["RPRIVATE"] = "rprivate"; + TmpfsMountOption["SHARED"] = "shared"; + TmpfsMountOption["RSHARED"] = "rshared"; + TmpfsMountOption["SLAVE"] = "slave"; + TmpfsMountOption["RSLAVE"] = "rslave"; + TmpfsMountOption["RELATIME"] = "relatime"; + TmpfsMountOption["NORELATIME"] = "norelatime"; + TmpfsMountOption["STRICTATIME"] = "strictatime"; + TmpfsMountOption["NOSTRICTATIME"] = "nostrictatime"; + TmpfsMountOption["MODE"] = "mode"; + TmpfsMountOption["UID"] = "uid"; + TmpfsMountOption["GID"] = "gid"; + TmpfsMountOption["NR_INODES"] = "nr_inodes"; + TmpfsMountOption["NR_BLOCKS"] = "nr_blocks"; + TmpfsMountOption["MPOL"] = "mpol"; +})(TmpfsMountOption || (exports.TmpfsMountOption = TmpfsMountOption = {})); +function renderTmpfs(tmpfs) { + return { + containerPath: tmpfs.containerPath, + size: tmpfs.size.toMebibytes(), + mountOptions: tmpfs.mountOptions, + }; +} +function renderDevice(device) { + return { + containerPath: device.containerPath, + hostPath: device.hostPath, + permissions: device.permissions, + }; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGludXgtcGFyYW1ldGVycy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImxpbnV4LXBhcmFtZXRlcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsd0NBQXdDO0FBQ3hDLDJDQUF1QztBQWdEdkM7O0dBRUc7QUFDSCxNQUFhLGVBQWdCLFNBQVEsc0JBQVM7SUErQjVDOztPQUVHO0lBQ0gsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxRQUE4QixFQUFFO1FBQ3hFLEtBQUssQ0FBQyxLQUFLLEVBQUUsRUFBRSxDQUFDLENBQUM7UUFkbkI7O1dBRUc7UUFDZ0IsWUFBTyxHQUFHLElBQUksS0FBSyxFQUFVLENBQUM7UUFFakQ7O1dBRUc7UUFDZ0IsVUFBSyxHQUFHLElBQUksS0FBSyxFQUFTLENBQUM7Ozs7OzsrQ0E3Qm5DLGVBQWU7Ozs7UUFxQ3hCLElBQUksQ0FBQyxhQUFhLENBQUMsS0FBSyxDQUFDLENBQUM7UUFFMUIsSUFBSSxDQUFDLGdCQUFnQixHQUFHLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQztRQUMvQyxJQUFJLENBQUMsa0JBQWtCLEdBQUcsS0FBSyxDQUFDLGtCQUFrQixDQUFDO1FBQ25ELElBQUksQ0FBQyxPQUFPLEdBQUcsS0FBSyxDQUFDLE9BQU8sQ0FBQztRQUM3QixJQUFJLENBQUMsVUFBVSxHQUFHLEtBQUssQ0FBQyxPQUFPLENBQUMsQ0FBQyxDQUFDLE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bm9yZWxhdGltZScsXG4gIFNUUklDVEFUSU1FID0gJ3N0cmljdGF0aW1lJyxcbiAgTk9TVFJJQ1RBVElNRSA9ICdub3N0cmljdGF0aW1lJyxcbiAgTU9ERSA9ICdtb2RlJyxcbiAgVUlEID0gJ3VpZCcsXG4gIEdJRCA9ICdnaWQnLFxuICBOUl9JTk9ERVMgPSAnbnJfaW5vZGVzJyxcbiAgTlJfQkxPQ0tTID0gJ25yX2Jsb2NrcycsXG4gIE1QT0wgPSAnbXBvbCdcbn1cblxuZnVuY3Rpb24gcmVuZGVyVG1wZnModG1wZnM6IFRtcGZzKTogQ2ZuSm9iRGVmaW5pdGlvbi5UbXBmc1Byb3BlcnR5IHtcbiAgcmV0dXJuIHtcbiAgICBjb250YWluZXJQYXRoOiB0bXBmcy5jb250YWluZXJQYXRoLFxuICAgIHNpemU6IHRtcGZzLnNpemUudG9NZWJpYnl0ZXMoKSxcbiAgICBtb3VudE9wdGlvbnM6IHRtcGZzLm1vdW50T3B0aW9ucyxcbiAgfTtcbn1cblxuZnVuY3Rpb24gcmVuZGVyRGV2aWNlKGRldmljZTogRGV2aWNlKTogQ2ZuSm9iRGVmaW5pdGlvbi5EZXZpY2VQcm9wZXJ0eSB7XG4gIHJldHVybiB7XG4gICAgY29udGFpbmVyUGF0aDogZGV2aWNlLmNvbnRhaW5lclBhdGgsXG4gICAgaG9zdFBhdGg6IGRldmljZS5ob3N0UGF0aCxcbiAgICBwZXJtaXNzaW9uczogZGV2aWNlLnBlcm1pc3Npb25zLFxuICB9O1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts new file mode 100644 index 0000000000000..6578bdcb3fd27 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts @@ -0,0 +1,806 @@ +import * as ec2 from 'aws-cdk-lib/aws-ec2'; +import * as eks from 'aws-cdk-lib/aws-eks'; +import * as iam from 'aws-cdk-lib/aws-iam'; +import { Duration, ITaggable, TagManager } from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +import { IComputeEnvironment, ComputeEnvironmentBase, ComputeEnvironmentProps } from './compute-environment-base'; +/** + * Represents a Managed ComputeEnvironment. Batch will provision EC2 Instances to + * meet the requirements of the jobs executing in this ComputeEnvironment. + */ +export interface IManagedComputeEnvironment extends IComputeEnvironment, ec2.IConnectable, ITaggable { + /** + * The maximum vCpus this `ManagedComputeEnvironment` can scale up to. + * + * *Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or + * `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances, + * The scheduler may exceed this number by at most one of the instances specified in `instanceTypes` + * or `instanceClasses`. + */ + readonly maxvCpus: number; + /** + * Specifies whether this Compute Environment is replaced if an update is made that requires + * replacing its instances. To enable more properties to be updated, + * set this property to `false`. When changing the value of this property to false, + * do not change any other properties at the same time. + * If other properties are changed at the same time, + * and the change needs to be rolled back but it can't, + * it's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state. + * You can't update a stack that is in the UPDATE_ROLLBACK_FAILED state. + * However, if you can continue to roll it back, + * you can return the stack to its original settings and then try to update it again. + * + * The properties which require a replacement of the Compute Environment are: + * + * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-replacecomputeenvironment + * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html + */ + readonly replaceComputeEnvironment?: boolean; + /** + * Whether or not to use spot instances. + * Spot instances are less expensive EC2 instances that can be + * reclaimed by EC2 at any time; your job will be given two minutes + * of notice before reclamation. + * + * @default false + */ + readonly spot?: boolean; + /** + * Only meaningful if `terminateOnUpdate` is `false`. If so, + * when an infrastructure update is triggered, any running jobs + * will be allowed to run until `updateTimeout` has expired. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html + * @default 30 minutes + */ + readonly updateTimeout?: Duration; + /** + * Whether or not any running jobs will be immediately terminated when an infrastructure update + * occurs. If this is enabled, any terminated jobs may be retried, depending on the job's + * retry policy. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html + * + * @default false + */ + readonly terminateOnUpdate?: boolean; + /** + * The security groups this Compute Environment will launch instances in. + */ + readonly securityGroups: ec2.ISecurityGroup[]; + /** + * The VPC Subnets this Compute Environment will launch instances in. + */ + readonly vpcSubnets?: ec2.SubnetSelection; + /** + * Whether or not the AMI is updated to the latest one supported by Batch + * when an infrastructure update occurs. + * + * If you specify a specific AMI, this property will be ignored. + * + * @default true + */ + readonly updateToLatestImageVersion?: boolean; +} +/** + * Props for a ManagedComputeEnvironment + */ +export interface ManagedComputeEnvironmentProps extends ComputeEnvironmentProps { + /** + * The maximum vCpus this `ManagedComputeEnvironment` can scale up to. + * Each vCPU is equivalent to 1024 CPU shares. + * + * *Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or + * `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances, + * The scheduler may exceed this number by at most one of the instances specified in `instanceTypes` + * or `instanceClasses`. + * + * @default 256 + */ + readonly maxvCpus?: number; + /** + * Specifies whether this Compute Environment is replaced if an update is made that requires + * replacing its instances. To enable more properties to be updated, + * set this property to `false`. When changing the value of this property to false, + * do not change any other properties at the same time. + * If other properties are changed at the same time, + * and the change needs to be rolled back but it can't, + * it's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state. + * You can't update a stack that is in the UPDATE_ROLLBACK_FAILED state. + * However, if you can continue to roll it back, + * you can return the stack to its original settings and then try to update it again. + * + * The properties which require a replacement of the Compute Environment are: + * + * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-replacecomputeenvironment + * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html + * + * @default false + */ + readonly replaceComputeEnvironment?: boolean; + /** + * Whether or not to use spot instances. + * Spot instances are less expensive EC2 instances that can be + * reclaimed by EC2 at any time; your job will be given two minutes + * of notice before reclamation. + * + * @default false + */ + readonly spot?: boolean; + /** + * Only meaningful if `terminateOnUpdate` is `false`. If so, + * when an infrastructure update is triggered, any running jobs + * will be allowed to run until `updateTimeout` has expired. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html + * + * @default 30 minutes + */ + readonly updateTimeout?: Duration; + /** + * Whether or not any running jobs will be immediately terminated when an infrastructure update + * occurs. If this is enabled, any terminated jobs may be retried, depending on the job's + * retry policy. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html + * + * @default false + */ + readonly terminateOnUpdate?: boolean; + /** + * VPC in which this Compute Environment will launch Instances + */ + readonly vpc: ec2.IVpc; + /** + * The security groups this Compute Environment will launch instances in. + * + * @default new security groups will be created + */ + readonly securityGroups?: ec2.ISecurityGroup[]; + /** + * The VPC Subnets this Compute Environment will launch instances in. + * + * @default new subnets will be created + */ + readonly vpcSubnets?: ec2.SubnetSelection; + /** + * Whether or not the AMI is updated to the latest one supported by Batch + * when an infrastructure update occurs. + * + * If you specify a specific AMI, this property will be ignored. + * + * @default true + */ + readonly updateToLatestImageVersion?: boolean; +} +/** + * Abstract base class for ManagedComputeEnvironments + * @internal + */ +export declare abstract class ManagedComputeEnvironmentBase extends ComputeEnvironmentBase implements IManagedComputeEnvironment { + readonly maxvCpus: number; + readonly replaceComputeEnvironment?: boolean; + readonly spot?: boolean; + readonly updateTimeout?: Duration; + readonly terminateOnUpdate?: boolean; + readonly securityGroups: ec2.ISecurityGroup[]; + readonly updateToLatestImageVersion?: boolean; + readonly tags: TagManager; + readonly connections: ec2.Connections; + constructor(scope: Construct, id: string, props: ManagedComputeEnvironmentProps); +} +/** + * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. + */ +export interface IManagedEc2EcsComputeEnvironment extends IManagedComputeEnvironment { + /** + * Configure which AMIs this Compute Environment can launch. + * + * Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches. + * + * @default + * - ECS_AL2 compatible AMI ids for non-GPU instances, ECS_AL2_NVIDIA compatible AMI ids for GPU instances + */ + readonly images?: EcsMachineImage[]; + /** + * The allocation strategy to use if not enough instances of + * the best fitting instance type can be allocated. + * + * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, + * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. + */ + readonly allocationStrategy?: AllocationStrategy; + /** + * The maximum percentage that a Spot Instance price can be when compared with the + * On-Demand price for that instance type before instances are launched. + * For example, if your maximum percentage is 20%, the Spot price must be + * less than 20% of the current On-Demand price for that Instance. + * You always pay the lowest market price and never more than your maximum percentage. + * For most use cases, Batch recommends leaving this field empty. + * + * @default - 100% + */ + readonly spotBidPercentage?: number; + /** + * The service-linked role that Spot Fleet needs to launch instances on your behalf. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html + * + * @default - a new Role will be created + */ + readonly spotFleetRole?: iam.IRole; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + */ + readonly instanceTypes: ec2.InstanceType[]; + /** + * The instance classes that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + * Batch will automatically choose the size. + */ + readonly instanceClasses: ec2.InstanceClass[]; + /** + * Whether or not to use batch's optimal instance type. + * The optimal instance type is equivalent to adding the + * C4, M4, and R4 instance classes. You can specify other instance classes + * (of the same architecture) in addition to the optimal instance classes. + * + * @default true + */ + readonly useOptimalInstanceClasses?: boolean; + /** + * The execution Role that instances launched by this Compute Environment will use. + * + * @default - a role will be created + */ + readonly instanceRole?: iam.IRole; + /** + * The Launch Template that this Compute Environment + * will use to provision EC2 Instances. + * + * *Note*: if `securityGroups` is specified on both your + * launch template and this Compute Environment, **the + * `securityGroup`s on the Compute Environment override the + * ones on the launch template. + * + * @default no launch template + */ + readonly launchTemplate?: ec2.ILaunchTemplate; + /** + * The minimum vCPUs that an environment should maintain, + * even if the compute environment is DISABLED. + * + * @default 0 + */ + readonly minvCpus?: number; + /** + * The EC2 placement group to associate with your compute resources. + * If you intend to submit multi-node parallel jobs to this Compute Environment, + * you should consider creating a cluster placement group and associate it with your compute resources. + * This keeps your multi-node parallel job on a logical grouping of instances + * within a single Availability Zone with high network flow potential. + * + * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html + * + * @default - no placement group + */ + readonly placementGroup?: ec2.IPlacementGroup; + /** + * Add an instance type to this compute environment + */ + addInstanceType(instanceType: ec2.InstanceType): void; + /** + * Add an instance class to this compute environment + */ + addInstanceClass(instanceClass: ec2.InstanceClass): void; +} +/** + * Base interface for containing all information needed to + * configure a MachineImage in Batch + */ +interface MachineImage { + /** + * The machine image to use + * + * @default - chosen by batch + */ + readonly image?: ec2.IMachineImage; +} +/** + * A Batch MachineImage that is compatible with ECS + */ +export interface EcsMachineImage extends MachineImage { + /** + * Tells Batch which instance type to launch this image on + * + * @default - 'ECS_AL2' for non-gpu instances, 'ECS_AL2_NVIDIA' for gpu instances + */ + readonly imageType?: EcsMachineImageType; +} +/** + * A Batch MachineImage that is compatible with EKS + */ +export interface EksMachineImage extends MachineImage { + /** + * Tells Batch which instance type to launch this image on + * + * @default - 'EKS_AL2' for non-gpu instances, 'EKS_AL2_NVIDIA' for gpu instances + */ + readonly imageType?: EksMachineImageType; +} +/** + * Maps the image to instance types + */ +export declare enum EcsMachineImageType { + /** + * Tells Batch that this machine image runs on non-GPU instances + */ + ECS_AL2 = "ECS_AL2", + /** + * Tells Batch that this machine image runs on GPU instances + */ + ECS_AL2_NVIDIA = "ECS_AL2_NVIDIA" +} +/** + * Maps the image to instance types + */ +export declare enum EksMachineImageType { + /** + * Tells Batch that this machine image runs on non-GPU instances + */ + EKS_AL2 = "EKS_AL2", + /** + * Tells Batch that this machine image runs on GPU instances + */ + EKS_AL2_NVIDIA = "EKS_AL2_NVIDIA" +} +/** + * Determines how this compute environment chooses instances to spawn + * + * @see https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/ + */ +export declare enum AllocationStrategy { + /** + * Batch chooses the lowest-cost instance type that fits all the jobs in the queue. + * If instances of that type are not available, the queue will not choose a new type; + * instead, it will wait for the instance to become available. + * This can stall your `Queue`, with your compute environment only using part of its max capacity + * (or none at all) until the `BEST_FIT` instance becomes available. + * This allocation strategy keeps costs lower but can limit scaling. + * `BEST_FIT` isn't supported when updating compute environments + */ + BEST_FIT = "BEST_FIT", + /** + * This is the default Allocation Strategy if `spot` is `false` or unspecified. + * This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements + * of the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`. + * However, if not all of the capacity can be filled with this instance type, + * it will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity. + * To make the most use of this allocation strategy, + * it is recommended to use as many instance classes as is feasible for your workload. + */ + BEST_FIT_PROGRESSIVE = "BEST_FIT_PROGRESSIVE", + /** + * If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` + * and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled). + * This will tell Batch to choose the instance types from the ones you’ve specified that have + * the most spot capacity available to minimize the chance of interruption. + * To get the most benefit from your spot instances, + * you should allow Batch to choose from as many different instance types as possible. + */ + SPOT_CAPACITY_OPTIMIZED = "SPOT_CAPACITY_OPTIMIZED", + /** + * The price and capacity optimized allocation strategy looks at both price and capacity + * to select the Spot Instance pools that are the least likely to be interrupted + * and have the lowest possible price. + * + * The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances. + */ + SPOT_PRICE_CAPACITY_OPTIMIZED = "SPOT_PRICE_CAPACITY_OPTIMIZED" +} +/** + * Props for a ManagedEc2EcsComputeEnvironment + */ +export interface ManagedEc2EcsComputeEnvironmentProps extends ManagedComputeEnvironmentProps { + /** + * Whether or not to use batch's optimal instance type. + * The optimal instance type is equivalent to adding the + * C4, M4, and R4 instance classes. You can specify other instance classes + * (of the same architecture) in addition to the optimal instance classes. + * + * @default true + */ + readonly useOptimalInstanceClasses?: boolean; + /** + * Configure which AMIs this Compute Environment can launch. + * If you specify this property with only `image` specified, then the + * `imageType` will default to `ECS_AL2`. *If your image needs GPU resources, + * specify `ECS_AL2_NVIDIA`; otherwise, the instances will not be able to properly + * join the ComputeEnvironment*. + * + * @default + * - ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances + */ + readonly images?: EcsMachineImage[]; + /** + * The allocation strategy to use if not enough instances of + * the best fitting instance type can be allocated. + * + * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, + * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. + */ + readonly allocationStrategy?: AllocationStrategy; + /** + * The maximum percentage that a Spot Instance price can be when compared with the + * On-Demand price for that instance type before instances are launched. + * For example, if your maximum percentage is 20%, the Spot price must be + * less than 20% of the current On-Demand price for that Instance. + * You always pay the lowest market price and never more than your maximum percentage. + * For most use cases, Batch recommends leaving this field empty. + * + * Implies `spot == true` if set + * + * @default 100% + */ + readonly spotBidPercentage?: number; + /** + * The service-linked role that Spot Fleet needs to launch instances on your behalf. + * + * @see https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html + * + * @default - a new role will be created + */ + readonly spotFleetRole?: iam.IRole; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + * + * @default - the instances Batch considers will be used (currently C4, M4, and R4) + */ + readonly instanceTypes?: ec2.InstanceType[]; + /** + * The instance classes that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + * Batch will automatically choose the instance size. + * + * @default - the instances Batch considers will be used (currently C4, M4, and R4) + */ + readonly instanceClasses?: ec2.InstanceClass[]; + /** + * The execution Role that instances launched by this Compute Environment will use. + * + * @default - a role will be created + */ + readonly instanceRole?: iam.IRole; + /** + * The Launch Template that this Compute Environment + * will use to provision EC2 Instances. + * + * *Note*: if `securityGroups` is specified on both your + * launch template and this Compute Environment, **the + * `securityGroup`s on the Compute Environment override the + * ones on the launch template. + * + * @default no launch template + */ + readonly launchTemplate?: ec2.ILaunchTemplate; + /** + * The minimum vCPUs that an environment should maintain, + * even if the compute environment is DISABLED. + * + * @default 0 + */ + readonly minvCpus?: number; + /** + * The EC2 placement group to associate with your compute resources. + * If you intend to submit multi-node parallel jobs to this Compute Environment, + * you should consider creating a cluster placement group and associate it with your compute resources. + * This keeps your multi-node parallel job on a logical grouping of instances + * within a single Availability Zone with high network flow potential. + * + * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html + * + * @default - no placement group + */ + readonly placementGroup?: ec2.IPlacementGroup; +} +/** + * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +export declare class ManagedEc2EcsComputeEnvironment extends ManagedComputeEnvironmentBase implements IManagedEc2EcsComputeEnvironment { + /** + * refer to an existing ComputeEnvironment by its arn. + */ + static fromManagedEc2EcsComputeEnvironmentArn(scope: Construct, id: string, managedEc2EcsComputeEnvironmentArn: string): IManagedEc2EcsComputeEnvironment; + readonly computeEnvironmentArn: string; + readonly computeEnvironmentName: string; + readonly images?: EcsMachineImage[]; + readonly allocationStrategy?: AllocationStrategy; + readonly spotBidPercentage?: number; + readonly spotFleetRole?: iam.IRole; + readonly instanceTypes: ec2.InstanceType[]; + readonly instanceClasses: ec2.InstanceClass[]; + readonly instanceRole?: iam.IRole; + readonly launchTemplate?: ec2.ILaunchTemplate; + readonly minvCpus?: number; + readonly placementGroup?: ec2.IPlacementGroup; + private readonly instanceProfile; + constructor(scope: Construct, id: string, props: ManagedEc2EcsComputeEnvironmentProps); + addInstanceType(instanceType: ec2.InstanceType): void; + addInstanceClass(instanceClass: ec2.InstanceClass): void; +} +/** + * A ManagedComputeEnvironment that uses EKS orchestration on EC2 instances. + */ +interface IManagedEc2EksComputeEnvironment extends IManagedComputeEnvironment { + /** + * The namespace of the Cluster + * + * Cannot be 'default', start with 'kube-', or be longer than 64 characters. + * + * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ + */ + readonly kubernetesNamespace?: string; + /** + * The cluster that backs this Compute Environment. Required + * for Compute Environments running Kubernetes jobs. + * + * Please ensure that you have followed the steps at + * + * https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html + * + * before attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster. + * If you do not follow the steps in the link, the deployment fail with a message that the + * compute environment did not stabilize. + */ + readonly eksCluster: eks.ICluster; + /** + * Configure which AMIs this Compute Environment can launch. + * + * @default + * EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances, + */ + readonly images?: EksMachineImage[]; + /** + * The allocation strategy to use if not enough instances of + * the best fitting instance type can be allocated. + * + * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, + * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. + */ + readonly allocationStrategy?: AllocationStrategy; + /** + * The maximum percentage that a Spot Instance price can be when compared with the + * On-Demand price for that instance type before instances are launched. + * For example, if your maximum percentage is 20%, the Spot price must be + * less than 20% of the current On-Demand price for that Instance. + * You always pay the lowest market price and never more than your maximum percentage. + * For most use cases, Batch recommends leaving this field empty. + * + * Implies `spot == true` if set + * + * @default - 100% + */ + readonly spotBidPercentage?: number; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + */ + readonly instanceTypes: ec2.InstanceType[]; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + */ + readonly instanceClasses: ec2.InstanceClass[]; + /** + * The execution Role that instances launched by this Compute Environment will use. + * + * @default - a role will be created + */ + readonly instanceRole?: iam.IRole; + /** + * The Launch Template that this Compute Environment + * will use to provision EC2 Instances. + * + * *Note*: if `securityGroups` is specified on both your + * launch template and this Compute Environment, **the + * `securityGroup`s on the Compute Environment override the + * ones on the launch template. + * + * @default - no launch template + */ + readonly launchTemplate?: ec2.ILaunchTemplate; + /** + * The minimum vCPUs that an environment should maintain, + * even if the compute environment is DISABLED. + * + * @default 0 + */ + readonly minvCpus?: number; + /** + * The EC2 placement group to associate with your compute resources. + * If you intend to submit multi-node parallel jobs to this Compute Environment, + * you should consider creating a cluster placement group and associate it with your compute resources. + * This keeps your multi-node parallel job on a logical grouping of instances + * within a single Availability Zone with high network flow potential. + * + * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html + * + * @default - no placement group + */ + readonly placementGroup?: ec2.IPlacementGroup; + /** + * Add an instance type to this compute environment + */ + addInstanceType(instanceType: ec2.InstanceType): void; + /** + * Add an instance class to this compute environment + */ + addInstanceClass(instanceClass: ec2.InstanceClass): void; +} +/** + * Props for a ManagedEc2EksComputeEnvironment + */ +export interface ManagedEc2EksComputeEnvironmentProps extends ManagedComputeEnvironmentProps { + /** + * The namespace of the Cluster + */ + readonly kubernetesNamespace: string; + /** + * The cluster that backs this Compute Environment. Required + * for Compute Environments running Kubernetes jobs. + * + * Please ensure that you have followed the steps at + * + * https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html + * + * before attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster. + * If you do not follow the steps in the link, the deployment fail with a message that the + * compute environment did not stabilize. + */ + readonly eksCluster: eks.ICluster; + /** + * Whether or not to use batch's optimal instance type. + * The optimal instance type is equivalent to adding the + * C4, M4, and R4 instance classes. You can specify other instance classes + * (of the same architecture) in addition to the optimal instance classes. + * + * @default true + */ + readonly useOptimalInstanceClasses?: boolean; + /** + * Configure which AMIs this Compute Environment can launch. + * + * @default + * If `imageKubernetesVersion` is specified, + * - EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances, + * Otherwise, + * - ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances, + */ + readonly images?: EksMachineImage[]; + /** + * The allocation strategy to use if not enough instances of + * the best fitting instance type can be allocated. + * + * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, + * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. + */ + readonly allocationStrategy?: AllocationStrategy; + /** + * The maximum percentage that a Spot Instance price can be when compared with the + * On-Demand price for that instance type before instances are launched. + * For example, if your maximum percentage is 20%, the Spot price must be + * less than 20% of the current On-Demand price for that Instance. + * You always pay the lowest market price and never more than your maximum percentage. + * For most use cases, Batch recommends leaving this field empty. + * + * Implies `spot == true` if set + * + * @default - 100% + */ + readonly spotBidPercentage?: number; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + * + * @default - the instances Batch considers will be used (currently C4, M4, and R4) + */ + readonly instanceTypes?: ec2.InstanceType[]; + /** + * The instance types that this Compute Environment can launch. + * Which one is chosen depends on the `AllocationStrategy` used. + * Batch will automatically choose the instance size. + * + * @default - the instances Batch considers will be used (currently C4, M4, and R4) + */ + readonly instanceClasses?: ec2.InstanceClass[]; + /** + * The execution Role that instances launched by this Compute Environment will use. + * + * @default - a role will be created + */ + readonly instanceRole?: iam.IRole; + /** + * The Launch Template that this Compute Environment + * will use to provision EC2 Instances. + * + * *Note*: if `securityGroups` is specified on both your + * launch template and this Compute Environment, **the + * `securityGroup`s on the Compute Environment override the + * ones on the launch template.** + * + * @default - no launch template + */ + readonly launchTemplate?: ec2.ILaunchTemplate; + /** + * The minimum vCPUs that an environment should maintain, + * even if the compute environment is DISABLED. + * + * @default 0 + */ + readonly minvCpus?: number; + /** + * The EC2 placement group to associate with your compute resources. + * If you intend to submit multi-node parallel jobs to this Compute Environment, + * you should consider creating a cluster placement group and associate it with your compute resources. + * This keeps your multi-node parallel job on a logical grouping of instances + * within a single Availability Zone with high network flow potential. + * + * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html + * + * @default - no placement group + */ + readonly placementGroup?: ec2.IPlacementGroup; +} +/** + * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +export declare class ManagedEc2EksComputeEnvironment extends ManagedComputeEnvironmentBase implements IManagedEc2EksComputeEnvironment { + readonly kubernetesNamespace?: string; + readonly eksCluster: eks.ICluster; + readonly computeEnvironmentName: string; + readonly computeEnvironmentArn: string; + readonly images?: EksMachineImage[]; + readonly allocationStrategy?: AllocationStrategy; + readonly spotBidPercentage?: number; + readonly instanceTypes: ec2.InstanceType[]; + readonly instanceClasses: ec2.InstanceClass[]; + readonly instanceRole?: iam.IRole; + readonly launchTemplate?: ec2.ILaunchTemplate; + readonly minvCpus?: number; + readonly placementGroup?: ec2.IPlacementGroup; + private readonly instanceProfile; + constructor(scope: Construct, id: string, props: ManagedEc2EksComputeEnvironmentProps); + addInstanceType(instanceType: ec2.InstanceType): void; + addInstanceClass(instanceClass: ec2.InstanceClass): void; +} +/** + * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. + */ +export interface IFargateComputeEnvironment extends IManagedComputeEnvironment { +} +/** + * Props for a FargateComputeEnvironment + */ +export interface FargateComputeEnvironmentProps extends ManagedComputeEnvironmentProps { +} +/** + * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +export declare class FargateComputeEnvironment extends ManagedComputeEnvironmentBase implements IFargateComputeEnvironment { + /** + * Reference an existing FargateComputeEnvironment by its arn + */ + static fromFargateComputeEnvironmentArn(scope: Construct, id: string, fargateComputeEnvironmentArn: string): IFargateComputeEnvironment; + readonly computeEnvironmentName: string; + readonly computeEnvironmentArn: string; + constructor(scope: Construct, id: string, props: FargateComputeEnvironmentProps); +} +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js new file mode 100644 index 0000000000000..378fcc005e21b --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js @@ -0,0 +1,451 @@ +"use strict"; +var _a, _b, _c; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.FargateComputeEnvironment = exports.ManagedEc2EksComputeEnvironment = exports.ManagedEc2EcsComputeEnvironment = exports.AllocationStrategy = exports.EksMachineImageType = exports.EcsMachineImageType = exports.ManagedComputeEnvironmentBase = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const iam = require("aws-cdk-lib/aws-iam"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +const compute_environment_base_1 = require("./compute-environment-base"); +/** + * Abstract base class for ManagedComputeEnvironments + * @internal + */ +class ManagedComputeEnvironmentBase extends compute_environment_base_1.ComputeEnvironmentBase { + constructor(scope, id, props) { + super(scope, id, props); + this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); + this.maxvCpus = props.maxvCpus ?? DEFAULT_MAX_VCPUS; + this.replaceComputeEnvironment = props.replaceComputeEnvironment ?? false; + this.spot = props.spot; + this.updateTimeout = props.updateTimeout; + this.terminateOnUpdate = props.terminateOnUpdate; + this.updateToLatestImageVersion = props.updateToLatestImageVersion ?? true; + this.securityGroups = props.securityGroups ?? [ + new ec2.SecurityGroup(this, 'SecurityGroup', { + vpc: props.vpc, + }), + ]; + this.connections = new ec2.Connections({ + securityGroups: this.securityGroups, + }); + } +} +exports.ManagedComputeEnvironmentBase = ManagedComputeEnvironmentBase; +/** + * Maps the image to instance types + */ +var EcsMachineImageType; +(function (EcsMachineImageType) { + /** + * Tells Batch that this machine image runs on non-GPU instances + */ + EcsMachineImageType["ECS_AL2"] = "ECS_AL2"; + /** + * Tells Batch that this machine image runs on GPU instances + */ + EcsMachineImageType["ECS_AL2_NVIDIA"] = "ECS_AL2_NVIDIA"; +})(EcsMachineImageType || (exports.EcsMachineImageType = EcsMachineImageType = {})); +/** + * Maps the image to instance types + */ +var EksMachineImageType; +(function (EksMachineImageType) { + /** + * Tells Batch that this machine image runs on non-GPU instances + */ + EksMachineImageType["EKS_AL2"] = "EKS_AL2"; + /** + * Tells Batch that this machine image runs on GPU instances + */ + EksMachineImageType["EKS_AL2_NVIDIA"] = "EKS_AL2_NVIDIA"; +})(EksMachineImageType || (exports.EksMachineImageType = EksMachineImageType = {})); +/** + * Determines how this compute environment chooses instances to spawn + * + * @see https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/ + */ +var AllocationStrategy; +(function (AllocationStrategy) { + /** + * Batch chooses the lowest-cost instance type that fits all the jobs in the queue. + * If instances of that type are not available, the queue will not choose a new type; + * instead, it will wait for the instance to become available. + * This can stall your `Queue`, with your compute environment only using part of its max capacity + * (or none at all) until the `BEST_FIT` instance becomes available. + * This allocation strategy keeps costs lower but can limit scaling. + * `BEST_FIT` isn't supported when updating compute environments + */ + AllocationStrategy["BEST_FIT"] = "BEST_FIT"; + /** + * This is the default Allocation Strategy if `spot` is `false` or unspecified. + * This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements + * of the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`. + * However, if not all of the capacity can be filled with this instance type, + * it will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity. + * To make the most use of this allocation strategy, + * it is recommended to use as many instance classes as is feasible for your workload. + */ + AllocationStrategy["BEST_FIT_PROGRESSIVE"] = "BEST_FIT_PROGRESSIVE"; + /** + * If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` + * and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled). + * This will tell Batch to choose the instance types from the ones you’ve specified that have + * the most spot capacity available to minimize the chance of interruption. + * To get the most benefit from your spot instances, + * you should allow Batch to choose from as many different instance types as possible. + */ + AllocationStrategy["SPOT_CAPACITY_OPTIMIZED"] = "SPOT_CAPACITY_OPTIMIZED"; + /** + * The price and capacity optimized allocation strategy looks at both price and capacity + * to select the Spot Instance pools that are the least likely to be interrupted + * and have the lowest possible price. + * + * The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances. + */ + AllocationStrategy["SPOT_PRICE_CAPACITY_OPTIMIZED"] = "SPOT_PRICE_CAPACITY_OPTIMIZED"; +})(AllocationStrategy || (exports.AllocationStrategy = AllocationStrategy = {})); +/** + * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +class ManagedEc2EcsComputeEnvironment extends ManagedComputeEnvironmentBase { + /** + * refer to an existing ComputeEnvironment by its arn. + */ + static fromManagedEc2EcsComputeEnvironmentArn(scope, id, managedEc2EcsComputeEnvironmentArn) { + const stack = core_1.Stack.of(scope); + const computeEnvironmentName = stack.splitArn(managedEc2EcsComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + class Import extends core_1.Resource { + constructor() { + super(...arguments); + this.computeEnvironmentArn = managedEc2EcsComputeEnvironmentArn; + this.computeEnvironmentName = computeEnvironmentName; + this.enabled = true; + this.instanceClasses = []; + this.instanceTypes = []; + this.maxvCpus = 1; + this.connections = {}; + this.securityGroups = []; + this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); + } + addInstanceClass(_instanceClass) { + throw new Error(`cannot add instance class to imported ComputeEnvironment '${id}'`); + } + addInstanceType(_instanceType) { + throw new Error(`cannot add instance type to imported ComputeEnvironment '${id}'`); + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, ManagedEc2EcsComputeEnvironment); + } + throw error; + } + this.images = props.images; + this.allocationStrategy = determineAllocationStrategy(id, props.allocationStrategy, this.spot); + this.spotBidPercentage = props.spotBidPercentage; + this.spotFleetRole = props.spotFleetRole ?? (this.spot && this.allocationStrategy === AllocationStrategy.BEST_FIT + ? createSpotFleetRole(this) + : undefined); + this.instanceTypes = props.instanceTypes ?? []; + this.instanceClasses = props.instanceClasses ?? []; + const { instanceRole, instanceProfile } = createInstanceRoleAndProfile(this, props.instanceRole); + this.instanceRole = instanceRole; + this.instanceProfile = instanceProfile; + this.launchTemplate = props.launchTemplate; + this.minvCpus = props.minvCpus ?? DEFAULT_MIN_VCPUS; + this.placementGroup = props.placementGroup; + validateVCpus(id, this.minvCpus, this.maxvCpus); + validateSpotConfig(id, this.spot, this.spotBidPercentage, this.spotFleetRole); + const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); + const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { + ...baseManagedResourceProperties(this, subnetIds), + computeEnvironmentName: props.computeEnvironmentName, + computeResources: { + ...baseManagedResourceProperties(this, subnetIds).computeResources, + minvCpus: this.minvCpus, + instanceRole: this.instanceProfile.attrArn, + instanceTypes: core_1.Lazy.list({ + produce: () => renderInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses), + }), + type: this.spot ? 'SPOT' : 'EC2', + spotIamFleetRole: this.spotFleetRole?.roleArn, + allocationStrategy: this.allocationStrategy, + bidPercentage: this.spotBidPercentage, + launchTemplate: this.launchTemplate ? { + launchTemplateId: this.launchTemplate?.launchTemplateId, + } : undefined, + ec2Configuration: this.images?.map((image) => { + return { + imageIdOverride: image.image?.getImage(this).imageId, + imageType: image.imageType ?? EcsMachineImageType.ECS_AL2, + }; + }), + placementGroup: this.placementGroup?.placementGroupName, + tags: this.tags.renderedTags, + }, + }); + this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); + this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { + service: 'batch', + resource: 'compute-environment', + resourceName: this.physicalName, + }); + this.node.addValidation({ validate: () => validateInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }); + } + addInstanceType(instanceType) { + this.instanceTypes.push(instanceType); + } + addInstanceClass(instanceClass) { + this.instanceClasses.push(instanceClass); + } +} +exports.ManagedEc2EcsComputeEnvironment = ManagedEc2EcsComputeEnvironment; +_a = JSII_RTTI_SYMBOL_1; +ManagedEc2EcsComputeEnvironment[_a] = { fqn: "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment", version: "0.0.0" }; +/** + * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +class ManagedEc2EksComputeEnvironment extends ManagedComputeEnvironmentBase { + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, ManagedEc2EksComputeEnvironment); + } + throw error; + } + this.kubernetesNamespace = props.kubernetesNamespace; + this.eksCluster = props.eksCluster; + this.images = props.images; + this.allocationStrategy = determineAllocationStrategy(id, props.allocationStrategy, this.spot); + if (this.allocationStrategy === AllocationStrategy.BEST_FIT) { + throw new Error(`ManagedEc2EksComputeEnvironment '${id}' uses invalid allocation strategy 'AllocationStrategy.BEST_FIT'`); + } + this.spotBidPercentage = props.spotBidPercentage; + this.instanceTypes = props.instanceTypes ?? []; + this.instanceClasses = props.instanceClasses ?? []; + const { instanceRole, instanceProfile } = createInstanceRoleAndProfile(this, props.instanceRole); + this.instanceRole = instanceRole; + this.instanceProfile = instanceProfile; + this.launchTemplate = props.launchTemplate; + this.minvCpus = props.minvCpus ?? DEFAULT_MIN_VCPUS; + this.placementGroup = props.placementGroup; + validateVCpus(id, this.minvCpus, this.maxvCpus); + validateSpotConfig(id, this.spot, this.spotBidPercentage); + const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); + const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { + ...baseManagedResourceProperties(this, subnetIds), + computeEnvironmentName: props.computeEnvironmentName, + eksConfiguration: { + eksClusterArn: this.eksCluster.clusterArn, + kubernetesNamespace: this.kubernetesNamespace, + }, + computeResources: { + ...baseManagedResourceProperties(this, subnetIds).computeResources, + minvCpus: this.minvCpus, + instanceRole: this.instanceProfile.attrArn, + instanceTypes: core_1.Lazy.list({ produce: () => renderInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }), + type: this.spot ? 'SPOT' : 'EC2', + allocationStrategy: this.allocationStrategy, + bidPercentage: this.spotBidPercentage, + launchTemplate: this.launchTemplate ? { + launchTemplateId: this.launchTemplate?.launchTemplateId, + } : undefined, + ec2Configuration: this.images?.map((image) => { + return { + imageIdOverride: image.image?.getImage(this).imageId, + imageType: image.imageType ?? EksMachineImageType.EKS_AL2, + }; + }), + placementGroup: this.placementGroup?.placementGroupName, + tags: this.tags.renderedTags, + }, + }); + this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); + this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { + service: 'batch', + resource: 'compute-environment', + resourceName: this.physicalName, + }); + this.node.addValidation({ validate: () => validateInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }); + } + addInstanceType(instanceType) { + this.instanceTypes.push(instanceType); + } + addInstanceClass(instanceClass) { + this.instanceClasses.push(instanceClass); + } +} +exports.ManagedEc2EksComputeEnvironment = ManagedEc2EksComputeEnvironment; +_b = JSII_RTTI_SYMBOL_1; +ManagedEc2EksComputeEnvironment[_b] = { fqn: "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment", version: "0.0.0" }; +/** + * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. + * + * @resource AWS::Batch::ComputeEnvironment + */ +class FargateComputeEnvironment extends ManagedComputeEnvironmentBase { + /** + * Reference an existing FargateComputeEnvironment by its arn + */ + static fromFargateComputeEnvironmentArn(scope, id, fargateComputeEnvironmentArn) { + const stack = core_1.Stack.of(scope); + const computeEnvironmentName = stack.splitArn(fargateComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + class Import extends core_1.Resource { + constructor() { + super(...arguments); + this.computeEnvironmentArn = fargateComputeEnvironmentArn; + this.computeEnvironmentName = computeEnvironmentName; + this.enabled = true; + this.maxvCpus = 1; + this.connections = {}; + this.securityGroups = []; + this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, FargateComputeEnvironment); + } + throw error; + } + const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); + const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { + ...baseManagedResourceProperties(this, subnetIds), + computeEnvironmentName: props.computeEnvironmentName, + computeResources: { + ...baseManagedResourceProperties(this, subnetIds).computeResources, + type: this.spot ? 'FARGATE_SPOT' : 'FARGATE', + }, + }); + this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); + this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { + service: 'batch', + resource: 'compute-environment', + resourceName: this.physicalName, + }); + } +} +exports.FargateComputeEnvironment = FargateComputeEnvironment; +_c = JSII_RTTI_SYMBOL_1; +FargateComputeEnvironment[_c] = { fqn: "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment", version: "0.0.0" }; +function renderInstances(types, classes, useOptimalInstanceClasses) { + const instances = []; + for (const instanceType of types ?? []) { + instances.push(instanceType.toString()); + } + for (const instanceClass of classes ?? []) { + instances.push(instanceClass); + } + if (useOptimalInstanceClasses || useOptimalInstanceClasses === undefined) { + instances.push('optimal'); + } + return instances; +} +function createInstanceRoleAndProfile(scope, instanceRole) { + const result = {}; + result.instanceRole = instanceRole ?? new iam.Role(scope, 'InstanceProfileRole', { + assumedBy: new iam.ServicePrincipal('ec2.amazonaws.com'), + managedPolicies: [iam.ManagedPolicy.fromAwsManagedPolicyName('service-role/AmazonEC2ContainerServiceforEC2Role')], + }); + result.instanceProfile = new iam.CfnInstanceProfile(scope, 'InstanceProfile', { + roles: [result.instanceRole.roleName], + }); + return result; +} +function createSpotFleetRole(scope) { + return new iam.Role(scope, 'SpotFleetRole', { + assumedBy: new iam.ServicePrincipal('spotfleet.amazonaws.com'), + }); +} +function determineAllocationStrategy(id, allocationStrategy, spot) { + let result = allocationStrategy; + if (!allocationStrategy) { + result = spot ? AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED : AllocationStrategy.BEST_FIT_PROGRESSIVE; + } + else if (allocationStrategy === AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED && !spot) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED' without using spot instances`); + } + else if (allocationStrategy === AllocationStrategy.SPOT_CAPACITY_OPTIMIZED && !spot) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'AllocationStrategy.SPOT_CAPACITY_OPTIMIZED' without using spot instances`); + } + return result; +} +function validateInstances(types, classes, useOptimalInstanceClasses) { + if (renderInstances(types, classes, useOptimalInstanceClasses).length === 0) { + return ["Specifies 'useOptimalInstanceClasses: false' without specifying any instance types or classes"]; + } + return []; +} +function validateSpotConfig(id, spot, spotBidPercentage, spotFleetRole) { + if (spotBidPercentage) { + if (!spot) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' without specifying 'spot'`); + } + else if (spotBidPercentage > 100) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' > 100`); + } + else if (spotBidPercentage < 0) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' < 0`); + } + } + if (spotFleetRole) { + if (!spot) { + throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotFleetRole' without specifying 'spot'`); + } + } +} +function validateVCpus(id, minvCpus, maxvCpus) { + if (minvCpus < 0) { + throw new Error(`Managed ComputeEnvironment '${id}' has 'minvCpus' = ${minvCpus} < 0; 'minvCpus' cannot be less than zero`); + } + if (minvCpus > maxvCpus) { + throw new Error(`Managed ComputeEnvironment '${id}' has 'minvCpus' = ${minvCpus} > 'maxvCpus' = ${maxvCpus}; 'minvCpus' cannot be greater than 'maxvCpus'`); + } +} +function baseManagedResourceProperties(baseComputeEnvironment, subnetIds) { + return { + serviceRole: baseComputeEnvironment.serviceRole?.roleArn, + state: baseComputeEnvironment.enabled ? 'ENABLED' : 'DISABLED', + computeResources: { + maxvCpus: baseComputeEnvironment.maxvCpus, + type: 'managed', + updateToLatestImageVersion: baseComputeEnvironment.updateToLatestImageVersion, + securityGroupIds: baseComputeEnvironment.securityGroups.map((securityGroup) => securityGroup.securityGroupId), + subnets: subnetIds, + }, + updatePolicy: { + terminateJobsOnUpdate: baseComputeEnvironment.terminateOnUpdate, + jobExecutionTimeoutMinutes: baseComputeEnvironment.updateTimeout?.toMinutes(), + }, + replaceComputeEnvironment: baseComputeEnvironment.replaceComputeEnvironment, + type: 'managed', + }; +} +const DEFAULT_MIN_VCPUS = 0; +const DEFAULT_MAX_VCPUS = 256; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsibWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUEyQztBQUUzQywyQ0FBMkM7QUFFM0MsMkNBQThHO0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RCcgOiAnRElTQUJMRUQnLFxuICAgIGNvbXB1dGVSZXNvdXJjZXM6IHtcbiAgICAgIG1heHZDcHVzOiBiYXNlQ29tcHV0ZUVudmlyb25tZW50Lm1heHZDcHVzLFxuICAgICAgdHlwZTogJ21hbmFnZWQnLFxuICAgICAgdXBkYXRlVG9MYXRlc3RJbWFnZVZlcnNpb246IGJhc2VDb21wdXRlRW52aXJvbm1lbnQudXBkYXRlVG9MYXRlc3RJbWFnZVZlcnNpb24sXG4gICAgICBzZWN1cml0eUdyb3VwSWRzOiBiYXNlQ29tcHV0ZUVudmlyb25tZW50LnNlY3VyaXR5R3JvdXBzLm1hcCgoc2VjdXJpdHlHcm91cCkgPT4gc2VjdXJpdHlHcm91cC5zZWN1cml0eUdyb3VwSWQpLFxuICAgICAgc3VibmV0czogc3VibmV0SWRzLFxuICAgIH0sXG4gICAgdXBkYXRlUG9saWN5OiB7XG4gICAgICB0ZXJtaW5hdGVKb2JzT25VcGRhdGU6IGJhc2VDb21wdXRlRW52aXJvbm1lbnQudGVybWluYXRlT25VcGRhdGUsXG4gICAgICBqb2JFeGVjdXRpb25UaW1lb3V0TWludXRlczogYmFzZUNvbXB1dGVFbnZpcm9ubWVudC51cGRhdGVUaW1lb3V0Py50b01pbnV0ZXMoKSxcbiAgICB9LFxuICAgIHJlcGxhY2VDb21wdXRlRW52aXJvbm1lbnQ6IGJhc2VDb21wdXRlRW52aXJvbm1lbnQucmVwbGFjZUNvbXB1dGVFbnZpcm9ubWVudCxcbiAgICB0eXBlOiAnbWFuYWdlZCcsXG4gIH07XG59XG5cbmNvbnN0IERFRkFVTFRfTUlOX1ZDUFVTID0gMDtcbmNvbnN0IERFRkFVTFRfTUFYX1ZDUFVTID0gMjU2O1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts new file mode 100644 index 0000000000000..460a7d679e9eb --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts @@ -0,0 +1,107 @@ +import * as ec2 from 'aws-cdk-lib/aws-ec2'; +import { Construct } from 'constructs'; +import { IEcsContainerDefinition } from './ecs-container-definition'; +import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; +interface IMultiNodeJobDefinition extends IJobDefinition { + /** + * The containers that this multinode job will run. + * + * @see https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/ + */ + readonly containers: MultiNodeContainer[]; + /** + * The instance type that this job definition will run + */ + readonly instanceType: ec2.InstanceType; + /** + * The index of the main node in this job. + * The main node is responsible for orchestration. + * + * @default 0 + */ + readonly mainNode?: number; + /** + * Whether to propogate tags from the JobDefinition + * to the ECS task that Batch spawns + * + * @default false + */ + readonly propagateTags?: boolean; + /** + * Add a container to this multinode job + */ + addContainer(container: MultiNodeContainer): void; +} +/** + * Runs the container on nodes [startNode, endNode] + */ +export interface MultiNodeContainer { + /** + * The index of the first node to run this container + * + * The container is run on all nodes in the range [startNode, endNode] (inclusive) + */ + readonly startNode: number; + /** + * The index of the last node to run this container. + * + * The container is run on all nodes in the range [startNode, endNode] (inclusive) + */ + readonly endNode: number; + /** + * The container that this node range will run + */ + readonly container: IEcsContainerDefinition; +} +/** + * Props to configure a MultiNodeJobDefinition + */ +export interface MultiNodeJobDefinitionProps extends JobDefinitionProps { + /** + * The instance type that this job definition + * will run. + */ + readonly instanceType: ec2.InstanceType; + /** + * The containers that this multinode job will run. + * + * @see https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/ + * + * @default none + */ + readonly containers?: MultiNodeContainer[]; + /** + * The index of the main node in this job. + * The main node is responsible for orchestration. + * + * @default 0 + */ + readonly mainNode?: number; + /** + * Whether to propogate tags from the JobDefinition + * to the ECS task that Batch spawns + * + * @default false + */ + readonly propagateTags?: boolean; +} +/** + * A JobDefinition that uses Ecs orchestration to run multiple containers + * + * @resource AWS::Batch::JobDefinition + */ +export declare class MultiNodeJobDefinition extends JobDefinitionBase implements IMultiNodeJobDefinition { + /** + * refer to an existing JobDefinition by its arn + */ + static fromJobDefinitionArn(scope: Construct, id: string, jobDefinitionArn: string): IJobDefinition; + readonly containers: MultiNodeContainer[]; + readonly instanceType: ec2.InstanceType; + readonly mainNode?: number; + readonly propagateTags?: boolean; + readonly jobDefinitionArn: string; + readonly jobDefinitionName: string; + constructor(scope: Construct, id: string, props: MultiNodeJobDefinitionProps); + addContainer(container: MultiNodeContainer): void; +} +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js new file mode 100644 index 0000000000000..dac94633d7c25 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js @@ -0,0 +1,104 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.MultiNodeJobDefinition = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +const ecs_job_definition_1 = require("./ecs-job-definition"); +const job_definition_base_1 = require("./job-definition-base"); +/** + * A JobDefinition that uses Ecs orchestration to run multiple containers + * + * @resource AWS::Batch::JobDefinition + */ +class MultiNodeJobDefinition extends job_definition_base_1.JobDefinitionBase { + /** + * refer to an existing JobDefinition by its arn + */ + static fromJobDefinitionArn(scope, id, jobDefinitionArn) { + const stack = core_1.Stack.of(scope); + const jobDefinitionName = stack.splitArn(jobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + class Import extends job_definition_base_1.JobDefinitionBase { + constructor() { + super(...arguments); + this.jobDefinitionArn = jobDefinitionArn; + this.jobDefinitionName = jobDefinitionName; + this.enabled = true; + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, MultiNodeJobDefinition); + } + throw error; + } + this.containers = props.containers ?? []; + this.mainNode = props.mainNode; + this.instanceType = props.instanceType; + this.propagateTags = props?.propagateTags; + const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { + ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), + type: 'multinode', + jobDefinitionName: props.jobDefinitionName, + propagateTags: this.propagateTags, + nodeProperties: { + mainNode: this.mainNode ?? 0, + nodeRangeProperties: core_1.Lazy.any({ + produce: () => this.containers.map((container) => ({ + targetNodes: container.startNode + ':' + container.endNode, + container: { + ...container.container._renderContainerDefinition(), + instanceType: this.instanceType.toString(), + }, + })), + }), + numNodes: core_1.Lazy.number({ + produce: () => computeNumNodes(this.containers), + }), + }, + platformCapabilities: [ecs_job_definition_1.Compatibility.EC2], + }); + this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { + service: 'batch', + resource: 'job-definition', + resourceName: this.physicalName, + }); + this.jobDefinitionName = this.getResourceNameAttribute(resource.ref); + this.node.addValidation({ validate: () => validateContainers(this.containers) }); + } + addContainer(container) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_MultiNodeContainer(container); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addContainer); + } + throw error; + } + this.containers.push(container); + } +} +exports.MultiNodeJobDefinition = MultiNodeJobDefinition; +_a = JSII_RTTI_SYMBOL_1; +MultiNodeJobDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition", version: "0.0.0" }; +function computeNumNodes(containers) { + let result = 0; + for (const container of containers) { + result += container.endNode - container.startNode + 1; + } + return result; +} +function validateContainers(containers) { + return containers.length === 0 ? ['multinode job has no containers!'] : []; +} +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUNBLDJDQUEwRDtBQUUxRCxxREFBeUQ7QUFFekQsNkRBQXFEO0FBQ3JELCtEQUEySDtBQWlHM0g7Ozs7R0FJRztBQUNILE1BQWEsc0JBQXVCLFNBQVEsdUNBQWlCO0lBQzNEOztPQUVHO0lBQ0ksTUFBTSxDQUFDLG9CQUFvQixDQUFDLEtBQWdCLEVBQUUsRUFBVSxFQUFFLGdCQUF3QjtRQUN2RixNQUFNLEtBQUssR0FBRyxZQUFLLENBQUMsRUFBRSxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQzlCLE1BQU0saUJBQWlCLEdBQUcsS0FBSyxDQUFDLFFBQVEsQ0FBQyxnQkFBZ0IsRUFBRSxnQkFBUyxDQUFDLG1CQUFtQixDQUFDLENBQUMsWUFBYSxDQUFDO1FBRXhHLE1BQU0sTUFBTyxTQUFRLHVDQUFpQjtZQUF0Qzs7Z0JBQ2tCLHFCQUFnQixHQUFHLGdCQUFnQixDQUFDO2dCQUNwQyxzQkFBaUIsR0FBRyxpQkFBaUIsQ0FBQztnQkFDdEMsWUFBTyxHQUFHLElBQUksQ0FBQztZQUNqQyxDQUFDO1NBQUE7UUFFRCxPQUFPLElBQUksTUFBTSxDQUFDLEtBQUssRUFBRSxFQUFFLENBQUMsQ0FBQztLQUM5QjtJQVVELFlBQVksS0FBZ0IsRUFBRSxFQUFVLEVBQUUsS0FBa0M7UUFDMUUsS0FBSyxDQUFDLEtBQUssRUFBRSxFQUFFLEVBQUUsS0FBSyxDQUFDLENBQUM7Ozs7OzsrQ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bnRhaW5lcnMucHVzaChjb250YWluZXIpO1xuICB9XG59XG5cbmZ1bmN0aW9uIGNvbXB1dGVOdW1Ob2Rlcyhjb250YWluZXJzOiBNdWx0aU5vZGVDb250YWluZXJbXSkge1xuICBsZXQgcmVzdWx0ID0gMDtcblxuICBmb3IgKGNvbnN0IGNvbnRhaW5lciBvZiBjb250YWluZXJzKSB7XG4gICAgcmVzdWx0ICs9IGNvbnRhaW5lci5lbmROb2RlIC0gY29udGFpbmVyLnN0YXJ0Tm9kZSArIDE7XG4gIH1cblxuICByZXR1cm4gcmVzdWx0O1xufVxuXG5mdW5jdGlvbiB2YWxpZGF0ZUNvbnRhaW5lcnMoY29udGFpbmVyczogTXVsdGlOb2RlQ29udGFpbmVyW10pOiBzdHJpbmdbXSB7XG4gIHJldHVybiBjb250YWluZXJzLmxlbmd0aCA9PT0gMCA/IFsnbXVsdGlub2RlIGpvYiBoYXMgbm8gY29udGFpbmVycyEnXSA6IFtdO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts new file mode 100644 index 0000000000000..1359eddcba414 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts @@ -0,0 +1,188 @@ +import { Duration, IResource, Resource } from 'aws-cdk-lib/core'; +import { Construct } from 'constructs'; +/** + * Represents a Scheduling Policy. Scheduling Policies tell the Batch + * Job Scheduler how to schedule incoming jobs. + */ +export interface ISchedulingPolicy extends IResource { + /** + * The name of this scheduling policy + * + * @attribute + */ + readonly schedulingPolicyName: string; + /** + * The arn of this scheduling policy + * + * @attribute + */ + readonly schedulingPolicyArn: string; +} +/** + * Props to configure a SchedulingPolicy + */ +interface SchedulingPolicyProps { + /** + * The name of this SchedulingPolicy + * + * @default - generated by CloudFormation + */ + readonly schedulingPolicyName?: string; +} +/** + * @internal + */ +export declare abstract class SchedulingPolicyBase extends Resource implements ISchedulingPolicy { + abstract readonly schedulingPolicyName: string; + abstract readonly schedulingPolicyArn: string; + constructor(scope: Construct, id: string, props?: SchedulingPolicyProps); +} +/** + * Represents a group of Job Definitions. All Job Definitions that + * declare a share identifier will be considered members of the Share + * defined by that share identifier. + * + * The Scheduler divides the maximum available vCPUs of the ComputeEnvironment + * among Jobs in the Queue based on their shareIdentifier and the weightFactor + * associated with that shareIdentifier. + */ +export interface Share { + /** + * The identifier of this Share. All jobs that specify this share identifier + * when submitted to the queue will be considered as part of this Share. + */ + readonly shareIdentifier: string; + /** + * The weight factor given to this Share. The Scheduler decides which jobs to put in the Compute Environment + * such that the following ratio is equal for each job: + * + * `sharevCpu / weightFactor`, + * + * where `sharevCpu` is the total amount of vCPU given to that particular share; that is, + * the sum of the vCPU of each job currently in the Compute Environment for that share. + * + * See the readme of this module for a detailed example that shows how these are used, + * how it relates to `computeReservation`, and how `shareDecay` affects these calculations. + */ + readonly weightFactor: number; +} +/** + * Represents a Fairshare Scheduling Policy. Instructs the scheduler + * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. + * + * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. + * It does this by deciding how many Jobs of each share to schedule *relative to how many jobs of + * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with + * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of + * fairshare policies. + */ +export interface IFairshareSchedulingPolicy extends ISchedulingPolicy { + /** + * Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue. + * + * The percentage reserved is defined by the Scheduler as: + * `(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers. + * + * For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the + * maximum available vCPU if there's only one fair share identifier. + * It reserves 25% if there are two fair share identifiers. + * It reserves 12.5% if there are three fair share identifiers. + * + * A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the + * maximum available vCPU if there's only one fair share identifier, + * 6.25% if there are two fair share identifiers, + * and 1.56% if there are three fair share identifiers. + * + * @default - no vCPU is reserved + */ + readonly computeReservation?: number; + /** + * The amount of time to use to measure the usage of each job. + * The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue. + * A value of zero (0) indicates that only current usage is measured. + * The decay is linear and gives preference to newer jobs. + * + * The maximum supported value is 604800 seconds (1 week). + * + * @default - 0: only the current job usage is considered + */ + readonly shareDecay?: Duration; + /** + * The shares that this Scheduling Policy applies to. + * *Note*: It is possible to submit Jobs to the queue with Share Identifiers that + * are not recognized by the Scheduling Policy. + */ + readonly shares: Share[]; +} +/** + * Fairshare SchedulingPolicy configuration + */ +export interface FairshareSchedulingPolicyProps extends SchedulingPolicyProps { + /** + * Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue. + * + * The percentage reserved is defined by the Scheduler as: + * `(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers. + * + * For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the + * maximum available vCPU if there's only one fair share identifier. + * It reserves 25% if there are two fair share identifiers. + * It reserves 12.5% if there are three fair share identifiers. + * + * A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the + * maximum available vCPU if there's only one fair share identifier, + * 6.25% if there are two fair share identifiers, + * and 1.56% if there are three fair share identifiers. + * + * @default - no vCPU is reserved + */ + readonly computeReservation?: number; + /** + * The amount of time to use to measure the usage of each job. + * The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue. + * A value of zero (0) indicates that only current usage is measured. + * The decay is linear and gives preference to newer jobs. + * + * The maximum supported value is 604800 seconds (1 week). + * + * @default - 0: only the current job usage is considered + */ + readonly shareDecay?: Duration; + /** + * The shares that this Scheduling Policy applies to. + * *Note*: It is possible to submit Jobs to the queue with Share Identifiers that + * are not recognized by the Scheduling Policy. + * + * @default - no shares + */ + readonly shares?: Share[]; +} +/** + * Represents a Fairshare Scheduling Policy. Instructs the scheduler + * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. + * + * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. + * The scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of + * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with + * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of + * fairshare policies. + * + * @resource AWS::Batch::SchedulingPolicy + */ +export declare class FairshareSchedulingPolicy extends SchedulingPolicyBase implements IFairshareSchedulingPolicy { + /** + * Reference an exisiting Scheduling Policy by its ARN + */ + static fromFairshareSchedulingPolicyArn(scope: Construct, id: string, fairshareSchedulingPolicyArn: string): IFairshareSchedulingPolicy; + readonly computeReservation?: number; + readonly shareDecay?: Duration; + readonly shares: Share[]; + readonly schedulingPolicyArn: string; + readonly schedulingPolicyName: string; + constructor(scope: Construct, id: string, props?: FairshareSchedulingPolicyProps); + /** + * Add a share this to this Fairshare SchedulingPolicy + */ + addShare(share: Share): void; +} +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js new file mode 100644 index 0000000000000..927263fa715f3 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js @@ -0,0 +1,101 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.FairshareSchedulingPolicy = exports.SchedulingPolicyBase = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +/** + * @internal + */ +class SchedulingPolicyBase extends core_1.Resource { + constructor(scope, id, props) { + super(scope, id, { + physicalName: props?.schedulingPolicyName, + }); + } +} +exports.SchedulingPolicyBase = SchedulingPolicyBase; +/** + * Represents a Fairshare Scheduling Policy. Instructs the scheduler + * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. + * + * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. + * The scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of + * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with + * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of + * fairshare policies. + * + * @resource AWS::Batch::SchedulingPolicy + */ +class FairshareSchedulingPolicy extends SchedulingPolicyBase { + /** + * Reference an exisiting Scheduling Policy by its ARN + */ + static fromFairshareSchedulingPolicyArn(scope, id, fairshareSchedulingPolicyArn) { + const stack = core_1.Stack.of(scope); + class Import extends SchedulingPolicyBase { + constructor() { + super(...arguments); + this.schedulingPolicyArn = fairshareSchedulingPolicyArn; + this.schedulingPolicyName = stack.splitArn(fairshareSchedulingPolicyArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + this.shares = []; + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, FairshareSchedulingPolicy); + } + throw error; + } + this.computeReservation = props?.computeReservation; + this.shareDecay = props?.shareDecay; + this.shares = props?.shares ?? []; + const resource = new aws_batch_1.CfnSchedulingPolicy(this, 'Resource', { + fairsharePolicy: { + computeReservation: this.computeReservation, + shareDecaySeconds: this.shareDecay?.toSeconds(), + shareDistribution: core_1.Lazy.any({ + produce: () => this.shares?.map((share) => ({ + shareIdentifier: share.shareIdentifier, + weightFactor: share.weightFactor, + })), + }), + }, + name: props?.schedulingPolicyName, + }); + this.schedulingPolicyArn = this.getResourceArnAttribute(resource.attrArn, { + service: 'batch', + resource: 'scheduling-policy', + resourceName: this.physicalName, + }); + this.schedulingPolicyName = this.getResourceNameAttribute(resource.ref); + } + /** + * Add a share this to this Fairshare SchedulingPolicy + */ + addShare(share) { + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Share(share); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, this.addShare); + } + throw error; + } + this.shares.push(share); + } +} +exports.FairshareSchedulingPolicy = FairshareSchedulingPolicy; +_a = JSII_RTTI_SYMBOL_1; +FairshareSchedulingPolicy[_a] = { fqn: "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy", version: "0.0.0" }; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NoZWR1bGluZy1wb2xpY3kuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJzY2hlZHVsaW5nLXBvbGljeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSwyQ0FBeUY7QUFFekYscURBQTREO0FBa0M1RDs7R0FFRztBQUNILE1BQXNCLG9CQUFxQixTQUFRLGVBQVE7SUFJekQsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxLQUE2QjtRQUNyRSxLQUFLLENBQUMsS0FBSyxFQUFFLEVBQUUsRUFBRTtZQUNmLFlBQVksRUFBRSxLQUFLLEVBQUUsb0JBQW9CO1NBQzFDLENBQUMsQ0FBQztLQUNKO0NBQ0Y7QUFURCxvREFTQztBQWtJRDs7Ozs7Ozs7Ozs7R0FXRztBQUNILE1BQWEseUJBQTBCLFNBQVEsb0JBQW9CO0lBQ2pFOztPQUVHO0lBQ0ksTUFBTSxDQUFDLGdDQUFnQyxDQUFDLEtBQWdCLEVBQUUsRUFBVSxFQUFFLDRCQUFvQztRQUMvRyxNQUFNLEtBQUssR0FBRyxZQUFLLENBQUMsRUFBRSxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQzlCLE1BQU0sTUFBTyxTQUFRLG9CQUFvQjtZQUF6Qzs7Z0JBQ2tCLHdCQUFtQixHQUFHLDRCQUE0QixDQUFDO2dCQUNuRCx5QkFBb0IsR0FBRyxLQUFLLENBQUMsUUFBUSxDQUFDLDRCQUE0QixFQUFF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lZHVsaW5nUG9saWN5TmFtZSxcbiAgICB9KTtcblxuICAgIHRoaXMuc2NoZWR1bGluZ1BvbGljeUFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UuYXR0ckFybiwge1xuICAgICAgc2VydmljZTogJ2JhdGNoJyxcbiAgICAgIHJlc291cmNlOiAnc2NoZWR1bGluZy1wb2xpY3knLFxuICAgICAgcmVzb3VyY2VOYW1lOiB0aGlzLnBoeXNpY2FsTmFtZSxcbiAgICB9KTtcbiAgICB0aGlzLnNjaGVkdWxpbmdQb2xpY3lOYW1lID0gdGhpcy5nZXRSZXNvdXJjZU5hbWVBdHRyaWJ1dGUocmVzb3VyY2UucmVmKTtcbiAgfVxuXG4gIC8qKlxuICAgKiBBZGQgYSBzaGFyZSB0aGlzIHRvIHRoaXMgRmFpcnNoYXJlIFNjaGVkdWxpbmdQb2xpY3lcbiAgICovXG4gIHB1YmxpYyBhZGRTaGFyZShzaGFyZTogU2hhcmUpIHtcbiAgICB0aGlzLnNoYXJlcy5wdXNoKHNoYXJlKTtcbiAgfVxufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts new file mode 100644 index 0000000000000..80c8be1714cae --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts @@ -0,0 +1,47 @@ +import { Construct } from 'constructs'; +import { IComputeEnvironment, ComputeEnvironmentBase, ComputeEnvironmentProps } from './compute-environment-base'; +/** + * Represents an UnmanagedComputeEnvironment. Batch will not provision instances on your behalf + * in this ComputeEvironment. + */ +export interface IUnmanagedComputeEnvironment extends IComputeEnvironment { + /** + * The vCPUs this Compute Environment provides. Used only by the + * scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s. + * + * **If this parameter is not provided on a fairshare queue, no capacity is reserved**; + * that is, the `FairshareSchedulingPolicy` is ignored. + */ + readonly unmanagedvCPUs?: number; +} +/** + * Represents an UnmanagedComputeEnvironment. Batch will not provision instances on your behalf + * in this ComputeEvironment. + */ +export interface UnmanagedComputeEnvironmentProps extends ComputeEnvironmentProps { + /** + * The vCPUs this Compute Environment provides. Used only by the + * scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s. + * + * **If this parameter is not provided on a fairshare queue, no capacity is reserved**; + * that is, the `FairshareSchedulingPolicy` is ignored. + * + * @default 0 + */ + readonly unmanagedvCpus?: number; +} +/** + * Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf. + * + * @resource AWS::Batch::ComputeEnvironment + */ +export declare class UnmanagedComputeEnvironment extends ComputeEnvironmentBase implements IUnmanagedComputeEnvironment { + /** + * Import an UnmanagedComputeEnvironment by its arn + */ + static fromUnmanagedComputeEnvironmentArn(scope: Construct, id: string, unmanagedComputeEnvironmentArn: string): IUnmanagedComputeEnvironment; + readonly unmanagedvCPUs?: number | undefined; + readonly computeEnvironmentArn: string; + readonly computeEnvironmentName: string; + constructor(scope: Construct, id: string, props?: UnmanagedComputeEnvironmentProps); +} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js new file mode 100644 index 0000000000000..3a7d3f74798bd --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js @@ -0,0 +1,70 @@ +"use strict"; +var _a; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.UnmanagedComputeEnvironment = void 0; +const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); +const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const core_1 = require("aws-cdk-lib/core"); +const aws_batch_1 = require("aws-cdk-lib/aws-batch"); +const compute_environment_base_1 = require("./compute-environment-base"); +/** + * Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf. + * + * @resource AWS::Batch::ComputeEnvironment + */ +class UnmanagedComputeEnvironment extends compute_environment_base_1.ComputeEnvironmentBase { + /** + * Import an UnmanagedComputeEnvironment by its arn + */ + static fromUnmanagedComputeEnvironmentArn(scope, id, unmanagedComputeEnvironmentArn) { + const stack = core_1.Stack.of(scope); + const computeEnvironmentName = stack.splitArn(unmanagedComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; + class Import extends compute_environment_base_1.ComputeEnvironmentBase { + constructor() { + super(...arguments); + this.computeEnvironmentArn = unmanagedComputeEnvironmentArn; + this.computeEnvironmentName = computeEnvironmentName; + this.enabled = true; + this.containerDefinition = {}; + } + } + return new Import(scope, id); + } + constructor(scope, id, props) { + super(scope, id, props); + try { + jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps(props); + } + catch (error) { + if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { + Error.captureStackTrace(error, UnmanagedComputeEnvironment); + } + throw error; + } + this.unmanagedvCPUs = props?.unmanagedvCpus; + const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { + type: 'unmanaged', + state: this.enabled ? 'ENABLED' : 'DISABLED', + computeEnvironmentName: props?.computeEnvironmentName, + unmanagedvCpus: this.unmanagedvCPUs, + serviceRole: props?.serviceRole?.roleArn + ?? new aws_iam_1.Role(this, 'BatchServiceRole', { + managedPolicies: [ + aws_iam_1.ManagedPolicy.fromAwsManagedPolicyName('service-role/AWSBatchServiceRole'), + ], + assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), + }).roleArn, + }); + this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); + this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { + service: 'batch', + resource: 'compute-environment', + resourceName: this.physicalName, + }); + } +} +exports.UnmanagedComputeEnvironment = UnmanagedComputeEnvironment; +_a = JSII_RTTI_SYMBOL_1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4gICAgICBzZXJ2aWNlUm9sZTogcHJvcHM/LnNlcnZpY2VSb2xlPy5yb2xlQXJuXG4gICAgICA/PyBuZXcgUm9sZSh0aGlzLCAnQmF0Y2hTZXJ2aWNlUm9sZScsIHtcbiAgICAgICAgbWFuYWdlZFBvbGljaWVzOiBbXG4gICAgICAgICAgTWFuYWdlZFBvbGljeS5mcm9tQXdzTWFuYWdlZFBvbGljeU5hbWUoJ3NlcnZpY2Utcm9sZS9BV1NCYXRjaFNlcnZpY2VSb2xlJyksXG4gICAgICAgIF0sXG4gICAgICAgIGFzc3VtZWRCeTogbmV3IFNlcnZpY2VQcmluY2lwYWwoJ2JhdGNoLmFtYXpvbmF3cy5jb20nKSxcbiAgICAgIH0pLnJvbGVBcm4sXG4gICAgfSk7XG4gICAgdGhpcy5jb21wdXRlRW52aXJvbm1lbnROYW1lID0gdGhpcy5nZXRSZXNvdXJjZU5hbWVBdHRyaWJ1dGUocmVzb3VyY2UucmVmKTtcbiAgICB0aGlzLmNvbXB1dGVFbnZpcm9ubWVudEFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UuYXR0ckNvbXB1dGVFbnZpcm9ubWVudEFybiwge1xuICAgICAgc2VydmljZTogJ2JhdGNoJyxcbiAgICAgIHJlc291cmNlOiAnY29tcHV0ZS1lbnZpcm9ubWVudCcsXG4gICAgICByZXNvdXJjZU5hbWU6IHRoaXMucGh5c2ljYWxOYW1lLFxuICAgIH0pO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js new file mode 100644 index 0000000000000..26f4d2b7fface --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js @@ -0,0 +1,294 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const batch = require("../../lib"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const assertions_1 = require("aws-cdk-lib/assertions"); +const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); +const events = require("aws-cdk-lib/aws-events"); +const targets = require("aws-cdk-lib/aws-events-targets"); +const sqs = require("aws-cdk-lib/aws-sqs"); +describe('Batch job event target', () => { + let stack; + let jobQueue; + let jobDefinition; + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + jobQueue = new batch.JobQueue(stack, 'MyQueue', { + computeEnvironments: [ + { + computeEnvironment: new batch.UnmanagedComputeEnvironment(stack, 'ComputeEnvironment'), + order: 1, + }, + ], + }); + jobDefinition = new batch.EcsJobDefinition(stack, 'MyJob', { + container: new batch.EcsEc2ContainerDefinition(stack, 'container', { + image: aws_ecs_1.ContainerImage.fromRegistry('test-repo'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + }); + test('use aws batch job as an event rule target', () => { + // GIVEN + const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 min)'), + }); + // WHEN + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition)); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { + ScheduleExpression: 'rate(1 min)', + State: 'ENABLED', + Targets: [ + { + Arn: { + 'Fn::GetAtt': [ + 'MyQueueE6CA6235', + 'JobQueueArn', + ], + }, + Id: 'Target0', + RoleArn: { + 'Fn::GetAtt': [ + 'MyJobEventsRoleCF43C336', + 'Arn', + ], + }, + BatchParameters: { + JobDefinition: { + Ref: 'MyJob8719E923', + }, + JobName: 'Rule', + }, + }, + ], + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [ + { + Action: 'batch:SubmitJob', + Effect: 'Allow', + Resource: [ + { Ref: 'MyJob8719E923' }, + { + 'Fn::GetAtt': [ + 'MyQueueE6CA6235', + 'JobQueueArn', + ], + }, + ], + }, + ], + Version: '2012-10-17', + }, + Roles: [ + { Ref: 'MyJobEventsRoleCF43C336' }, + ], + }); + }); + test('use a Dead Letter Queue for the rule target', () => { + // GIVEN + const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 hour)'), + }); + const queue = new sqs.Queue(stack, 'Queue'); + // WHEN + const eventInput = { + buildspecOverride: 'buildspecs/hourly.yml', + }; + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { + deadLetterQueue: queue, + event: events.RuleTargetInput.fromObject(eventInput), + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { + Targets: [ + { + Arn: { + 'Fn::GetAtt': [ + 'MyQueueE6CA6235', + 'JobQueueArn', + ], + }, + Id: 'Target0', + DeadLetterConfig: { + Arn: { + 'Fn::GetAtt': [ + 'Queue4A7E3555', + 'Arn', + ], + }, + }, + Input: JSON.stringify(eventInput), + RoleArn: { + 'Fn::GetAtt': ['MyJobEventsRoleCF43C336', 'Arn'], + }, + BatchParameters: { + JobDefinition: { + Ref: 'MyJob8719E923', + }, + JobName: 'Rule', + }, + }, + ], + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::SQS::QueuePolicy', { + PolicyDocument: { + Statement: [ + { + Action: 'sqs:SendMessage', + Condition: { + ArnEquals: { + 'aws:SourceArn': { + 'Fn::GetAtt': [ + 'Rule4C995B7F', + 'Arn', + ], + }, + }, + }, + Effect: 'Allow', + Principal: { + Service: 'events.amazonaws.com', + }, + Resource: { + 'Fn::GetAtt': [ + 'Queue4A7E3555', + 'Arn', + ], + }, + Sid: 'AllowEventRuleRule', + }, + ], + Version: '2012-10-17', + }, + Queues: [ + { + Ref: 'Queue4A7E3555', + }, + ], + }); + }); + test('specifying retry policy', () => { + // GIVEN + const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 hour)'), + }); + const queue = new sqs.Queue(stack, 'Queue'); + // WHEN + const eventInput = { + buildspecOverride: 'buildspecs/hourly.yml', + }; + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { + deadLetterQueue: queue, + event: events.RuleTargetInput.fromObject(eventInput), + retryAttempts: 2, + maxEventAge: aws_cdk_lib_1.Duration.hours(2), + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { + ScheduleExpression: 'rate(1 hour)', + State: 'ENABLED', + Targets: [ + { + Arn: { + 'Fn::GetAtt': [ + 'MyQueueE6CA6235', + 'JobQueueArn', + ], + }, + BatchParameters: { + JobDefinition: { + Ref: 'MyJob8719E923', + }, + JobName: 'Rule', + }, + DeadLetterConfig: { + Arn: { + 'Fn::GetAtt': [ + 'Queue4A7E3555', + 'Arn', + ], + }, + }, + Id: 'Target0', + Input: JSON.stringify(eventInput), + RetryPolicy: { + MaximumEventAgeInSeconds: 7200, + MaximumRetryAttempts: 2, + }, + RoleArn: { + 'Fn::GetAtt': [ + 'MyJobEventsRoleCF43C336', + 'Arn', + ], + }, + }, + ], + }); + }); + test('specifying retry policy with 0 retryAttempts', () => { + // GIVEN + const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 hour)'), + }); + // WHEN + const eventInput = { + buildspecOverride: 'buildspecs/hourly.yml', + }; + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { + event: events.RuleTargetInput.fromObject(eventInput), + retryAttempts: 0, + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { + ScheduleExpression: 'rate(1 hour)', + State: 'ENABLED', + Targets: [ + { + Arn: { + 'Fn::GetAtt': [ + 'MyQueueE6CA6235', + 'JobQueueArn', + ], + }, + BatchParameters: { + JobDefinition: { + Ref: 'MyJob8719E923', + }, + JobName: 'Rule', + }, + Id: 'Target0', + Input: JSON.stringify(eventInput), + RetryPolicy: { + MaximumRetryAttempts: 0, + }, + RoleArn: { + 'Fn::GetAtt': [ + 'MyJobEventsRoleCF43C336', + 'Arn', + ], + }, + }, + ], + }); + }); + test('should validate jobName minimum and maximum length', () => { + const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 min)'), + }); + expect(() => { + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { + jobName: '', + })); + }).toThrowError(/must have length between 1 and 128/); + expect(() => { + rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { + jobName: 'a'.repeat(200), + })); + }).toThrowError(/must have length between 1 and 128/); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmF0Y2gudGVzdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImJhdGNoLnRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxtQ0FBbUM7QUFDbkMsNkNBQW9EO0FBQ3BELHVEQUFrRDtBQUNsRCxpREFBcUQ7QUFDckQsaURBQWlEO0FBQ2pELDBEQUEwRDtBQUMxRCwyQ0FBMkM7QUFFM0MsUUFBUSxDQUFDLHdCQUF3QixFQUFFLEdBQUcsRUFBRTtJQUN0QyxJQUFJLEtBQVksQ0FBQztJQUNqQixJQUFJLFFBQXlCLENBQUM7SUFDOUIsSUFBSSxhQUFtQyxDQUFDO0lBRXhDLFVBQVUsQ0FBQyxHQUFHLEVBQUU7UUFDZ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WV1ZUU2Q0E2MjM1JyxcbiAgICAgICAgICAgICAgJ0pvYlF1ZXVlQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJZDogJ1RhcmdldDAnLFxuICAgICAgICAgIFJvbGVBcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlKb2JFdmVudHNSb2xlQ0Y0M0MzMzYnLFxuICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBCYXRjaFBhcmFtZXRlcnM6IHtcbiAgICAgICAgICAgIEpvYkRlZmluaXRpb246IHtcbiAgICAgICAgICAgICAgUmVmOiAnTXlKb2I4NzE5RTkyMycsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgSm9iTmFtZTogJ1J1bGUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICBdLFxuICAgIH0pO1xuXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6SUFNOjpQb2xpY3knLCB7XG4gICAgICBQb2xpY3lEb2N1bWVudDoge1xuICAgICAgICBTdGF0ZW1lbnQ6IFtcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdiYXRjaDpTdWJtaXRKb2InLFxuICAgICAgICAgICAgRWZmZWN0OiAnQWxsb3cnLFxuICAgICAgICAgICAgUmVzb3VyY2U6IFtcbiAgICAgICAgICAgICAgeyBSZWY6ICdNeUpvYjg3MTlFOTIzJyB9LFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICAgICAnTXlRdWV1ZUU2Q0E2MjM1JyxcbiAgICAgICAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICA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b21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkV2ZW50czo6UnVsZScsIHtcbiAgICAgIFRhcmdldHM6IFtcbiAgICAgICAge1xuICAgICAgICAgIEFybjoge1xuICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICdNeVF1ZXVlRTZDQTYyMzUnLFxuICAgICAgICAgICAgICAnSm9iUXVldWVBcm4nLFxuICAgICAgICAgICAgXSxcbiAgICAgICAgICB9LFxuICAgICAgICAgIElkOiAnVGFyZ2V0MCcsXG4gICAgICAgICAgRGVhZExldHRlckNvbmZpZzoge1xuICAgICAgICAgICAgQXJuOiB7XG4gICAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAgICdRdWV1ZTRBN0UzNTU1JyxcbiAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJbnB1dDogSlNPTi5zdHJpbmdpZnkoZXZlbnRJbnB1dCksXG4gICAgICAgICAgUm9sZUFybjoge1xuICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbJ015Sm9iRXZlbnRzUm9sZUNGNDNDMzM2JywgJ0FybiddLFxuICAgICAgICAgIH0sXG4gICAgICAgICAgQmF0Y2hQYXJhbWV0ZXJzOiB7XG4gICAgICAgICAgICBKb2JEZWZpbml0aW9uOiB7XG4gICAgICAgICAgICAgIFJlZjogJ015Sm9iODcxOUU5MjMnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIEpvYk5hbWU6ICdSdWxlJyxcbiAgICAgICAgICB9LFxuICAgICAgICB9LFxuICAgICAgXSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OlNRUzo6UXVldWVQb2xpY3knLCB7XG4gICAgICBQb2xpY3lEb2N1bWVudDoge1xuICAgICAgICBTdGF0ZW1lbnQ6IFtcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdzcXM6U2VuZE1lc3NhZ2UnLFxuICAgICAgICAgICAgQ29uZGl0aW9uOiB7XG4gICAgICAgICAgICAgIEFybkVxdWFsczoge1xuICAgICAgICAgICAgICAgICdhd3M6U291cmNlQXJuJzoge1xuICAgICAgICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICAgICAgICdSdWxlNEM5OTVCN0YnLFxuICAgICAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBQcmluY2lwYWw6IHtcbiAgICAgICAgICAgICAgU2VydmljZTogJ2V2ZW50cy5hbWF6b25hd3MuY29tJyxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICAgICAnUXVldWU0QTdFMzU1NScsXG4gICAgICAgICAgICAgICAgJ0FybicsXG4gICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgU2lkOiAnQWxsb3dFdmVudFJ1bGVSdWxlJyxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgICB9LFxuICAgICAgUXVldWVzOiBbXG4gICAgICAgIHtcbiAgICAgICAgICBSZWY6ICdRdWV1ZTRBN0UzNTU1JyxcbiAgICAgICAgfSxcbiAgICAgIF0sXG4gICAgfSk7XG4gIH0pO1xuXG4gIHRlc3QoJ3NwZWNpZnlpbmcgcmV0cnkgcG9saWN5JywgKCkgP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Bcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlRdWV1ZUU2Q0E2MjM1JyxcbiAgICAgICAgICAgICAgJ0pvYlF1ZXVlQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBCYXRjaFBhcmFtZXRlcnM6IHtcbiAgICAgICAgICAgIEpvYkRlZmluaXRpb246IHtcbiAgICAgICAgICAgICAgUmVmOiAnTXlKb2I4NzE5RTkyMycsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgSm9iTmFtZTogJ1J1bGUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAgRGVhZExldHRlckNvbmZpZzoge1xuICAgICAgICAgICAgQXJuOiB7XG4gICAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAgICdRdWV1ZTRBN0UzNTU1JyxcbiAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJZDogJ1RhcmdldDAnLFxuICAgICAgICAgIElucHV0OiBKU09OLnN0cmluZ2lmeShldmVudElucHV0KSxcbiAgICAgICAgICBSZXRyeVBvbGljeToge1xuICAgICAgICAgICAgTWF4aW11bUV2ZW50QWdlSW5TZWNvbmRzOiA3MjAwLFxuICAgICAgICAgICAgTWF4aW11bVJldHJ5QXR0ZW1wdHM6IDIsXG4gICAgICAgICAgfSxcbiAgICAgICAgICBSb2xlQXJuOiB7XG4gICAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICAgJ015Sm9iRXZlbnRzUm9sZUNGNDNDMzM2JyxcbiAgICAgICAgICAgICAgJ0FybicsXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICBdLFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdzcGVjaWZ5aW5nIH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ZSxcbiAgICAgICAgICBqb2JEZWZpbml0aW9uLmpvYkRlZmluaXRpb25Bcm4sXG4gICAgICAgICAgam9iRGVmaW5pdGlvbixcbiAgICAgICAgICB7XG4gICAgICAgICAgICBqb2JOYW1lOiAnJyxcbiAgICAgICAgICB9LFxuICAgICAgICApLFxuICAgICAgKTtcbiAgICB9KS50b1Rocm93RXJyb3IoL211c3QgaGF2ZSBsZW5ndGggYmV0d2VlbiAxIGFuZCAxMjgvKTtcbiAgICBleHBlY3QoKCkgPT4ge1xuICAgICAgcnVsZS5hZGRUYXJnZXQoXG4gICAgICAgIG5ldyB0YXJnZXRzLkJhdGNoSm9iKFxuICAgICAgICAgIGpvYlF1ZXVlLmpvYlF1ZXVlQXJuLFxuICAgICAgICAgIGpvYlF1ZXVlLFxuICAgICAgICAgIGpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgICAgICAgICBqb2JEZWZpbml0aW9uLFxuICAgICAgICAgIHtcbiAgICAgICAgICAgIGpvYk5hbWU6ICdhJy5yZXBlYXQoMjAwKSxcbiAgICAgICAgICB9LFxuICAgICAgICApLFxuICAgICAgKTtcbiAgICB9KS50b1Rocm93RXJyb3IoL211c3QgaGF2ZSBsZW5ndGggYmV0d2VlbiAxIGFuZCAxMjgvKTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js new file mode 100644 index 0000000000000..0ed0f7a77b1ed --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js @@ -0,0 +1,286 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const path = require("path"); +const batch = require("../../lib"); +const cdk_build_tools_1 = require("@aws-cdk/cdk-build-tools"); +const cdk = require("aws-cdk-lib"); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const sfn = require("aws-cdk-lib/aws-stepfunctions"); +const tasks = require("aws-cdk-lib/aws-stepfunctions-tasks"); +let stack; +let batchJobDefinition; +let batchJobQueue; +beforeEach(() => { + // GIVEN + stack = new cdk.Stack(); + batchJobDefinition = new batch.EcsJobDefinition(stack, 'JobDefinition', { + container: new batch.EcsEc2ContainerDefinition(stack, 'Container', { + image: ecs.ContainerImage.fromAsset(path.join(__dirname, '../batchjob-image')), + cpu: 256, + memory: cdk.Size.mebibytes(2048), + }), + }); + batchJobQueue = new batch.JobQueue(stack, 'JobQueue', { + computeEnvironments: [ + { + order: 1, + computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(stack, 'ComputeEnv', { + vpc: new ec2.Vpc(stack, 'vpc'), + }), + }, + ], + }); +}); +(0, cdk_build_tools_1.describeDeprecated)('RunBatchJob', () => { + test('Task with only the required parameters', () => { + // WHEN + const task = new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + }), + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, + JobName: 'JobName', + JobQueue: { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + }, + }); + }); + test('Task with all the parameters', () => { + // WHEN + const task = new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 15, + containerOverrides: { + command: ['sudo', 'rm'], + environment: { key: 'value' }, + instanceType: new ec2.InstanceType('MULTI'), + memory: 1024, + gpuCount: 1, + vcpus: 10, + }, + dependsOn: [{ jobId: '1234', type: 'some_type' }], + payload: { + foo: sfn.JsonPath.stringAt('$.bar'), + }, + attempts: 3, + timeout: cdk.Duration.seconds(60), + integrationPattern: sfn.ServiceIntegrationPattern.FIRE_AND_FORGET, + }), + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob', + ], + ], + }, + End: true, + Parameters: { + JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, + JobName: 'JobName', + JobQueue: { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + ArrayProperties: { Size: 15 }, + ContainerOverrides: { + Command: ['sudo', 'rm'], + Environment: [{ Name: 'key', Value: 'value' }], + InstanceType: 'MULTI', + Memory: 1024, + ResourceRequirements: [{ Type: 'GPU', Value: '1' }], + Vcpus: 10, + }, + DependsOn: [{ JobId: '1234', Type: 'some_type' }], + Parameters: { 'foo.$': '$.bar' }, + RetryStrategy: { Attempts: 3 }, + Timeout: { AttemptDurationSeconds: 60 }, + }, + }); + }); + test('supports tokens', () => { + // WHEN + const task = new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobQueueArn: batchJobQueue.jobQueueArn, + jobName: sfn.JsonPath.stringAt('$.jobName'), + arraySize: sfn.JsonPath.numberAt('$.arraySize'), + timeout: cdk.Duration.seconds(sfn.JsonPath.numberAt('$.timeout')), + attempts: sfn.JsonPath.numberAt('$.attempts'), + }), + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, + 'JobName.$': '$.jobName', + 'JobQueue': { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + 'ArrayProperties': { + 'Size.$': '$.arraySize', + }, + 'RetryStrategy': { + 'Attempts.$': '$.attempts', + }, + 'Timeout': { + 'AttemptDurationSeconds.$': '$.timeout', + }, + }, + }); + }); + test('Task throws if WAIT_FOR_TASK_TOKEN is supplied as service integration pattern', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + integrationPattern: sfn.ServiceIntegrationPattern.WAIT_FOR_TASK_TOKEN, + }), + }); + }).toThrow(/Invalid Service Integration Pattern: WAIT_FOR_TASK_TOKEN is not supported to call RunBatchJob./i); + }); + test('Task throws if environment in containerOverrides contain env with name starting with AWS_BATCH', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + containerOverrides: { + environment: { AWS_BATCH_MY_NAME: 'MY_VALUE' }, + }, + }), + }); + }).toThrow(/Invalid environment variable name: AWS_BATCH_MY_NAME. Environment variable names starting with 'AWS_BATCH' are reserved./i); + }); + test('Task throws if arraySize is out of limits 2-10000', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 1, + }), + }); + }).toThrow(/arraySize must be between 2 and 10,000/); + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 10001, + }), + }); + }).toThrow(/arraySize must be between 2 and 10,000/); + }); + test('Task throws if dependencies exceeds 20', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + dependsOn: [...Array(21).keys()].map(i => ({ + jobId: `${i}`, + type: `some_type-${i}`, + })), + }), + }); + }).toThrow(/dependencies must be 20 or less/); + }); + test('Task throws if attempts is out of limits 1-10', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + attempts: 0, + }), + }); + }).toThrow(/attempts must be between 1 and 10/); + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + attempts: 11, + }), + }); + }).toThrow(/attempts must be between 1 and 10/); + }); + test('Task throws if timeout is less than 60 sec', () => { + expect(() => { + new sfn.Task(stack, 'Task', { + task: new tasks.RunBatchJob({ + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + timeout: cdk.Duration.seconds(59), + }), + }); + }).toThrow(/timeout must be greater than 60 seconds/); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicnVuLWJhdGNoLWpvYi50ZXN0LmpzIiw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MjRGRkUzRUQnIH0sXG4gICAgICAgIEpvYk5hbWU6ICdKb2JOYW1lJyxcbiAgICAgICAgSm9iUXVldWU6IHtcbiAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICdKb2JRdWV1ZUVFM0FENDk5JyxcbiAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgXSxcbiAgICAgICAgfSxcbiAgICAgICAgQXJyYXlQcm9wZXJ0aWVzOiB7IFNpemU6IDE1IH0sXG4gICAgICAgIENvbnRhaW5lck92ZXJyaWRlczoge1xuICAgICAgICAgIENvbW1hbmQ6IFsnc3VkbycsICdybSddLFxuICAgICAgICAgIEVudmlyb25tZW50OiBbeyBOYW1lOiAna2V5JywgVmFsdWU6ICd2YWx1ZScgfV0sXG4gICAgICAgICAgSW5zdGFuY2VUeXBlOiAnTVVMVEknLFxuICAgICAgICAgIE1lbW9yeTogMTAyNCxcbiAgICAgICAgICBSZXNvdXJjZVJlcXVpcmVtZW50czogW3sgVHlwZTogJ0dQVScsIFZhbHVlOiAnMScgfV0sXG4gICAgICAgICAgVmNwdXM6IDEwLFxuICAgICAgICB9LFxuICAgICAgICBEZXBlbmRzT246IFt7IEpvYklkOiAnMTIzNCcsIFR5cGU6ICdzb21lX3R5cGUnIH1dLFxuICAgICAgICBQYXJhbWV0ZXJzOiB7ICdmb28uJCc6ICckLmJhcicgfSxcbiAgICAgICAgUmV0cnlTdHJhdGVneTogeyBBdHRlbXB0czogMyB9LFxuICAgICAgICBUaW1lb3V0OiB7IEF0dGVtcHREdXJhdGlvblNlY29uZHM6IDYwIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdzdXBwb3J0cyB0b2tlbnMnLCAoKSA9PiB7XG4gIC8vIFdIRU5cbiAgICBjb25zdCB0YXNrID0gbmV3IHNmbi5UYXNrKHN0YWNrLCAnVGFzaycsIHtcbiAgICAgIHRhc2s6IG5ldyB0YXNrcy5SdW5CYXR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uJCc6ICckLmpvYk5hbWUnLFxuICAgICAgICAnSm9iUXVldWUnOiB7XG4gICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAnSm9iUXVldWVFRTNBRDQ5OScsXG4gICAgICAgICAgICAnSm9iUXVldWVBcm4nLFxuICAgICAgICAgIF0sXG4gICAgICAgIH0sXG4gICAgICAgICdBcnJheVByb3BlcnRpZXMnOiB7XG4gICAgICAgICAgJ1NpemUuJCc6ICckLmFycmF5U2l6ZScsXG4gICAgICAgIH0sXG4gICAgICAgICdSZXRyeVN0cmF0ZWd5Jzoge1xuICAgICAgICAgICdBdHRlbXB0cy4kJzogJyQuYXR0ZW1wdHMnLFxuICAgICAgICB9LFxuICAgICAgICAnVGltZW91dCc6IHtcbiAgICAgICAgICAnQXR0ZW1wdER1cmF0aW9uU2Vjb25kcy4kJzogJyQudGltZW91dCcsXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdUYXNrIHRocm93cyBpZiBXQUlUX0ZPUl9UQVNLX1RPS0VOIGlzIHN1cHBsaWVkIGFzIHNlcnZpY2UgaW50ZWdyYXRpb24gcGF0dGVybicsICgpID0+IHtcbiAgICBleHBlY3QoKCkgPT4ge1xuICAgICAgbmV3IHNmbi5UYXNrKHN0YWNrLCAnVGFzaycsIHtcbiAgICAgICAgdGFzazogbmV3IHRhc2tzLlJ1bkJhdGNoSm9iKHtcbiAgICAgICAgICBqb2JEZWZpbml0aW9uQXJuOiBiYXRjaEpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgICAgICAgICBqb2JOYW1lOiAnSm9iTmFtZScsXG4gICAgICAgICAgam9iUXVldWVBcm46IGJhdGNoSm9iUXVldWUuam9iUXVldWVBcm4sXG4gICAgICAgICAgaW50ZWdyYXRpb25QYXR0ZXJuOiBzZm4uU2VydmljZUludGVncmF0aW9uUGF0dGVybi5XQUlUX0ZPUl9UQVNLX1RPS0VO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KSxcbiAgICAgICAgfSksXG4gICAgICB9KTtcbiAgICB9KS50b1Rocm93KFxuICAgICAgL3RpbWVvdXQgbXVzdCBiZSBncmVhdGVyIHRoYW4gNjAgc2Vjb25kcy8sXG4gICAgKTtcbiAgfSk7XG59KTsiXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js new file mode 100644 index 0000000000000..8387351204073 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js @@ -0,0 +1,401 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const path = require("path"); +const batch = require("../../lib"); +const cdk = require("aws-cdk-lib"); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const sfn = require("aws-cdk-lib/aws-stepfunctions"); +const aws_stepfunctions_tasks_1 = require("aws-cdk-lib/aws-stepfunctions-tasks"); +let stack; +let batchJobDefinition; +let batchJobQueue; +beforeEach(() => { + // GIVEN + stack = new cdk.Stack(); + batchJobDefinition = new batch.EcsJobDefinition(stack, 'JobDefinition', { + container: new batch.EcsEc2ContainerDefinition(stack, 'Container', { + image: ecs.ContainerImage.fromAsset(path.join(__dirname, '../batchjob-image')), + cpu: 256, + memory: cdk.Size.mebibytes(2048), + }), + }); + batchJobQueue = new batch.JobQueue(stack, 'JobQueue', { + computeEnvironments: [ + { + order: 1, + computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(stack, 'ComputeEnv', { + vpc: new ec2.Vpc(stack, 'vpc'), + }), + }, + ], + }); +}); +test('Task with only the required parameters', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, + JobName: 'JobName', + JobQueue: { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + }, + }); +}); +test('Task with all the parameters', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 15, + containerOverrides: { + command: ['sudo', 'rm'], + environment: { key: 'value' }, + instanceType: new ec2.InstanceType('MULTI'), + memory: cdk.Size.mebibytes(1024), + gpuCount: 1, + vcpus: 10, + }, + dependsOn: [{ jobId: '1234', type: 'some_type' }], + payload: sfn.TaskInput.fromObject({ + foo: sfn.JsonPath.stringAt('$.bar'), + }), + attempts: 3, + taskTimeout: sfn.Timeout.duration(cdk.Duration.seconds(60)), + integrationPattern: sfn.IntegrationPattern.REQUEST_RESPONSE, + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob', + ], + ], + }, + End: true, + Parameters: { + JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, + JobName: 'JobName', + JobQueue: { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + ArrayProperties: { Size: 15 }, + ContainerOverrides: { + Command: ['sudo', 'rm'], + Environment: [{ Name: 'key', Value: 'value' }], + InstanceType: 'MULTI', + ResourceRequirements: [{ Type: 'GPU', Value: '1' }, { Type: 'MEMORY', Value: '1024' }, { Type: 'VCPU', Value: '10' }], + }, + DependsOn: [{ JobId: '1234', Type: 'some_type' }], + Parameters: { 'foo.$': '$.bar' }, + RetryStrategy: { Attempts: 3 }, + Timeout: { AttemptDurationSeconds: 60 }, + }, + }); +}); +test('supports tokens', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobName: sfn.JsonPath.stringAt('$.jobName'), + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: sfn.JsonPath.numberAt('$.arraySize'), + taskTimeout: sfn.Timeout.at('$.timeout'), + attempts: sfn.JsonPath.numberAt('$.attempts'), + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, + 'JobName.$': '$.jobName', + 'JobQueue': { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + 'ArrayProperties': { + 'Size.$': '$.arraySize', + }, + 'RetryStrategy': { + 'Attempts.$': '$.attempts', + }, + 'Timeout': { + 'AttemptDurationSeconds.$': '$.timeout', + }, + }, + }); +}); +test('container overrides are tokens', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + containerOverrides: { + memory: cdk.Size.mebibytes(sfn.JsonPath.numberAt('$.asdf')), + }, + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { 'Fn::Join': ['', ['arn:', { Ref: 'AWS::Partition' }, ':states:::batch:submitJob.sync']] }, + End: true, + Parameters: { + JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, + JobName: 'JobName', + JobQueue: { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + ContainerOverrides: { + ResourceRequirements: [{ 'Type': 'MEMORY', 'Value.$': '$.asdf' }], + }, + }, + }); +}); +test('supports passing task input into payload', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobQueueArn: batchJobQueue.jobQueueArn, + jobName: sfn.JsonPath.stringAt('$.jobName'), + payload: sfn.TaskInput.fromJsonPathAt('$.foo'), + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, + 'JobName.$': '$.jobName', + 'JobQueue': { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + 'Parameters.$': '$.foo', + }, + }); +}); +test('Task throws if WAIT_FOR_TASK_TOKEN is supplied as service integration pattern', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + integrationPattern: sfn.IntegrationPattern.WAIT_FOR_TASK_TOKEN, + }); + }).toThrow(/Unsupported service integration pattern. Supported Patterns: REQUEST_RESPONSE,RUN_JOB. Received: WAIT_FOR_TASK_TOKEN/); +}); +test('Task throws if environment in containerOverrides contain env with name starting with AWS_BATCH', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + containerOverrides: { + environment: { AWS_BATCH_MY_NAME: 'MY_VALUE' }, + }, + }); + }).toThrow(/Invalid environment variable name: AWS_BATCH_MY_NAME. Environment variable names starting with 'AWS_BATCH' are reserved./); +}); +test('Task throws if arraySize is out of limits 2-10000', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 1, + }); + }).toThrow(/arraySize must be between 2 and 10,000/); + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + arraySize: 10001, + }); + }).toThrow(/arraySize must be between 2 and 10,000/); +}); +test('Task throws if dependencies exceeds 20', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + dependsOn: [...Array(21).keys()].map(i => ({ + jobId: `${i}`, + type: `some_type-${i}`, + })), + }); + }).toThrow(/dependencies must be 20 or less/); +}); +test('Task throws if attempts is out of limits 1-10', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + attempts: 0, + }); + }).toThrow(/attempts must be between 1 and 10/); + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + attempts: 11, + }); + }).toThrow(/attempts must be between 1 and 10/); +}); +test('Task throws if attempt duration is less than 60 sec', () => { + expect(() => { + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + taskTimeout: sfn.Timeout.duration(cdk.Duration.seconds(59)), + }); + }).toThrow(/attempt duration must be greater than 60 seconds./); +}); +test('supports passing tags', () => { + // WHEN + const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobQueueArn: batchJobQueue.jobQueueArn, + jobName: sfn.JsonPath.stringAt('$.jobName'), + tags: { + test: 'this is a tag', + }, + }); + // THEN + expect(stack.resolve(task.toStateJson())).toEqual({ + Type: 'Task', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':states:::batch:submitJob.sync', + ], + ], + }, + End: true, + Parameters: { + 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, + 'JobName.$': '$.jobName', + 'JobQueue': { + 'Fn::GetAtt': [ + 'JobQueueEE3AD499', + 'JobQueueArn', + ], + }, + 'Tags': { + test: 'this is a tag', + }, + }, + }); +}); +test('throws if tags has invalid value', () => { + expect(() => { + const tags = {}; + for (let i = 0; i < 100; i++) { + tags[i] = 'tag'; + } + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task1', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + tags, + }); + }).toThrow(/Maximum tag number of entries is 50./); + expect(() => { + const keyTooLong = 'k'.repeat(150); + const tags = {}; + tags[keyTooLong] = 'tag'; + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + tags, + }); + }).toThrow(/Tag key size must be between 1 and 128/); + expect(() => { + const tags = { key: 'k'.repeat(300) }; + new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task3', { + jobDefinitionArn: batchJobDefinition.jobDefinitionArn, + jobName: 'JobName', + jobQueueArn: batchJobQueue.jobQueueArn, + tags, + }); + }).toThrow(/Tag value maximum size is 256/); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3VibWl0LWpvYi50ZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsic3VibWl0LWpvYi50ZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsNkJBQTZCO0FBQzdCLG1DQUFtQztBQUNuQyxtQ0FBbUM7QUFDbkMsMkNBQTJDO0FBQzNDLDJDQUEyQztBQUMzQyxxREFBcUQ7QUFDckQsaUZBQXFFO0FBRXJFLElBQUksS0FBZ0IsQ0FBQztBQUNyQixJQUFJLGtCQUF3QyxDQUFDO0FBQzdDLElBQUksYUFBOEIsQ0FBQztBQUVuQyxVQUFVLENBQUMsR0FBRyxFQUFFO0lBQ2QsUUFBUTtJQUNSLEtBQUssR0FBRyxJQUFJLEdBQUcsQ0FBQyxLQUFLLEVBQUUsQ0FBQztJQUV4QixrQkFBa0IsR0FBRyxJQUFJLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQyxLQUFLLEVBQUUsZUFBZSxFQUFFO1FBQ3RFLFNBQVMsRUFBRSxJQUFJLEtBQUssQ0FBQyx5QkFBeUIsQ0FBQyxLQUFLLEVBQUUsV0FBVyxFQUFFO1lBQ2pFLEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFNBQVMsQ0FDakMsSUFBSSxDQUFDLElBQUksQ0FBQyxTQUFTLEVBQUUsbUJBQW1CLENBQUMsQ0FDMUM7WUFDRCxHQUFHLEVBQUUsR0FBRztZQUN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3M6IHsgW2tleTogc3RyaW5nXTogc3RyaW5nIH0gPSB7fTtcbiAgICB0YWdzW2tleVRvb0xvbmddID0gJ3RhZyc7XG4gICAgbmV3IEJhdGNoU3VibWl0Sm9iKHN0YWNrLCAnVGFzazInLCB7XG4gICAgICBqb2JEZWZpbml0aW9uQXJuOiBiYXRjaEpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgICAgIGpvYk5hbWU6ICdKb2JOYW1lJyxcbiAgICAgIGpvYlF1ZXVlQXJuOiBiYXRjaEpvYlF1ZXVlLmpvYlF1ZXVlQXJuLFxuICAgICAgdGFncyxcbiAgICB9KTtcbiAgfSkudG9UaHJvdyhcbiAgICAvVGFnIGtleSBzaXplIG11c3QgYmUgYmV0d2VlbiAxIGFuZCAxMjgvLFxuICApO1xuXG4gIGV4cGVjdCgoKSA9PiB7XG4gICAgY29uc3QgdGFncyA9IHsga2V5OiAnaycucmVwZWF0KDMwMCkgfTtcbiAgICBuZXcgQmF0Y2hTdWJtaXRKb2Ioc3RhY2ssICdUYXNrMycsIHtcbiAgICAgIGpvYkRlZmluaXRpb25Bcm46IGJhdGNoSm9iRGVmaW5pdGlvbi5qb2JEZWZpbml0aW9uQXJuLFxuICAgICAgam9iTmFtZTogJ0pvYk5hbWUnLFxuICAgICAgam9iUXVldWVBcm46IGJhdGNoSm9iUXVldWUuam9iUXVldWVBcm4sXG4gICAgICB0YWdzLFxuICAgIH0pO1xuICB9KS50b1Rocm93KFxuICAgIC9UYWcgdmFsdWUgbWF4aW11bSBzaXplIGlzIDI1Ni8sXG4gICk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js new file mode 100644 index 0000000000000..d49b37fb9a85a --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js @@ -0,0 +1,998 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const path = require("path"); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const ecr = require("aws-cdk-lib/aws-ecr"); +const efs = require("aws-cdk-lib/aws-efs"); +const ssm = require("aws-cdk-lib/aws-ssm"); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const logs = require("aws-cdk-lib/aws-logs"); +const secretsmanager = require("aws-cdk-lib/aws-secretsmanager"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const cdk = require("aws-cdk-lib"); +const lib_1 = require("../lib"); +const utils_1 = require("./utils"); +const aws_ecr_assets_1 = require("aws-cdk-lib/aws-ecr-assets"); +// GIVEN +const defaultContainerProps = { + cpu: 256, + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + memory: aws_cdk_lib_1.Size.mebibytes(2048), +}; +const defaultExpectedProps = { + type: 'container', + containerProperties: { + image: 'amazon/amazon-ecs-sample', + resourceRequirements: [ + { + type: 'MEMORY', + value: '2048', + }, + { + type: 'VCPU', + value: '256', + }, + ], + }, +}; +let stack; +let pascalCaseExpectedProps; +describe.each([lib_1.EcsEc2ContainerDefinition, lib_1.EcsFargateContainerDefinition])('%p', (ContainerDefinition) => { + // GIVEN + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { + ...defaultExpectedProps, + containerProperties: { + ...defaultExpectedProps.containerProperties, + executionRoleArn: { + 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], + }, + }, + }); + }); + test('ecs container defaults', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ExecutionRoleArn: { + 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], + }, + ...pascalCaseExpectedProps.ContainerProperties, + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + AssumeRolePolicyDocument: { + Statement: [ + { + Action: 'sts:AssumeRole', + Effect: 'Allow', + Principal: { Service: 'ecs-tasks.amazonaws.com' }, + }, + ], + Version: '2012-10-17', + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [ + { + Action: [ + 'logs:CreateLogStream', + 'logs:PutLogEvents', + ], + Effect: 'Allow', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { Ref: 'AWS::Partition' }, + ':logs:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':log-group:/aws/batch/job:*', + ], + ], + }, + }, + ], + Version: '2012-10-17', + }, + PolicyName: 'EcsContainerExecutionRoleDefaultPolicy6F59CD37', + Roles: [{ + Ref: 'EcsContainerExecutionRole3B199293', + }], + }); + }); + test('respects command', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + command: ['echo', 'foo'], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Command: ['echo', 'foo'], + }, + }); + }); + test('respects environment', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + privileged: true, + environment: { + foo: 'bar', + }, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Environment: [{ + Name: 'foo', + Value: 'bar', + }], + }, + }); + }); + test('respects executionRole', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + privileged: true, + executionRole: new aws_iam_1.Role(stack, 'execRole', { + assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:user/user-name'), + }), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ExecutionRoleArn: { + 'Fn::GetAtt': ['execRole623CB63A', 'Arn'], + }, + }, + }); + }); + test('respects jobRole', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + privileged: true, + jobRole: new aws_iam_1.Role(stack, 'jobRole', { + assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:user/user-name'), + }), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + JobRoleArn: { + 'Fn::GetAtt': ['jobRoleA2173686', 'Arn'], + }, + }, + }); + }); + test('respects linuxParameters', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + privileged: true, + linuxParameters: new lib_1.LinuxParameters(stack, 'linuxParameters', { + initProcessEnabled: true, + maxSwap: aws_cdk_lib_1.Size.kibibytes(4096), + sharedMemorySize: aws_cdk_lib_1.Size.mebibytes(256), + swappiness: 30, + }), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + LinuxParameters: { + InitProcessEnabled: true, + MaxSwap: 4, + SharedMemorySize: 256, + Swappiness: 30, + }, + }, + }); + }); + test('respects logging', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + logging: ecs.LogDriver.awsLogs({ + datetimeFormat: 'format', + logRetention: logs.RetentionDays.ONE_MONTH, + multilinePattern: 'pattern', + streamPrefix: 'hello', + }), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ExecutionRoleArn: { + 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], + }, + ...pascalCaseExpectedProps.ContainerProperties, + LogConfiguration: { + Options: { + 'awslogs-datetime-format': 'format', + 'awslogs-group': { Ref: 'EcsContainerLogGroup6C5D5962' }, + 'awslogs-multiline-pattern': 'pattern', + 'awslogs-region': { Ref: 'AWS::Region' }, + 'awslogs-stream-prefix': 'hello', + }, + }, + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + AssumeRolePolicyDocument: { + Statement: [ + { + Action: 'sts:AssumeRole', + Effect: 'Allow', + Principal: { Service: 'ecs-tasks.amazonaws.com' }, + }, + ], + Version: '2012-10-17', + }, + }); + }); + test('respects readonlyRootFilesystem', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + readonlyRootFilesystem: true, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ReadonlyRootFilesystem: true, + }, + }); + }); + test('respects secrets from secrestsmanager', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + secrets: { + envName: lib_1.Secret.fromSecretsManager(new secretsmanager.Secret(stack, 'testSecret')), + }, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Secrets: [ + { + Name: 'envName', + ValueFrom: { Ref: 'testSecretB96AD12C' }, + }, + ], + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [ + { + Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], + Effect: 'Allow', + Resource: { + 'Fn::Join': [ + '', [ + 'arn:', + { Ref: 'AWS::Partition' }, + ':logs:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':log-group:/aws/batch/job:*', + ], + ], + }, + }, + { + Action: ['secretsmanager:GetSecretValue', 'secretsmanager:DescribeSecret'], + Effect: 'Allow', + Resource: { Ref: 'testSecretB96AD12C' }, + }, + ], + }, + }); + }); + test('respects versioned secrets from secrestsmanager', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + secrets: { + envName: lib_1.Secret.fromSecretsManagerVersion(new secretsmanager.Secret(stack, 'testSecret'), { + versionId: 'versionID', + versionStage: 'stage', + }), + }, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Secrets: [ + { + Name: 'envName', + ValueFrom: { + 'Fn::Join': [ + '', [ + { Ref: 'testSecretB96AD12C' }, + '::stage:versionID', + ], + ], + }, + }, + ], + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [ + { + Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], + Effect: 'Allow', + Resource: { + 'Fn::Join': [ + '', [ + 'arn:', + { Ref: 'AWS::Partition' }, + ':logs:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':log-group:/aws/batch/job:*', + ], + ], + }, + }, + { + Action: ['secretsmanager:GetSecretValue', 'secretsmanager:DescribeSecret'], + Effect: 'Allow', + Resource: { Ref: 'testSecretB96AD12C' }, + }, + ], + }, + }); + }); + test('respects secrets from ssm', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + secrets: { + envName: lib_1.Secret.fromSsmParameter(new ssm.StringParameter(stack, 'myParam', { stringValue: 'super secret' })), + }, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Secrets: [ + { + Name: 'envName', + ValueFrom: { + 'Fn::Join': [ + '', [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':ssm:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':parameter/', + { Ref: 'myParam03610B68' }, + ], + ], + }, + }, + ], + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [ + { + Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], + Effect: 'Allow', + Resource: { + 'Fn::Join': [ + '', [ + 'arn:', + { Ref: 'AWS::Partition' }, + ':logs:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':log-group:/aws/batch/job:*', + ], + ], + }, + }, + { + Action: ['ssm:DescribeParameters', 'ssm:GetParameters', 'ssm:GetParameter', 'ssm:GetParameterHistory'], + Effect: 'Allow', + Resource: { + 'Fn::Join': [ + '', + [ + 'arn:', + { Ref: 'AWS::Partition' }, + ':ssm:', + { Ref: 'AWS::Region' }, + ':', + { Ref: 'AWS::AccountId' }, + ':parameter/', + { Ref: 'myParam03610B68' }, + ], + ], + }, + }, + ], + }, + }); + }); + test('respects user', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + user: 'foo', + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + User: 'foo', + }, + }); + }); + test('respects efs volumes', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + volumes: [ + lib_1.EcsVolume.efs({ + containerPath: '/first/path', + fileSystem: new efs.FileSystem(stack, 'efs', { + vpc: new aws_ec2_1.Vpc(stack, 'vpc'), + }), + name: 'firstEfsVolume', + accessPointId: 'EfsVolumeAccessPointId', + readonly: true, + rootDirectory: 'efsRootDir', + enableTransitEncryption: true, + transitEncryptionPort: 20181, + useJobRole: true, + }), + lib_1.EcsVolume.efs({ + containerPath: '/second/path', + fileSystem: new efs.FileSystem(stack, 'efs2', { + vpc: new aws_ec2_1.Vpc(stack, 'vpc2'), + }), + name: 'secondEfsVolume', + }), + ], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Volumes: [ + { + EfsVolumeConfiguration: { + FileSystemId: { + Ref: 'efs6C17982A', + }, + RootDirectory: 'efsRootDir', + TransitEncryptionPort: 20181, + AuthorizationConfig: { + AccessPointId: 'EfsVolumeAccessPointId', + Iam: 'ENABLED', + }, + }, + Name: 'firstEfsVolume', + }, + { + EfsVolumeConfiguration: { + FileSystemId: { + Ref: 'efs2CB3916C1', + }, + }, + Name: 'secondEfsVolume', + }, + ], + MountPoints: [ + { + ContainerPath: '/first/path', + ReadOnly: true, + SourceVolume: 'firstEfsVolume', + }, + { + ContainerPath: '/second/path', + SourceVolume: 'secondEfsVolume', + }, + ], + }, + }); + }); + test('respects host volumes', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + volumes: [ + lib_1.EcsVolume.host({ + containerPath: '/container/path', + name: 'EcsHostPathVolume', + hostPath: '/host/path', + }), + ], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Volumes: [ + { + Name: 'EcsHostPathVolume', + Host: { + SourcePath: '/host/path', + }, + }, + ], + MountPoints: [ + { + ContainerPath: '/container/path', + SourceVolume: 'EcsHostPathVolume', + }, + ], + }, + }); + }); + test('respects addVolume() with an EfsVolume', () => { + // GIVEN + const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addVolume(lib_1.EcsVolume.efs({ + containerPath: '/container/path', + fileSystem: new efs.FileSystem(stack, 'efs', { + vpc: new aws_ec2_1.Vpc(stack, 'vpc'), + }), + name: 'AddedEfsVolume', + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Volumes: [{ + Name: 'AddedEfsVolume', + EfsVolumeConfiguration: { + FileSystemId: { + Ref: 'efs6C17982A', + }, + }, + }], + MountPoints: [{ + ContainerPath: '/container/path', + SourceVolume: 'AddedEfsVolume', + }], + }, + }); + }); + test('respects addVolume() with a host volume', () => { + // GIVEN + const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addVolume(lib_1.EcsVolume.host({ + containerPath: '/container/path/new', + name: 'hostName', + hostPath: '/host/path', + readonly: false, + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Volumes: [{ + Name: 'hostName', + Host: { + SourcePath: '/host/path', + }, + }], + MountPoints: [{ + ContainerPath: '/container/path/new', + SourceVolume: 'hostName', + }], + }, + }); + }); + test('correctly renders docker images', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + image: ecs.ContainerImage.fromDockerImageAsset(new aws_ecr_assets_1.DockerImageAsset(stack, 'dockerImageAsset', { + directory: path.join(__dirname, 'batchjob-image'), + })), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Image: { + 'Fn::Sub': '${AWS::AccountId}.dkr.ecr.${AWS::Region}.${AWS::URLSuffix}/cdk-hnb659fds-container-assets-${AWS::AccountId}-${AWS::Region}:8b518243ecbfcfd08b4734069e7e74ff97b7889dfde0a60d16e7bdc96e6c593b', + }, + }, + }); + }); + test('correctly renders images from repositories', () => { + // GIVEN + const repo = new ecr.Repository(stack, 'Repo'); + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new ContainerDefinition(stack, 'EcsContainer', { + ...defaultContainerProps, + image: ecs.ContainerImage.fromEcrRepository(repo, 'my-tag'), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Image: { + 'Fn::Join': [ + '', + [ + { + 'Fn::Select': [ + 4, + { + 'Fn::Split': [ + ':', + { 'Fn::GetAtt': ['Repo02AC86CF', 'Arn'] }, + ], + }, + ], + }, + '.dkr.ecr.', + { + 'Fn::Select': [ + 3, + { + 'Fn::Split': [ + ':', + { 'Fn::GetAtt': ['Repo02AC86CF', 'Arn'] }, + ], + }, + ], + }, + '.', + { Ref: 'AWS::URLSuffix' }, + '/', + { Ref: 'Repo02AC86CF' }, + ':my-tag', + ], + ], + }, + }, + }); + }); +}); +describe('EC2 containers', () => { + // GIVEN + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { + ...defaultExpectedProps, + containerProperties: { + ...defaultExpectedProps.containerProperties, + executionRoleArn: { + 'Fn::GetAtt': ['EcsEc2ContainerExecutionRole90E18680', 'Arn'], + }, + }, + }); + }); + test('respects addUlimit()', () => { + // GIVEN + const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addUlimit({ + hardLimit: 10, + name: lib_1.UlimitName.SIGPENDING, + softLimit: 1, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Ulimits: [{ + HardLimit: 10, + SoftLimit: 1, + Name: 'sigpending', + }], + }, + }); + }); + test('respects ulimits', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + ulimits: [ + { + hardLimit: 100, + name: lib_1.UlimitName.CORE, + softLimit: 10, + }, + ], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Ulimits: [ + { + HardLimit: 100, + Name: 'core', + SoftLimit: 10, + }, + ], + }, + }); + }); + test('respects privileged', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + privileged: true, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Privileged: true, + }, + }); + }); + test('respects gpu', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + privileged: true, + gpu: 12, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ResourceRequirements: [ + { + Type: 'MEMORY', + Value: '2048', + }, + { + Type: 'VCPU', + Value: '256', + }, + { + Type: 'GPU', + Value: '12', + }, + ], + }, + }); + }); + test('can use an assset as a container', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + image: ecs.ContainerImage.fromAsset(path.join(__dirname, 'batchjob-image')), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + Image: { + 'Fn::Sub': '${AWS::AccountId}.dkr.ecr.${AWS::Region}.${AWS::URLSuffix}/cdk-hnb659fds-container-assets-${AWS::AccountId}-${AWS::Region}:8b518243ecbfcfd08b4734069e7e74ff97b7889dfde0a60d16e7bdc96e6c593b', + }, + ExecutionRoleArn: { 'Fn::GetAtt': ['EcsEc2ContainerExecutionRole90E18680', 'Arn'] }, + }, + }); + }); +}); +describe('Fargate containers', () => { + // GIVEN + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { + ...defaultExpectedProps, + containerProperties: { + ...defaultExpectedProps.containerProperties, + executionRoleArn: { + 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], + }, + }, + }); + }); + test('create executionRole by default', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { + ...defaultContainerProps, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ExecutionRoleArn: { + 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], + }, + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + AssumeRolePolicyDocument: { + Statement: [{ + Action: 'sts:AssumeRole', + Effect: 'Allow', + Principal: { Service: 'ecs-tasks.amazonaws.com' }, + }], + Version: '2012-10-17', + }, + }); + }); + test('can set ephemeralStorageSize', () => { + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { + ...defaultContainerProps, + fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, + ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(100), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ExecutionRoleArn: { + 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], + }, + EphemeralStorage: { + SizeInGiB: aws_cdk_lib_1.Size.gibibytes(100).toGibibytes(), + }, + }, + }); + }); + test('can set ephemeralStorageSize as token', () => { + const ephemeralStorageValue = cdk.Token.asNumber(150); + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { + ...defaultContainerProps, + fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, + ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(ephemeralStorageValue), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + ContainerProperties: { + ...pascalCaseExpectedProps.ContainerProperties, + ExecutionRoleArn: { + 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], + }, + EphemeralStorage: { + SizeInGiB: aws_cdk_lib_1.Size.gibibytes(150).toGibibytes(), + }, + }, + }); + }); + test('ephemeralStorageSize throws error when out of range', () => { + expect(() => new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { + ...defaultContainerProps, + fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, + ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(19), + }), + })).toThrow("ECS Fargate container 'EcsFargateContainer' specifies 'ephemeralStorageSize' at 19 < 21 GB"); + expect(() => new lib_1.EcsJobDefinition(stack, 'ECSJobDefn2', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer2', { + ...defaultContainerProps, + fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, + ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(201), + }), + })).toThrow("ECS Fargate container 'EcsFargateContainer2' specifies 'ephemeralStorageSize' at 201 > 200 GB"); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJlY3MtY29udGFpbmVyLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCw2QkFBNkI7QUFDN0IsaURBQTBDO0FBQzFDLDJDQUEyQztBQUMzQywyQ0FBMkM7QUFDM0MsMkNBQTJDO0FBQzNDLDJDQUEyQztBQUMzQyxpREFBeUQ7QUFDekQsNkNBQTZDO0FBQzdDLGlFQUFpRTtBQUNqRSw2Q0FBMEM7QUFDMUMsbUNBQW1DO0FBQ25DLGdDQUE2TTtBQUU3TSxtQ0FBa0Q7QUFDbEQsK0RBQThEO0FBRTlELFFBQVE7QUFDUixNQUFNLHFCQUFxQixHQUFnQztJQUN6RCxHQUFHLEVBQUUsR0FBRztJQUNSLEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFlBQVksQ0FBQywwQkFBMEIsQ0FBQztJQUNsRSxNQUFNLEVBQUUsa0JBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDO0NBQzdCLENBQUM7QUFFRixNQUFNLG9CQUFvQixHQUEwQjtJQUNsRCxJQUFJLEVBQUUsV0FBVztJQUNqQixtQkFBbUIsRUFBRTtRQUNuQixLQUFLLEVBQUUsMEJBQTBCO1FBQ2pDLG9CQUFvQixFQUFFO1lBQ3BCO2dCQUNFLElBQUksRUFBRSxRQUFRO2dCQUNkLEtBQUssRUFBRSxNQUFNO2FBQ2Q7WUFDRDtnQkFDRSxJQUFJLEVBQUUsTUFBTTtnQkFDWixLQUFLLEVBQUUsS0FBSzthQUNiO1NBQ0Y7S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AgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsXG4gICAgICAgICAgICAgICAgW1xuICAgICAgICAgICAgICAgICAgJ2FybjonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlBhcnRpdGlvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6bG9nczonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlJlZ2lvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpBY2NvdW50SWQnIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZy1ncm91cDovYXdzL2JhdGNoL2pvYjoqJyxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgICB9LFxuICAgICAgUG9saWN5TmFtZTogJ0Vjc0NvbnRhaW5lckV4ZWN1dGlvblJvbGVEZWZhdWx0UG9saWN5NkY1OUNEMzcnLFxuICAgICAgUm9sZXM6IFt7XG4gICAgICAgIFJlZjogJ0Vjc0NvbnRhaW5lckV4ZWN1dGlvblJvbGUzQjE5OTI5MycsXG4gICAgICB9XSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgY29tbWFuZCcsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICBjb21tYW5kOiBbJ2VjaG8nLCAn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YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgU2VjcmV0czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIE5hbWU6ICdlbnZOYW1lJyxcbiAgICAgICAgICAgIFZhbHVlRnJvbTogeyBSZWY6ICd0ZXN0U2VjcmV0Qjk2QUQxMkMnIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgXSxcbiAgICAgIH0sXG4gICAgfSk7XG5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpJQU06OlBvbGljeScsIHtcbiAgICAgIFBvbGljeURvY3VtZW50OiB7XG4gICAgICAgIFN0YXRlbWVudDogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIEFjdGlvbjogWydsb2dzOkNyZWF0ZUxvZ1N0cmVhbScsICdsb2dzOlB1dExvZ0V2ZW50cyddLFxuICAgICAgICAgICAgRWZmZWN0OiAnQWxsb3cnLFxuICAgICAgICAgICAgUmVzb3VyY2U6IHtcbiAgICAgICAgICAgICAgJ0ZuOjpKb2luJzogW1xuICAgICAgICAgICAgICAgICcnLCBbXG4gICAgICAgICAgICAgICAgICAnYXJuOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UGFydGl0aW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2dzOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZ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uICAgICAgfSksXG4gICAgfSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgU2VjcmV0czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIE5hbWU6ICdlbnZOYW1lJyxcbiAgICAgICAgICAgIFZhbHVlRnJvbToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAndGVzdFNlY3JldEI5NkFEMTJDJyB9LFxuICAgICAgICAgICAgICAgICAgJzo6c3RhZ2U6dmVyc2lvbklEJyxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgICAgUG9saWN5RG9jdW1lbnQ6IHtcbiAgICAgICAgU3RhdGVtZW50OiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiBbJ2xvZ3M6Q3JlYXRlTG9nU3RyZWFtJywgJ2xvZ3M6UHV0TG9nRXZlbnRzJ10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpQYXJ0aXRpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZ3M6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpSZWdpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6QWNjb3VudElkJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2ctZ3JvdXA6L2F3cy9iYXRjaC9qb2I6KicsXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246IFsnc2VjcmV0c21hbmFnZXI6R2V0U2VjcmV0VmFsdWUnLCAnc2VjcmV0c21hbmFnZXI6RGVzY3JpYmVTZWNyZXQnXSxcbiAgICAgICAgICAgIEVmZmVjdDogJ0FsbG93JyxcbiAgICAgICAgICAgIFJlc291cmNlOiB7IFJlZjogJ3Rlc3RTZWNyZXRCOTZBRDEyQycgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgc2VjcmV0cyBmcm9tIHNzbScsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICBzZWNyZXRzOiB7XG4gICAgICAgICAgZW52TmFtZTogU2VjcmV0LmZyb21Tc21QYXJhbWV0ZXIobmV3IHNzbS5TdHJpbmdQYXJhbWV0ZXIoc3RhY2ssICdteVBhcmFtJywgeyBzdHJpbmdWYWx1ZTogJ3N1cGVyIHNlY3JldCcgfSkpLFxuICAgICAgICB9LFxuICAgICAgfSksXG4gICAgfSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgU2VjcmV0czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIE5hbWU6ICdlbnZOYW1lJyxcbiAgICAgICAgICAgIFZhbHVlRnJvbToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgUmVmOiAnQVdTOjpQYXJ0aXRpb24nLFxuICAgICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICAgICc6c3NtOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OkFjY291bnRJZCcgfSxcbiAgICAgICAgICAgICAgICAgICc6cGFyYW1ldGVyLycsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ215UGFyYW0wMzYxMEI2OCcgfSxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgICAgUG9saWN5RG9jdW1lbnQ6IHtcbiAgICAgICAgU3RhdGVtZW50OiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiBbJ2xvZ3M6Q3JlYXRlTG9nU3RyZWFtJywgJ2xvZ3M6UHV0TG9nRXZlbnRzJ10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpQYXJ0aXRpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZ3M6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpSZWdpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6QWNjb3VudElkJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2ctZ3JvdXA6L2F3cy9iYXRjaC9qb2I6KicsXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246IFsnc3NtOkRlc2NyaWJlUGFyYW1ldGVycycsICdzc206R2V0UGFyYW1ldGVycycsICdzc206R2V0UGFyYW1ldGVyJywgJ3NzbTpHZXRQYXJhbWV0ZXJIaXN0b3J5J10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsXG4gICAgICAgICAgICAgICAgW1xuICAgICAgICAgICAgICAgICAgJ2FybjonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlBhcnRpdGlvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6c3NtOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OkFjY291bnRJZCcgfSxcbiAgICAgICAgICAgICAgICAgICc6cGFyYW1ldGVyLycsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ215UGFyYW0wMzYxMEI2OCcgfSxcbiAgICAgICAgICAgICAgICBdLFxuXG4gICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyB1c2VyJywgKCkgPT4ge1xuICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICB1c2VyOiAnZm9vJyxcbiAgICAgIH0pLFxuICAgIH0pO1xuXG4gICAgLy8gVEhFTlxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkJhdGNoOjpKb2JEZWZpbml0aW9uJywge1xuICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMs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gfSksXG4gICAgICAgICAgRWNzVm9sdW1lLmVmcyh7XG4gICAgICAgICAgICBjb250YWluZXJQYXRoOiAnL3NlY29uZC9wYXRoJyxcbiAgICAgICAgICAgIGZpbGVTeXN0ZW06IG5ldyBlZnMuRmlsZVN5c3RlbShzdGFjaywgJ2VmczInLCB7XG4gICAgICAgICAgICAgIHZwYzogbmV3IFZwYyhzdGFjaywgJ3ZwYzInKSxcbiAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgbmFtZTogJ3NlY29uZEVmc1ZvbHVtZScsXG4gICAgICAgICAgfSksXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBWb2x1bWVzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgRWZzVm9sdW1lQ29uZmlndXJhdGlvbjoge1xuICAgICAgICAgICAgICBGaWxlU3lzdGVtSWQ6IHtcbiAgICAgICAgICAgICAgICBSZWY6ICdlZnM2QzE3OTgyQScsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIFJvb3REaXJlY3Rvcnk6ICdlZnNSb290RGlyJyxcbiAgICAgICAgICAgICAgVHJhbnNpdEVuY3J5cHRpb25Qb3J0OiAyMDE4MSxcbiAgICAgICAgICAgICAgQXV0aG9yaXphdGlvbkNvbmZpZzoge1xuICAgICAgICAgICAgICAgIEFjY2Vzc1BvaW50SWQ6ICdFZnNWb2x1bWVBY2Nlc3NQb2ludElkJyxcbiAgICAgICAgICAgICAgICBJYW06ICdFTkFCTEVEJyxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBOYW1lOiAnZmlyc3RFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgRWZzVm9sdW1lQ29uZmlndXJhdGlvbjoge1xuICAgICAgICAgICAgICBGaWxlU3lzdGVtSWQ6IHtcbiAgICAgICAgICAgICAgICBSZWY6ICdlZnMyQ0IzOTE2QzEnLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIE5hbWU6ICdzZWNvbmRFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICAgIE1vdW50UG9pbnRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQ29udGFpbmVyUGF0aDogJy9maXJzdC9wYXRoJyxcbiAgICAgICAgICAgIFJlYWRPbmx5OiB0cnVlLFxuICAgICAgICAgICAgU291cmNlVm9sdW1lOiAnZmlyc3RFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQ29udGFpbmVyUGF0aDogJy9zZWNvbmQvcGF0aCcsXG4gICAgICAgICAgICBTb3VyY2VWb2x1bWU6ICdzZWNvbmRFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBob3N0IHZvbHVtZXMnLCAoKSA9PiB7XG4gICAgLy8gV0hFTlxuICAgIG5ldyBFY3NKb2JEZWZpbml0aW9uKHN0YWNrLCAnRUNTSm9iRGVmbicsIHtcbiAgICAgIGNvbnRhaW5lcjogbmV3IENvbnRhaW5lckRlZmluaXRpb24oc3RhY2ssICdFY3NDb250YWluZXInLCB7XG4gICAgICAgIC4uLmRlZmF1bHRDb250YWluZXJQcm9wcyxcbiAgICAgICAgdm9sdW1lczogW1xuICAgICAgICAgIEVjc1ZvbHVtZS5ob3N0KHtcbiAgICAgICAgICAgIGNvbnRhaW5lclBhdGg6ICcvY29udGFpbmVyL3BhdGgnLFxuICAgICAgICAgICAgbmFtZTogJ0Vjc0hvc3RQYXRoVm9sdW1lJyxcbiAgICAgICAgICAgIGhvc3RQYXRoOiAnL2hvc3QvcGF0aCcsXG4gICAgICAgICAgfSksXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBWb2x1bWVzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgTmFtZTogJ0Vjc0hvc3RQYXRoVm9sdW1lJyxcbiAgICAgICAgICAgIEhvc3Q6IHtcbiAgICAgICAgICAgICAgU291cmNlUGF0aDogJy9ob3N0L3BhdGgnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBNb3VudFBvaW50czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIENvbnRhaW5lclBhdGg6ICcvY29udGFpbmVyL3BhdGgnLFxuICAgICAgICAgICAgU291cmNlVm9sdW1lOiAnRWNzSG9zdFBhdGhWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBhZGRWb2x1bWUoKSB3aXRoIGFuIEVmc1ZvbHVtZ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vbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgSW1hZ2U6IHtcbiAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAnJyxcbiAgICAgICAgICAgIFtcbiAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICAgICAgNCxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICAgICAgeyAnRm46OkdldEF0dCc6IFsnUmVwbzAyQUM4NkNGJywgJ0FybiddIH0sXG4gICAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICcuZGtyLmVjci4nLFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTZWxlY3QnOiBbXG4gICAgICAgICAgICAgICAgICAzLFxuICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAnRm46OlNwbGl0JzogW1xuICAgICAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgICAgICB7ICdGbjo6R2V0QXR0JzogWydSZXBvMDJBQzg2Q0YnLCAnQXJuJ10gfSxcbiAgICAgICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAg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xuICAgICAgICB1bGltaXRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgaGFyZExpbWl0OiAxMDAsXG4gICAgICAgICAgICBuYW1lOiBVbGltaXROYW1lLkNPUkUsXG4gICAgICAgICAgICBzb2Z0TGltaXQ6IDEwLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBVbGltaXRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgSGFyZExpbWl0OiAxMDAsXG4gICAgICAgICAgICBOYW1lOiAnY29yZScsXG4gICAgICAgICAgICBTb2Z0TGltaXQ6IDEwLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBwcml2aWxlZ2VkJywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWNzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0VDU0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFY3NFYzJDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzRWMyQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIHByaXZpbGVnZWQ6IHRydWUsXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS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mdhdGVDb250YWluZXIyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGZhcmdhdGVQbGF0Zm9ybVZlcnNpb246IGVjcy5GYXJnYXRlUGxhdGZvcm1WZXJzaW9uLkxBVEVTVCxcbiAgICAgICAgZXBoZW1lcmFsU3RvcmFnZVNpemU6IFNpemUuZ2liaWJ5dGVzKDIwMSksXG4gICAgICB9KSxcbiAgICB9KSkudG9UaHJvdyhcIkVDUyBGYXJnYXRlIGNvbnRhaW5lciAnRWNzRmFyZ2F0ZUNvbnRhaW5lcjInIHNwZWNpZmllcyAnZXBoZW1lcmFsU3RvcmFnZVNpemUnIGF0IDIwMSA+IDIwMCBHQlwiKTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js new file mode 100644 index 0000000000000..0eb741964ca54 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js @@ -0,0 +1,147 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const iam = require("aws-cdk-lib/aws-iam"); +const lib_1 = require("../lib"); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +test('EcsJobDefinition respects propagateTags', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EcsJobDefinition(stack, 'JobDefn', { + propagateTags: true, + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + PropagateTags: true, + }); +}); +test('EcsJobDefinition uses Compatibility.EC2 for EC2 containers', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + PlatformCapabilities: [lib_1.Compatibility.EC2], + }); +}); +test('EcsJobDefinition uses Compatibility.FARGATE for Fargate containers', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + PlatformCapabilities: [lib_1.Compatibility.FARGATE], + }); +}); +test('can be imported from ARN', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + const importedJob = lib_1.EcsJobDefinition.fromJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); + // THEN + expect(importedJob.jobDefinitionArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); +}); +test('JobDefinitionName is parsed from arn', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + const jobDefinition = new lib_1.EcsJobDefinition(stack, 'JobDefn', { + propagateTags: true, + container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + expect(aws_cdk_lib_1.Tokenization.resolve(jobDefinition.jobDefinitionName, { + scope: stack, + resolver: new aws_cdk_lib_1.DefaultTokenResolver(new aws_cdk_lib_1.StringConcat()), + })).toEqual({ + 'Fn::Select': [ + 1, + { + 'Fn::Split': [ + '/', + { + 'Fn::Select': [ + 5, + { + 'Fn::Split': [ + ':', + { + Ref: 'JobDefnA747EE6E', + }, + ], + }, + ], + }, + ], + }, + ], + }); +}); +test('JobDefinitionName is parsed from arn in imported job', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + const importedJob = lib_1.EcsJobDefinition.fromJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); + // THEN + expect(importedJob.jobDefinitionName).toEqual('job-def-name'); +}); +test('grantSubmitJob() grants the job role the correct actions', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const ecsJob = new lib_1.EcsJobDefinition(stack, 'ECSJob', { + container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('foorepo/fooimage'), + }), + }); + const queue = new lib_1.JobQueue(stack, 'queue'); + queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'env', { + vpc: new aws_ec2_1.Vpc(stack, 'VPC'), + }), 1); + const user = new iam.User(stack, 'MyUser'); + // WHEN + ecsJob.grantSubmitJob(user, queue); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { + PolicyDocument: { + Statement: [{ + Action: 'batch:SubmitJob', + Effect: 'Allow', + Resource: [ + { Ref: 'ECSJobFFFEA569' }, + { 'Fn::GetAtt': ['queue276F7297', 'JobQueueArn'] }, + ], + }], + Version: '2012-10-17', + }, + PolicyName: 'MyUserDefaultPolicy7B897426', + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWpvYi1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJlY3Mtam9iLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsNkNBQTRGO0FBQzVGLDJDQUEyQztBQUMzQyxnQ0FBOEo7QUFDOUosaURBQTBDO0FBRTFDLElBQUksQ0FBQyx5Q0FBeUMsRUFBRSxHQUFHLEVBQUU7SUFDbkQsUUFBUTtJQUNSLE1BQU0sS0FBSyxHQUFHLElBQUksbUJBQUssRUFBRSxDQUFDO0lBRTFCLE9BQU87SUFDUCxJQUFJLHNCQUFnQixDQUFDLEtBQUssRUFBRSxTQUFTLEVBQUU7UUFDckMsYUFBYSxFQUFFLElBQUk7UUFDbkIsU0FBUyxFQUFFLElBQUksK0JBQXlCLENBQUMsS0FBSyxFQUFFLGNBQWMsRUFBRTtZQUM5RCxHQUFHLEVBQUUsR0FBRztZQUNSLEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFlBQVksQ0FBQywwQkFBMEIsQ0FBQztZQUNsRSxNQUFNLEVBQUUsa0JBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDO1NBQzdCLENBQUM7S0FDSCxDQUFDLENBQUM7SUFFSCxPQUFPO0lBQ1AscUJBQVEsQ0FBQyxTQUFTLENBQUMsS0FBSyxDQUFDLENBQUMscUJBQXFCLENBQUMsMkJBQTJCLEVBQUU7UUFDM0UsYUFBYS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i9hbWF6b24tZWNzLXNhbXBsZScpLFxuICAgICAgbWVtb3J5OiBTaXplLm1lYmlieXRlcygyMDQ4KSxcbiAgICB9KSxcbiAgfSk7XG5cbiAgLy8gVEhFTlxuICBleHBlY3QoVG9rZW5pemF0aW9uLnJlc29sdmUoam9iRGVmaW5pdGlvbi5qb2JEZWZpbml0aW9uTmFtZSwge1xuICAgIHNjb3BlOiBzdGFjayxcbiAgICByZXNvbHZlcjogbmV3IERlZmF1bHRUb2tlblJlc29sdmVyKG5ldyBTdHJpbmdDb25jYXQoKSksXG4gIH0pKS50b0VxdWFsKHtcbiAgICAnRm46OlNlbGVjdCc6IFtcbiAgICAgIDEsXG4gICAgICB7XG4gICAgICAgICdGbjo6U3BsaXQnOiBbXG4gICAgICAgICAgJy8nLFxuICAgICAgICAgIHtcbiAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICA1LFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgUmVmOiAnSm9iRGVmbkE3NDdFRTZFJyxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgXSxcbiAgICAgIH0sXG4gICAgXSxcbiAgfSk7XG59KTtcblxudGVzdCgnSm9iRGVmaW5pdGlvbk5hbWUgaXMgcGFyc2VkIGZyb20gYXJuIGluIGltcG9ydGVkIGpvYicsICgpID0+IHtcbiAgLy8gR0lWRU5cbiAgY29uc3Qgc3RhY2sgPSBuZXcgU3RhY2soKTtcblxuICAvLyBXSEVOXG4gIGNvbnN0IGltcG9ydGVkSm9iID0gRWNzSm9iRGVmaW5pdGlvbi5mcm9tSm9iRGVmaW5pdGlvbkFybihzdGF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NlcicpO1xuXG4gIC8vIFdIRU5cbiAgZWNzSm9iLmdyYW50U3VibWl0Sm9iKHVzZXIsIHF1ZXVlKTtcblxuICAvLyBUSEVOXG4gIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgIFBvbGljeURvY3VtZW50OiB7XG4gICAgICBTdGF0ZW1lbnQ6IFt7XG4gICAgICAgIEFjdGlvbjogJ2JhdGNoOlN1Ym1pdEpvYicsXG4gICAgICAgIEVmZmVjdDogJ0FsbG93JyxcbiAgICAgICAgUmVzb3VyY2U6IFtcbiAgICAgICAgICB7IFJlZjogJ0VDU0pvYkZGRkVBNTY5JyB9LFxuICAgICAgICAgIHsgJ0ZuOjpHZXRBdHQnOiBbJ3F1ZXVlMjc2RjcyOTcnLCAnSm9iUXVldWVBcm4nXSB9LFxuICAgICAgICBdLFxuICAgICAgfV0sXG4gICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgfSxcbiAgICBQb2xpY3lOYW1lOiAnTXlVc2VyRGVmYXVsdFBvbGljeTdCODk3NDI2JyxcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js new file mode 100644 index 0000000000000..3230501ab97c5 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js @@ -0,0 +1,712 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const utils_1 = require("./utils"); +const lib_1 = require("../lib"); +// GIVEN +const defaultContainerProps = { + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), +}; +const defaultExpectedProps = { + type: 'container', + eksProperties: { + podProperties: { + containers: [{ + image: 'amazon/amazon-ecs-sample', + }], + }, + }, +}; +let stack; +let pascalCaseExpectedProps; +describe('eks container', () => { + // GIVEN + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedProps); + }); + test('eks container defaults', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + }); + }); + test('respects args', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + args: ['arg1', 'arg2'], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Args: ['arg1', 'arg2'], + }], + }, + }, + }); + }); + test('respects command', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + command: ['echo', 'bar'], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Command: ['echo', 'bar'], + }], + }, + }, + }); + }); + test('respects cpuLimit', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + cpuLimit: 256, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Limits: { + cpu: 256, + }, + }, + }], + }, + }, + }); + }); + test('respects cpuReservation', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + cpuReservation: 256, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Requests: { + cpu: 256, + }, + }, + }], + }, + }, + }); + }); + test('respects memoryLimitMiB', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + memoryLimit: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Limits: { + memory: '2048Mi', + }, + }, + }], + }, + }, + }); + }); + test('respects memoryReservation', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + memoryReservation: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Requests: { + memory: '2048Mi', + }, + }, + }], + }, + }, + }); + }); + test('respects gpuLimit', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + gpuLimit: 20, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Limits: { + 'nvidia.com/gpu': 20, + }, + }, + }], + }, + }, + }); + }); + test('respects gpuReservation', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + gpuReservation: 20, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Requests: { + 'nvidia.com/gpu': 20, + }, + }, + }], + }, + }, + }); + }); + test('respects resource requests and limits', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + cpuLimit: 256, + cpuReservation: 128, + memoryLimit: aws_cdk_lib_1.Size.mebibytes(2048), + memoryReservation: aws_cdk_lib_1.Size.mebibytes(2048), + gpuLimit: 20, + gpuReservation: 10, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Resources: { + Limits: { + 'cpu': 256, + 'memory': '2048Mi', + 'nvidia.com/gpu': 20, + }, + Requests: { + 'cpu': 128, + 'memory': '2048Mi', + 'nvidia.com/gpu': 10, + }, + }, + }], + }, + }, + }); + }); + test('respects env', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + env: { + var: 'val', + boo: 'bah', + }, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Env: [ + { + Name: 'var', + Value: 'val', + }, + { + Name: 'boo', + Value: 'bah', + }, + ], + }], + }, + }, + }); + }); + test('respects imagePullPolicy', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + imagePullPolicy: lib_1.ImagePullPolicy.NEVER, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + ImagePullPolicy: 'Never', + }], + }, + }, + }); + }); + test('respects name', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + name: 'myContainerName', + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + Name: 'myContainerName', + }], + }, + }, + }); + }); + test('respects privileged', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + privileged: true, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + SecurityContext: { + Privileged: true, + }, + }], + }, + }, + }); + }); + test('respects readonlyFileSystem', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + readonlyRootFilesystem: true, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + SecurityContext: { + ReadOnlyRootFilesystem: true, + }, + }], + }, + }, + }); + }); + test('respects runAsGroup', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + runAsGroup: 1, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + SecurityContext: { + RunAsGroup: 1, + }, + }], + }, + }, + }); + }); + test('respects runAsRoot', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefEksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + runAsRoot: true, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + SecurityContext: { + RunAsNonRoot: false, + }, + }], + }, + }, + }); + }); + test('respects runAsUser', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + runAsUser: 90, + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + SecurityContext: { + RunAsUser: 90, + }, + }], + }, + }, + }); + }); + test('respects emptyDir volumes', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + volumes: [ + lib_1.EksVolume.emptyDir({ + name: 'emptyDirName', + medium: lib_1.EmptyDirMediumType.DISK, + mountPath: '/mount/path', + readonly: false, + sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), + }), + ], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + Name: 'emptyDirName', + ReadOnly: false, + }], + }], + Volumes: [{ + Name: 'emptyDirName', + EmptyDir: { + Medium: '', + SizeLimit: '2048Mi', + }, + }], + }, + }, + }); + }); + test('respects hostPath volumes', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + volumes: [lib_1.EksVolume.hostPath({ + name: 'hostPathName', + hostPath: 'hostPathPath', + mountPath: '/mount/path', + readonly: true, + })], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + Name: 'hostPathName', + ReadOnly: true, + }], + }], + Volumes: [{ + Name: 'hostPathName', + HostPath: { + Path: 'hostPathPath', + }, + }], + }, + }, + }); + }); + test('respects secret volumes, and ensures optional defaults to true', () => { + // WHEN + new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + volumes: [lib_1.EksVolume.secret({ + name: 'secretVolumeName', + secretName: 'myKubeSecret', + mountPath: '/mount/path', + readonly: true, + })], + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + ReadOnly: true, + }], + }], + Volumes: [{ + Name: 'secretVolumeName', + Secret: { + SecretName: 'myKubeSecret', + Optional: true, + }, + }], + }, + }, + }); + }); + test('respects addVolume() with emptyDir volume', () => { + // GIVEN + const jobDefn = new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addVolume(lib_1.EksVolume.emptyDir({ + name: 'emptyDirName', + medium: lib_1.EmptyDirMediumType.DISK, + mountPath: '/mount/path', + readonly: false, + sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + Name: 'emptyDirName', + ReadOnly: false, + }], + }], + Volumes: [{ + Name: 'emptyDirName', + EmptyDir: { + Medium: '', + SizeLimit: '2048Mi', + }, + }], + }, + }, + }); + }); + test('respects addVolume() with hostPath volume', () => { + // GIVEN + const jobDefn = new lib_1.EksJobDefinition(stack, 'EksJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addVolume(lib_1.EksVolume.hostPath({ + name: 'hostPathName', + hostPath: 'hostPathPath', + mountPath: '/mount/path', + readonly: true, + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + Name: 'hostPathName', + ReadOnly: true, + }], + }], + Volumes: [{ + Name: 'hostPathName', + HostPath: { + Path: 'hostPathPath', + }, + }], + }, + }, + }); + }); + test('respects addVolume() with secret volume (optional: false)', () => { + // GIVEN + const jobDefn = new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { + ...defaultContainerProps, + }), + }); + // WHEN + jobDefn.container.addVolume(lib_1.EksVolume.secret({ + name: 'secretVolumeName', + secretName: 'secretName', + optional: false, + mountPath: '/mount/path', + readonly: true, + })); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...pascalCaseExpectedProps, + EksProperties: { + PodProperties: { + ...pascalCaseExpectedProps.EksProperties.PodProperties, + Containers: [{ + ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], + VolumeMounts: [{ + MountPath: '/mount/path', + Name: 'secretVolumeName', + ReadOnly: true, + }], + }], + Volumes: [{ + Name: 'secretVolumeName', + Secret: { + SecretName: 'secretName', + Optional: false, + }, + }], + }, + }, + }); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJla3MtY29udGFpbmVyLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsNkNBQTBDO0FBQzFDLG1DQUFrRDtBQUNsRCxnQ0FBK0k7QUFHL0ksUUFBUTtBQUNSLE1BQU0scUJBQXFCLEdBQWdDO0lBQ3pELEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFlBQVksQ0FBQywwQkFBMEIsQ0FBQztDQUN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AgICAgICAgICBMaW1pdHM6IHtcbiAgICAgICAgICAgICAgICAnbnZpZGlhLmNvbS9ncHUnOiAyMCxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfV0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBncHVSZXNlcnZhdGlvbicsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVrc0pvYkRlZmluaXRpb24oc3RhY2ssICdFa3NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgRWtzQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0VjMkNvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICBncHVSZXNlcnZhdGlvbjogMjAsXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgRWtzUHJvcGVydGllczoge1xuICAgICAgICBQb2RQcm9wZXJ0aWVzOiB7XG4gICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLFxuICAgICAgICAgIENvbnRhaW5lcnM6IFt7XG4gICAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMuQ29udGFpbmVyc1swXSxcbiAgICAgICAgICAgIFJlc291cmNlczoge1xuICAgICAgICAgICAgICBSZXF1ZXN0czoge1xuICAgICAgICAgICAgICAgICdudmlkaW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uICAgICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLkNvbnRhaW5lcnNbMF0sXG4gICAgICAgICAgICBSZXNvdXJjZXM6IHtcbiAgICAgICAgICAgICAgTGltaXRzOiB7XG4gICAgICAgICAgICAgICAgJ2NwdSc6IDI1NixcbiAgICAgICAgICAgICAgICAnbWVtb3J5JzogJzIwNDhNaScsXG4gICAgICAgICAgICAgICAgJ252aWRpYS5jb20vZ3B1JzogMjAsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIFJlcXVlc3RzOiB7XG4gICAgICAgICAgICAgICAgJ2NwdSc6IDEyOCxcbiAgICAgICAgICAgICAgICAnbWVtb3J5JzogJzIwNDhNaScsXG4gICAgICAgICAgICAgICAgJ252aWRpYS5jb20vZ3B1JzogMTAsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH1dLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgZW52JywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWtzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0Vrc0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFa3NDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzRWMyQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGVudjoge1xuICAgICAgICAgIHZhcjogJ3ZhbCcsXG4gICAgICAgICAgYm9vOiAnYmFoJyxcbiAgICAgICAgfSxcbiAgICAgIH0pLFxuICAgIH0pO1xuXG4gICAgLy8gVEhFTlxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkJhdGNoOjpKb2JEZWZpbml0aW9uJywge1xuICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMsXG4gICAgICBFa3NQcm9wZXJ0aWVzOiB7XG4gICAgICAgIFBvZFByb3BlcnRpZXM6IHtcbiAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMsXG4gICAgICAgICAgQ29udGFpbmVyczogW3tcbiAgICAgICAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLkVrc1Byb3BlcnRpZXMuUG9kUHJvcGVydGllcy5Db250YWluZXJzWzBdLFxuICAgICAgICAgICAgRW52OiBbXG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICBOYW1lOiAndmFyJyxcbiAgICAgICAgICAgICAgICBWYWx1ZTogJ3ZhbCcsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICBOYW1lOiAnYm9vJyxcbiAgICAgICAgICAgICAgICBWYWx1ZTogJ2JhaCcsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIH1dLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgaW1hZ2VQdWxsUG9saWN5JywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWtzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0Vrc0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFa3NDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzRWMyQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGltYWdlUHVsbFBvbGljeTogSW1hZ2VQdWxsUG9saWN5Lk5FVkVSLFxuICAgICAgfSksXG4gICAgfSk7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WVzLkNvbnRhaW5lcnNbMF0sXG4gICAgICAgICAgICBWb2x1bWVNb3VudHM6IFt7XG4gICAgICAgICAgICAgIE1vdW50UGF0aDogJy9tb3VudC9wYXRoJyxcbiAgICAgICAgICAgICAgTmFtZTogJ2VtcHR5RGlyTmFtZScsXG4gICAgICAgICAgICAgIFJlYWRPbmx5OiBmYWxzZSxcbiAgICAgICAgICAgIH1dLFxuICAgICAgICAgIH1dLFxuICAgICAgICAgIFZvbHVtZXM6IFt7XG4gICAgICAgICAgICBOYW1lOiAnZW1wdHlEaXJOYW1lJyxcbiAgICAgICAgICAgIEVtcHR5RGlyOiB7XG4gICAgICAgICAgICAgIE1lZGl1bTogJycsXG4gICAgICAgICAgICAgIFNpemVMaW1pdDogJzIwNDhNaScsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH1dLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgaG9zdFBhdGggdm9sdW1lcycsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVrc0pvYkRlZmluaXRpb24oc3RhY2ssICdFa3NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgRWtzQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0VjMkNvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICB2b2x1bWVzOiBbRWtzVm9sdW1lLmhvc3RQYXRoKHtcbiAgICAgICAgICBuYW1lOiAnaG9zdFBhdGhOYW1lJyxcbiAgICAgICAgICBob3N0UGF0aDogJ2hvc3RQYXRoUGF0aCcsXG4gICAgICAgICAgbW91bnRQYXRoOiAnL21vdW50L3BhdGgnLFxuICAgICAgICAgIHJlYWRvbmx5OiB0cnVlLFxuICAgICAgICB9KV0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1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2FsQ2FzZUV4cGVjdGVkUHJvcHMsXG4gICAgICBFa3NQcm9wZXJ0aWVzOiB7XG4gICAgICAgIFBvZFByb3BlcnRpZXM6IHtcbiAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMsXG4gICAgICAgICAgQ29udGFpbmVyczogW3tcbiAgICAgICAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLkVrc1Byb3BlcnRpZXMuUG9kUHJvcGVydGllcy5Db250YWluZXJzWzBdLFxuICAgICAgICAgICAgVm9sdW1lTW91bnRzOiBbe1xuICAgICAgICAgICAgICBNb3VudFBhdGg6ICcvbW91bnQvcGF0aCcsXG4gICAgICAgICAgICAgIE5hbWU6ICdlbXB0eURpck5hbWUnLFxuICAgICAgICAgICAgICBSZWFkT25seTogZmFsc2UsXG4gICAgICAgICAgICB9XSxcbiAgICAgICAgICB9XSxcbiAgICAgICAgICBWb2x1bWVzOiBbe1xuICAgICAgICAgICAgTmFtZTogJ2VtcHR5RGlyTmFtZScsXG4gICAgICAgICAgICBFbXB0eURpcjoge1xuICAgICAgICAgICAgICBNZWRpdW06ICcnLFxuICAgICAgICAgICAgICBTaXplTGltaXQ6ICcyMDQ4TWknLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9XSxcbiAgICAgICAgfSxcbiAgICAgIH0sXG4gICAgfSk7XG4gIH0pO1xuXG4gIHRlc3QoJ3Jlc3BlY3RzIGFkZFZvbHVtZSgpIHdpdGggaG9zdFBhdGggdm9sdW1lJywgKCkgPT4ge1xuICAgIC8vIEdJVkVOXG4gICAgY29uc3Qgam9iRGVmbiA9IG5ldyBFa3NKb2JEZWZpbml0aW9uKHN0YWNrLCAnRWtzSm9iRGVmbicsIHtcbiAgICAgIGNvbnRhaW5lcjogbmV3IEVrc0NvbnRhaW5lckRlZmluaXRpb24oc3RhY2ssICdFY3NFYzJDb250YWluZXInLCB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G4gICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLFxuICAgICAgICAgIENvbnRhaW5lcnM6IFt7XG4gICAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMuQ29udGFpbmVyc1swXSxcbiAgICAgICAgICAgIFZvbHVtZU1vdW50czogW3tcbiAgICAgICAgICAgICAgTW91bnRQYXRoOiAnL21vdW50L3BhdGgnLFxuICAgICAgICAgICAgICBOYW1lOiAnc2VjcmV0Vm9sdW1lTmFtZScsXG4gICAgICAgICAgICAgIFJlYWRPbmx5OiB0cnVlLFxuICAgICAgICAgICAgfV0sXG4gICAgICAgICAgfV0sXG4gICAgICAgICAgVm9sdW1lczogW3tcbiAgICAgICAgICAgIE5hbWU6ICdzZWNyZXRWb2x1bWVOYW1lJyxcbiAgICAgICAgICAgIFNlY3JldDoge1xuICAgICAgICAgICAgICBTZWNyZXROYW1lOiAnc2VjcmV0TmFtZScsXG4gICAgICAgICAgICAgIE9wdGlvbmFsOiBmYWxzZSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfV0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js new file mode 100644 index 0000000000000..6a75c414d26d2 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js @@ -0,0 +1,72 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const lib_1 = require("../lib"); +test('EcsJobDefinition respects dnsPolicy', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + dnsPolicy: lib_1.DnsPolicy.CLUSTER_FIRST, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + EksProperties: { + PodProperties: { + DnsPolicy: lib_1.DnsPolicy.CLUSTER_FIRST, + }, + }, + }); +}); +test('EcsJobDefinition respects useHostNetwork', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + useHostNetwork: true, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + EksProperties: { + PodProperties: { + HostNetwork: true, + }, + }, + }); +}); +test('EcsJobDefinition respects serviceAccount', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { + container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + serviceAccount: 'my-service-account', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + EksProperties: { + PodProperties: { + ServiceAccountName: 'my-service-account', + }, + }, + }); +}); +test('can be imported from ARN', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + const importedJob = lib_1.EksJobDefinition.fromEksJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); + // THEN + expect(importedJob.jobDefinitionArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWpvYi1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJla3Mtam9iLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsNkNBQW9DO0FBQ3BDLGdDQUE2RTtBQUU3RSxJQUFJLENBQUMscUNBQXFDLEVBQUUsR0FBRyxFQUFFO0lBQy9DLFFBQVE7SUFDUixNQUFNLEtBQUssR0FBRyxJQUFJLG1CQUFLLEVBQUUsQ0FBQztJQUUxQixPQUFPO0lBQ1AsSUFBSSxzQkFBZ0IsQ0FBQyxLQUFLLEVBQUUsWUFBWSxFQUFFO1FBQ3hDLFNBQVMsRUFBRSxJQUFJLDRCQUFzQixDQUFDLEtBQUssRUFBRSxjQUFjLEVBQUU7WUFDM0QsS0FBSyxFQUFFLEdBQUcsQ0FBQyxjQUFjLENBQUMsWUFBWSxDQUFDLDBCQUEwQixDQUFDO1NBQ25FLENBQUM7UUFDRixTQUFTLEVBQUUsZUFBUyxDQUFDLGFBQWE7S0FDbkMsQ0FBQyxDQUFDO0lBRUgsT0FBTztJQUNQLHFCQUFRLENBQUMsU0FBUyxDQUFDLEtBQUssQ0FBQyxDQUFDLHFCQUFxQixDQUFDLDJCQUEyQixFQUFFO1FBQzNFLGFBQWEsRUFBRTtZQUNiLGFBQWEsRUFBRTtnQkFDYixTQUFTLEVBQUUsZUFBUyxDQUFDLGFBQ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fSxcbiAgfSk7XG59KTtcblxudGVzdCgnY2FuIGJlIGltcG9ydGVkIGZyb20gQVJOJywgKCkgPT4ge1xuICAvLyBHSVZFTlxuICBjb25zdCBzdGFjayA9IG5ldyBTdGFjaygpO1xuXG4gIC8vIFdIRU5cbiAgY29uc3QgaW1wb3J0ZWRKb2IgPSBFa3NKb2JEZWZpbml0aW9uLmZyb21Fa3NKb2JEZWZpbml0aW9uQXJuKHN0YWNrLCAnaW1wb3J0ZWRKb2JEZWZpbml0aW9uJyxcbiAgICAnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOmpvYi1kZWZpbml0aW9uL2pvYi1kZWYtbmFtZToxJyk7XG5cbiAgLy8gVEhFTlxuICBleHBlY3QoaW1wb3J0ZWRKb2Iuam9iRGVmaW5pdGlvbkFybikudG9FcXVhbCgnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOmpvYi1kZWZpbml0aW9uL2pvYi1kZWYtbmFtZToxJyk7XG59KTtcblxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js new file mode 100644 index 0000000000000..5d9e85af3e008 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js @@ -0,0 +1,34 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const events = require("aws-cdk-lib/aws-events"); +const targets = require("aws-cdk-lib/aws-events-targets"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const batch = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +const jobQueue = new batch.JobQueue(stack, 'MyQueue', { + computeEnvironments: [ + { + computeEnvironment: new batch.UnmanagedComputeEnvironment(stack, 'ComputeEnvironment'), + order: 1, + }, + ], +}); +const jobDefinition = new batch.EcsJobDefinition(stack, 'MyJob', { + container: new batch.EcsEc2ContainerDefinition(stack, 'container', { + image: aws_ecs_1.ContainerImage.fromRegistry('test-repo'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), +}); +const rule = new events.Rule(stack, 'Rule', { + schedule: events.Schedule.expression('rate(1 minute)'), +}); +rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition)); +new integ.IntegTest(app, 'BatchUniqueNameTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuYmF0Y2gtdW5pcXVlLW5hbWUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbnRlZy5iYXRjaC11bmlxdWUtbmFtZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLGlEQUFxRDtBQUNyRCw2Q0FBK0M7QUFDL0MsaURBQWlEO0FBQ2pELDBEQUEwRDtBQUMxRCxvREFBb0Q7QUFDcEQsZ0NBQWdDO0FBRWhDLE1BQU0sR0FBRyxHQUFHLElBQUksaUJBQUcsRUFBRSxDQUFDO0FBQ3RCLE1BQU0sS0FBSyxHQUFHLElBQUksbUJBQUssQ0FBQyxHQUFHLEVBQUUsT0FBTyxDQUFDLENBQUM7QUFDdEMsTUFBTSxRQUFRLEdBQUcsSUFBSSxLQUFLLENBQUMsUUFBUSxDQUFDLEtBQUssRUFBRSxTQUFTLEVBQUU7SUF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JlcG8nKSxcbiAgICBjcHU6IDI1NixcbiAgICBtZW1vcnk6IFNpemUubWViaWJ5dGVzKDIwNDgpLFxuICB9KSxcbn0pO1xuXG5jb25zdCBydWxlID0gbmV3IGV2ZW50cy5SdWxlKHN0YWNrLCAnUnVsZScsIHtcbiAgc2NoZWR1bGU6IGV2ZW50cy5TY2hlZHVsZS5leHByZXNzaW9uKCdyYXRlKDEgbWludXRlKScpLFxufSk7XG5cbnJ1bGUuYWRkVGFyZ2V0KG5ldyB0YXJnZXRzLkJhdGNoSm9iKFxuICBqb2JRdWV1ZS5qb2JRdWV1ZUFybixcbiAgam9iUXVldWUsXG4gIGpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgam9iRGVmaW5pdGlvbixcbikpO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoVW5pcXVlTmFtZVRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js new file mode 100644 index 0000000000000..acacc540d2191 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js @@ -0,0 +1,94 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); +const efs = require("aws-cdk-lib/aws-efs"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const ssm = require("aws-cdk-lib/aws-ssm"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const batch = require("../lib"); +const aws_ecr_assets_1 = require("aws-cdk-lib/aws-ecr-assets"); +const path = require("path"); +const secretsmanager = require("aws-cdk-lib/aws-secretsmanager"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); +new batch.EcsJobDefinition(stack, 'ECSJobDefn', { + container: new batch.EcsEc2ContainerDefinition(stack, 'myContainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + environment: { + foo: 'bar', + }, + gpu: 12, + volumes: [ + batch.EcsVolume.host({ + name: 'volumeName', + hostPath: '/foo/bar', + containerPath: 'ahhh', + }), + batch.EcsVolume.efs({ + fileSystem: new efs.FileSystem(stack, 'myFileSystem', { + vpc, + }), + name: 'efsVolume', + containerPath: '/my/path', + }), + ], + ulimits: [{ + hardLimit: 50, + name: batch.UlimitName.CORE, + softLimit: 10, + }], + secrets: { + MY_SECRET_ENV_VAR: batch.Secret.fromSecretsManager(new secretsmanager.Secret(stack, 'mySecret')), + ANOTHER_ONE: batch.Secret.fromSecretsManagerVersion(new secretsmanager.Secret(stack, 'anotherSecret'), { + versionId: 'foo', + versionStage: 'bar', + }), + SSM_TIME: batch.Secret.fromSsmParameter(new ssm.StringParameter(stack, 'ssm', { stringValue: 'myString' })), + }, + }), +}); +new batch.EcsJobDefinition(stack, 'ECSFargateJobDefn', { + container: new batch.EcsFargateContainerDefinition(stack, 'myFargateContainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + cpu: 16, + memory: aws_cdk_lib_1.Size.mebibytes(32768), + ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(100), + fargatePlatformVersion: aws_ecs_1.FargatePlatformVersion.LATEST, + }), + jobDefinitionName: 'foofoo', + parameters: { + foo: 'bar', + }, + propagateTags: true, + retryAttempts: 5, + retryStrategies: [ + new batch.RetryStrategy(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER), + new batch.RetryStrategy(batch.Action.RETRY, batch.Reason.NON_ZERO_EXIT_CODE), + new batch.RetryStrategy(batch.Action.EXIT, batch.Reason.custom({ + onExitCode: '40*', + onReason: 'reason', + onStatusReason: 'statusreason', + })), + ], + schedulingPriority: 10, + timeout: aws_cdk_lib_1.Duration.minutes(10), +}); +new batch.EcsJobDefinition(stack, 'ECSDockerJobDefn', { + container: new batch.EcsEc2ContainerDefinition(stack, 'EcsDockerContainer', { + cpu: 16, + memory: aws_cdk_lib_1.Size.mebibytes(32768), + image: ecs.ContainerImage.fromDockerImageAsset(new aws_ecr_assets_1.DockerImageAsset(stack, 'dockerImageAsset', { + directory: path.join(__dirname, 'batchjob-image'), + })), + }), +}); +new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuZWNzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcuZWNzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQTBDO0FBQzFDLGlEQUE2RTtBQUM3RSwyQ0FBMkM7QUFDM0MsMkNBQTJDO0FBQzNDLDJDQUEyQztBQUMzQyw2Q0FBeUQ7QUFDekQsb0RBQW9EO0FBQ3BELGdDQUFnQztBQUNoQywrREFBOEQ7QUFDOUQsNkJBQTZCO0FBQzdCLGlFQUFpRTtBQUVqRSxNQUFNLEdBQUcsR0FBRyxJQUFJLGlCQUFHLEVBQUUsQ0FBQztBQUN0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IGNvbnRhaW5lcjogbmV3IGJhdGNoLkVjc0VjMkNvbnRhaW5lckRlZmluaXRpb24oc3RhY2ssICdFY3NEb2NrZXJDb250YWluZXInLCB7XG4gICAgY3B1OiAxNixcbiAgICBtZW1vcnk6IFNpemUubWViaWJ5dGVzKDMyNzY4KSxcbiAgICBpbWFnZTogZWNzLkNvbnRhaW5lckltYWdlLmZyb21Eb2NrZXJJbWFnZUFzc2V0KG5ldyBEb2NrZXJJbWFnZUFzc2V0KHN0YWNrLCAnZG9ja2VySW1hZ2VBc3NldCcsIHtcbiAgICAgIGRpcmVjdG9yeTogcGF0aC5qb2luKF9fZGlybmFtZSwgJ2JhdGNoam9iLWltYWdlJyksXG4gICAgfSkpLFxuICB9KSxcbn0pO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoRWNzSm9iRGVmaW5pdGlvblRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js new file mode 100644 index 0000000000000..ec09421f64761 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js @@ -0,0 +1,59 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const batch = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +new batch.EksJobDefinition(stack, 'EksJobDefn', { + container: new batch.EksContainerDefinition(stack, 'EksContainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + args: ['foo'], + command: ['echo foo'], + env: { foo: 'bar' }, + cpuLimit: 8, + cpuReservation: 4, + memoryLimit: aws_cdk_lib_1.Size.mebibytes(8192), + memoryReservation: aws_cdk_lib_1.Size.mebibytes(8192), + gpuLimit: 12, + gpuReservation: 12, + imagePullPolicy: batch.ImagePullPolicy.ALWAYS, + name: 'myBigCoolVolume', + privileged: true, + readonlyRootFilesystem: false, + runAsGroup: 1, + runAsRoot: false, + runAsUser: 20, + volumes: [ + batch.EksVolume.emptyDir({ + name: 'woah', + mountPath: '/mount/path', + medium: batch.EmptyDirMediumType.MEMORY, + readonly: true, + sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), + }), + batch.EksVolume.secret({ + name: 'secretVolumeName', + secretName: 'secretName', + mountPath: '/secret/path', + optional: false, + }), + batch.EksVolume.secret({ + name: 'defaultOptionalSettingSecretVolume', + secretName: 'NewSecretName', + mountPath: '/secret/path2', + }), + batch.EksVolume.hostPath({ + name: 'hostPath', + hostPath: '/foo/bar', + mountPath: '/fooasdfadfs', + }), + ], + }), +}); +new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuZWtzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcuZWtzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQXFEO0FBQ3JELDZDQUErQztBQUMvQyxvREFBb0Q7QUFDcEQsZ0NBQWdDO0FBRWhDLE1BQU0sR0FBRyxHQUFHLEl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0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js new file mode 100644 index 0000000000000..96eab371eb46c --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js @@ -0,0 +1,35 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const iam = require("aws-cdk-lib/aws-iam"); +const batch = require("../lib"); +const lib_1 = require("../lib"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); +const queue = new batch.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'managedEc2CE', { + vpc, + }), + order: 1, + }], + priority: 10, +}); +const ecsJob = new batch.EcsJobDefinition(stack, 'ECSJob', { + container: new batch.EcsEc2ContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('foorepo/fooimage'), + }), +}); +const user = new iam.User(stack, 'MyUser'); +ecsJob.grantSubmitJob(user, queue); +new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50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ycsIHsgcmVzdHJpY3REZWZhdWx0U2VjdXJpdHlHcm91cDogZmFsc2UgfSk7XG5cbmNvbnN0IHF1ZXVlID0gbmV3IGJhdGNoLkpvYlF1ZXVlKHN0YWNrLCAnam9CQlEnLCB7XG4gIGNvbXB1dGVFbnZpcm9ubWVudHM6IFt7XG4gICAgY29tcHV0ZUVudmlyb25tZW50OiBuZXcgTWFuYWdlZEVjMkVjc0NvbXB1dGVFbnZpcm9ubWVudChzdGFjaywgJ21hbmFnZWRFYzJDRScsIHtcbiAgICAgIHZwYyxcbiAgICB9KSxcbiAgICBvcmRlcjogMSxcbiAgfV0sXG4gIHByaW9yaXR5OiAxMCxcbn0pO1xuXG5jb25zdCBlY3NKb2IgPSBuZXcgYmF0Y2guRWNzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0VDU0pvYicsIHtcbiAgY29udGFpbmVyOiBuZXcgYmF0Y2guRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICBjcHU6IDI1NixcbiAgICBtZW1vcnk6IFNpemUubWViaWJ5dGVzKDIwNDgpLFxuICAgIGltYWdlOiBlY3MuQ29udGFpbmVySW1hZ2UuZnJvbVJlZ2lzdHJ5KCdmb29yZXBvL2Zvb2ltYWdlJyksXG4gIH0pLFxufSk7XG5cbmNvbnN0IHVzZXIgPSBuZXcgaWFtLlVzZXIoc3RhY2ssICdNeVVzZXInKTtcbmVjc0pvYi5ncmFudFN1Ym1pdEpvYih1c2VyLCBxdWV1ZSk7XG5cbm5ldyBpbnRlZy5JbnRlZ1Rlc3QoYXBwLCAnQmF0Y2hFY3NKb2JEZWZpbml0aW9uVGVzdCcsIHtcbiAgdGVzdENhc2VzOiBbc3RhY2tdLFxufSk7XG5cbmFwcC5zeW50aCgpO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js new file mode 100644 index 0000000000000..5798e3b70f7e9 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js @@ -0,0 +1,41 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const batch = require("../lib"); +const lib_1 = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); +const fairsharePolicy = new batch.FairshareSchedulingPolicy(stack, 'fairshare', { + computeReservation: 75, + schedulingPolicyName: 'joBBQFairsharePolicy', + shareDecay: aws_cdk_lib_1.Duration.hours(1), + shares: [{ + shareIdentifier: 'shareA', + weightFactor: 0.5, + }], +}); +const queue = new batch.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'managedEc2CE', { + vpc, + }), + order: 1, + }], + priority: 10, + schedulingPolicy: fairsharePolicy, +}); +fairsharePolicy.addShare({ + shareIdentifier: 'shareB', + weightFactor: 7, +}); +queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'newManagedEc2CE', { + vpc, +}), 2); +new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuam9iLXF1ZXVlLmpzIiwic291cmNlUm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RoKCk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js new file mode 100644 index 0000000000000..29a0fed0681b9 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js @@ -0,0 +1,78 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const lib_1 = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'batch-stack'); +const vpc = new ec2.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); +new lib_1.FargateComputeEnvironment(stack, 'minimalPropsFargate', { + vpc, + maxvCpus: 512, +}); +new lib_1.FargateComputeEnvironment(stack, 'maximalPropsFargate', { + vpc, + maxvCpus: 512, + computeEnvironmentName: 'maxPropsFargateCE', + replaceComputeEnvironment: true, + spot: true, + terminateOnUpdate: true, + updateTimeout: aws_cdk_lib_1.Duration.minutes(30), + updateToLatestImageVersion: false, +}); +new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'minimalPropsEc2', { + vpc, + images: [{ + image: new ec2.AmazonLinuxImage(), + }], +}); +new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'LaunchTemplate', { + vpc, + images: [{ + image: new ec2.AmazonLinuxImage(), + }], + allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, + minvCpus: 256, + maxvCpus: 512, + replaceComputeEnvironment: true, + terminateOnUpdate: false, + placementGroup: new ec2.PlacementGroup(stack, 'placementGroup'), + updateTimeout: aws_cdk_lib_1.Duration.hours(1), + launchTemplate: new aws_ec2_1.LaunchTemplate(stack, 'launchTemplate'), +}); +new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SpotEc2', { + vpc, + images: [{ + image: new ec2.AmazonLinuxImage(), + }], + spot: true, + spotBidPercentage: 95, + spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { + assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), + }), +}); +new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'AllocationStrategySPOT_CAPACITY', { + vpc, + images: [{ + image: new ec2.AmazonLinuxImage(), + }], + spot: true, + spotBidPercentage: 95, + allocationStrategy: lib_1.AllocationStrategy.SPOT_CAPACITY_OPTIMIZED, +}); +const taggedEc2Ecs = new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'taggedCE', { + vpc, + images: [{ + image: new ec2.AmazonLinuxImage(), + }], +}); +aws_cdk_lib_1.Tags.of(taggedEc2Ecs).add('foo', 'bar'); +aws_cdk_lib_1.Tags.of(taggedEc2Ecs).add('super', 'salamander'); +new integ.IntegTest(app, 'BatchManagedComputeEnvironmentTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcubWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcubWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsMkNBQTJDO0FBQzNDLGlEQUFxRDtBQUNyRCxpREFBNkQ7QUFDN0QsNkNBQXlEO0FBQ3pELG9EQUFvR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IE1hbmFnZWRFYzJFY3NDb21wdXRlRW52aXJvbm1lbnQoc3RhY2ssICdBbGxvY2F0aW9uU3RyYXRlZ3lTUE9UX0NBUEFDSVRZJywge1xuICB2cGMsXG4gIGltYWdlczogW3tcbiAgICBpbWFnZTogbmV3IGVjMi5BbWF6b25MaW51eEltYWdlKCksXG4gIH1dLFxuICBzcG90OiB0cnVlLFxuICBzcG90QmlkUGVyY2VudGFnZTogOTUsXG4gIGFsbG9jYXRpb25TdHJhdGVneTogQWxsb2NhdGlvblN0cmF0ZWd5LlNQT1RfQ0FQQUNJVFlfT1BUSU1JWkVELFxufSk7XG5cbmNvbnN0IHRhZ2dlZEVjMkVjcyA9IG5ldyBNYW5hZ2VkRWMyRWNzQ29tcHV0ZUVudmlyb25tZW50KHN0YWNrLCAndGFnZ2VkQ0UnLCB7XG4gIHZwYyxcbiAgaW1hZ2VzOiBbe1xuICAgIGltYWdlOiBuZXcgZWMyLkFtYXpvbkxpbnV4SW1hZ2UoKSxcbiAgfV0sXG59KTtcblxuVGFncy5vZih0YWdnZWRFYzJFY3MpLmFkZCgnZm9vJywgJ2JhcicpO1xuVGFncy5vZih0YWdnZWRFYzJFY3MpLmFkZCgnc3VwZXInLCAnc2FsYW1hbmRlcicpO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoTWFuYWdlZENvbXB1dGVFbnZpcm9ubWVudFRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js new file mode 100644 index 0000000000000..5c3d60fee788b --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js @@ -0,0 +1,48 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const batch = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'stack'); +new batch.MultiNodeJobDefinition(stack, 'SingleContainerMultiNodeJob', { + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + containers: [{ + startNode: 0, + endNode: 10, + container: new batch.EcsEc2ContainerDefinition(stack, 'myContainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }], + propagateTags: true, +}); +const multinodeJob = new batch.MultiNodeJobDefinition(stack, 'MultiContainerMultiNodeJob', { + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + containers: [{ + startNode: 0, + endNode: 10, + container: new batch.EcsEc2ContainerDefinition(stack, 'multinodecontainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), + }], +}); +multinodeJob.addContainer({ + startNode: 11, + endNode: 20, + container: new batch.EcsEc2ContainerDefinition(stack, 'multiContainer', { + image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + }), +}); +new integ.IntegTest(app, 'Bat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Jywge1xuICB0ZXN0Q2FzZXM6IFtzdGFja10sXG59KTtcblxuYXBwLnN5bnRoKCk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js new file mode 100644 index 0000000000000..55a17c9cfbbe7 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js @@ -0,0 +1,25 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const integ = require("@aws-cdk/integ-tests-alpha"); +const lib_1 = require("../lib"); +const app = new aws_cdk_lib_1.App(); +const stack = new aws_cdk_lib_1.Stack(app, 'batch-stack'); +new lib_1.UnmanagedComputeEnvironment(stack, 'minimalProps'); +new lib_1.UnmanagedComputeEnvironment(stack, 'maximalProps', { + computeEnvironmentName: 'unmanagedIntegTestCE', + enabled: true, + unmanagedvCpus: 256, + serviceRole: new aws_iam_1.Role(stack, 'IntegServiceRole', { + managedPolicies: [ + aws_iam_1.ManagedPolicy.fromAwsManagedPolicyName('service-role/AWSBatchServiceRole'), + ], + assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), + }), +}); +new integ.IntegTest(app, 'BatchManagedComputeEnvironmentTest', { + testCases: [stack], +}); +app.synth(); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcudW5tYW5hZ2VkLWNvbXB1dGUtZ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WNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js new file mode 100644 index 0000000000000..5a3ad995469b0 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js @@ -0,0 +1,205 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const utils_1 = require("./utils"); +const batch = require("../lib"); +const defaultExpectedEcsProps = { + type: 'container', + platformCapabilities: [batch.Compatibility.EC2], +}; +const defaultExpectedEksProps = { + type: 'container', +}; +const defaultExpectedMultiNodeProps = { + type: 'multinode', +}; +let stack; +let pascalCaseExpectedEcsProps; +let pascalCaseExpectedEksProps; +let pascalCaseExpectedMultiNodeProps; +let defaultEcsProps; +let defaultEksProps; +let defaultMultiNodeProps; +let expectedProps; +let defaultProps; +describe.each([batch.EcsJobDefinition, batch.EksJobDefinition, batch.MultiNodeJobDefinition])('%p type JobDefinition', (JobDefinition) => { + // GIVEN + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); + pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); + pascalCaseExpectedMultiNodeProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedMultiNodeProps); + defaultEcsProps = { + container: new batch.EcsEc2ContainerDefinition(stack, 'EcsContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + }; + defaultEksProps = { + container: new batch.EksContainerDefinition(stack, 'EksContainer', { + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + }; + defaultMultiNodeProps = { + containers: [{ + container: new batch.EcsEc2ContainerDefinition(stack, 'MultinodeEcsContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 0, + endNode: 10, + }], + mainNode: 0, + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + }; + switch (JobDefinition) { + case batch.EcsJobDefinition: + expectedProps = pascalCaseExpectedEcsProps; + defaultProps = defaultEcsProps; + break; + case batch.EksJobDefinition: + expectedProps = pascalCaseExpectedEksProps; + defaultProps = defaultEksProps; + break; + case batch.MultiNodeJobDefinition: + expectedProps = pascalCaseExpectedMultiNodeProps; + defaultProps = defaultMultiNodeProps; + break; + } + }); + test('JobDefinition respects name', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + jobDefinitionName: 'myEcsJob', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + JobDefinitionName: 'myEcsJob', + }); + }); + test('JobDefinition respects parameters', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + parameters: { + foo: 'bar', + }, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + Parameters: { + foo: 'bar', + }, + }); + }); + test('JobDefinition respects retryAttempts', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + retryAttempts: 8, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + RetryStrategy: { + Attempts: 8, + }, + }); + }); + test('JobDefinition respects retryStrategies', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + retryStrategies: [ + batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER), + batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.NON_ZERO_EXIT_CODE), + batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.SPOT_INSTANCE_RECLAIMED), + batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.custom({ + onExitCode: '40*', + onReason: 'reason*', + onStatusReason: 'statusReason', + })), + ], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + RetryStrategy: { + EvaluateOnExit: [ + { + Action: 'EXIT', + OnReason: 'CannotPullContainerError:*', + }, + { + Action: 'RETRY', + OnExitCode: '*', + }, + { + Action: 'RETRY', + OnStatusReason: 'Host EC2*', + }, + { + Action: 'RETRY', + OnExitCode: '40*', + OnReason: 'reason*', + OnStatusReason: 'statusReason', + }, + ], + }, + }); + }); + test('JobDefinition respects schedulingPriority', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + schedulingPriority: 10, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + SchedulingPriority: 10, + }); + }); + test('JobDefinition respects schedulingPriority', () => { + // WHEN + new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + timeout: aws_cdk_lib_1.Duration.minutes(10), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + Timeout: { + AttemptDurationSeconds: 600, + }, + }); + }); + test('JobDefinition respects addRetryStrategy()', () => { + // WHEN + const jobDefn = new JobDefinition(stack, 'JobDefn', { + ...defaultProps, + }); + jobDefn.addRetryStrategy(batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.SPOT_INSTANCE_RECLAIMED)); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + ...expectedProps, + RetryStrategy: { + EvaluateOnExit: [ + { + Action: 'RETRY', + OnStatusReason: 'Host EC2*', + }, + ], + }, + }); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLWRlZmluaXRpb24tYmFzZS50ZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiam9iLWRlZmluaXRpb24tYmFzZS50ZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsdURBQWtEO0FBQ2xELGlEQUFnRjtBQUNoRiwyQ0FBMkM7QUFDM0MsNkNBQTZEO0FBQzdELG1DQUFrRDtBQUNsRCxnQ0FBZ0M7QUFHaEMsTUFBTSx1QkFBdUIsR0FBMEI7SUFDckQsSUFBSSxFQUFFLFdBQVc7SUFDakIsb0JBQW9CLEVBQUUsQ0FBQyxLQUFLLENBQUMsYUFBYSxDQUFDLEdBQUcsQ0FBQztDQUNoRCxDQUFDO0FBQ0YsTUFBTSx1QkFBdUIsR0FBMEI7SUFDckQsSUFBSSxFQUFFLFdBQVc7Q0FDbEIsQ0FBQztBQUNGLE1BQU0sNkJBQTZCLEdBQTBCO0lBQzNELElBQUksRUFBRSxXQUFXO0NBQ2xCLENBQUM7QUFFRixJQUFJLEtBQVksQ0FBQztBQUVqQixJQUFJLDBCQUErQixDQUFDO0FBQ3BDLElBQUksMEJBQStCLENBQUM7QUFDcEMsSUFBSSxnQ0FBcUMsQ0FBQztBQUUxQyxJQUFJLGVBQTRDLENBQUM7QUFDakQsSUFBSSxlQUE0QyxDQUFDO0FBQ2pELElBQUkscUJBQXdELENBQUM7QUFFN0QsSUFBSSxhQUFrQixDQUFDO0FBQ3ZCLEl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ICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdFWElUJyxcbiAgICAgICAgICAgIE9uUmVhc29uOiAnQ2Fubm90UHVsbENvbnRhaW5lckVycm9yOionLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25FeGl0Q29kZTogJyonLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25TdGF0dXNSZWFzb246ICdIb3N0IEVDMionLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25FeGl0Q29kZTogJzQwKicsXG4gICAgICAgICAgICBPblJlYXNvbjogJ3JlYXNvbionLFxuICAgICAgICAgICAgT25TdGF0dXNSZWFzb246ICdzdGF0dXNSZWFzb24nLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdKb2JEZWZpbml0aW9uIHJlc3BlY3RzIHNjaGVkdWxpbmdQcmlvcml0eScsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEpvYkRlZmluaXRpb24oc3RhY2ssICdKb2JEZWZuJywge1xuICAgICAgLi4uZGVmYXVsdFByb3BzLFxuICAgICAgc2NoZWR1bGluZ1ByaW9yaXR5OiAxMCxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLmV4cGVjdGVkUHJvcHMsXG4gICAgICBTY2hlZHVsaW5nUHJpb3JpdHk6IDEwLFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdKb2JEZWZpb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ZU9uRXhpdDogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIEFjdGlvbjogJ1JFVFJZJyxcbiAgICAgICAgICAgIE9uU3RhdHVzUmVhc29uOiAnSG9zdCBFQzIqJyxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js new file mode 100644 index 0000000000000..b15482f2d3cc1 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js @@ -0,0 +1,228 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const lib_1 = require("../lib"); +test('JobQueue respects computeEnvironments', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + new lib_1.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { + vpc, + }), + order: 1, + }], + priority: 10, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { + ComputeEnvironmentOrder: [{ + ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, + Order: 1, + }], + Priority: 10, + State: 'ENABLED', + }); +}); +test('JobQueue respects enabled', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + new lib_1.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { + vpc, + }), + order: 1, + }], + priority: 10, + enabled: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { + ComputeEnvironmentOrder: [{ + ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, + Order: 1, + }], + Priority: 10, + State: 'DISABLED', + }); +}); +test('JobQueue respects name', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + new lib_1.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { + vpc, + }), + order: 1, + }], + priority: 10, + jobQueueName: 'JoBBQ', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { + ComputeEnvironmentOrder: [{ + ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, + Order: 1, + }], + Priority: 10, + JobQueueName: 'JoBBQ', + }); +}); +test('JobQueue name is parsed from arn', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + const queue = new lib_1.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { + vpc, + }), + order: 1, + }], + priority: 10, + jobQueueName: 'JoBBQ', + }); + // THEN + expect(aws_cdk_lib_1.Tokenization.resolve(queue.jobQueueName, { + scope: stack, + resolver: new aws_cdk_lib_1.DefaultTokenResolver(new aws_cdk_lib_1.StringConcat()), + })).toEqual({ + 'Fn::Select': [ + 1, + { + 'Fn::Split': [ + '/', + { + 'Fn::Select': [ + 5, + { + 'Fn::Split': [ + ':', + { + 'Fn::GetAtt': [ + 'joBBQ9FD52DAF', + 'JobQueueArn', + ], + }, + ], + }, + ], + }, + ], + }, + ], + }); +}); +test('JobQueue respects schedulingPolicy', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + new lib_1.JobQueue(stack, 'JobQueue', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { + vpc, + }), + order: 1, + }], + priority: 10, + schedulingPolicy: new lib_1.FairshareSchedulingPolicy(stack, 'FairsharePolicy'), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { + ComputeEnvironmentOrder: [{ + ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, + Order: 1, + }], + Priority: 10, + SchedulingPolicyArn: { + 'Fn::GetAtt': ['FairsharePolicyA0C549BE', 'Arn'], + }, + }); +}); +test('JobQueue respects addComputeEnvironment', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + const queue = new lib_1.JobQueue(stack, 'JobQueue', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'FirstCE', { + vpc, + }), + order: 1, + }], + priority: 10, + schedulingPolicy: new lib_1.FairshareSchedulingPolicy(stack, 'FairsharePolicy'), + }); + queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SecondCE', { + vpc, + }), 2); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { + ComputeEnvironmentOrder: [ + { + ComputeEnvironment: { 'Fn::GetAtt': ['FirstCEAD3794AD', 'ComputeEnvironmentArn'] }, + Order: 1, + }, + { + ComputeEnvironment: { 'Fn::GetAtt': ['SecondCEEBA93938', 'ComputeEnvironmentArn'] }, + Order: 2, + }, + ], + Priority: 10, + SchedulingPolicyArn: { + 'Fn::GetAtt': ['FairsharePolicyA0C549BE', 'Arn'], + }, + }); +}); +test('can be imported from ARN', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + const queue = lib_1.JobQueue.fromJobQueueArn(stack, 'importedJobQueue', 'arn:aws:batch:us-east-1:123456789012:job-queue/importedJobQueue'); + // THEN + expect(queue.jobQueueArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-queue/importedJobQueue'); +}); +test('JobQueue throws when the same order is assigned to multiple ComputeEnvironments', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + const vpc = new ec2.Vpc(stack, 'vpc'); + // WHEN + const joBBQ = new lib_1.JobQueue(stack, 'joBBQ', { + computeEnvironments: [{ + computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'FirstCE', { + vpc, + }), + order: 1, + }], + priority: 10, + }); + joBBQ.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SecondCE', { + vpc, + }), 1); + expect(() => { + assertions_1.Template.fromStack(stack); + }).toThrow(/assigns the same order to different ComputeEnvironments/); +}); +test('JobQueue throws when there are no linked ComputeEnvironments', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.JobQueue(stack, 'joBBQ'); + expect(() => { + assertions_1.Template.fromStack(stack); + }).toThrow(/This JobQueue does not link any ComputeEnvironments/); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLXF1ZXVlLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJqb2ItcXVldWUudGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCw2Q0FBc0Y7QUFDdEYsMkNBQTJDO0FBQzNDLGdDQUE4RjtBQUU5RixJQUFJLENB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biAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICA1LFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICAgICAgICAgJ2pvQkJROUZENTJEQUYnLFxuICAgICAgICAgICAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIF0sXG4gIH0pO1xufSk7XG5cbnRlc3QoJ0pvYlF1ZXVlIHJlc3BlY3RzIHNjaGVkdWxpbmdQb2xpY3knLCAoKSA9PiB7XG4gIC8vIEdJVkVOXG4gIGNvbnN0IHN0YWNrID0gbmV3IFN0YWNrKCk7XG4gIGNvbnN0IHZwYyA9IG5ldyBlYzIuVnBjKHN0YWNrLCAndnBjJyk7XG5cbiAgLy8gV0hFTlxuICBuZXcgSm9iUXVldWUoc3RhY2ssICdKb2JRdWV1ZScsIHtcbiAgICBjb21wdXRlRW52aXJvbm1lbnRzOiBbe1xuICAgICAgY29tcHV0ZUVudmlyb25tZW50OiBuZXcgTWFuYWdlZEVjMkVjc0NvbXB1dGVFbnZpcm9ubWVudChzdGFjaywgJ0NFJywge1xuICAgICAgICB2cGMsXG4gICAgICB9KSxcbiAgICAgIG9yZGVyOiAxLFxuICAgIH1dLFxuICAgIHByaW9yaXR5OiAxMCxcbiAgICBzY2hlZHVsaW5nUG9saWN5OiBuZXcgRmFpcnNoYXJlU2NoZWR1bGluZ1BvbGljeShzdGFjaywgJ0ZhaXJzaGFyZVBvbGlje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VjdCgoKSA9PiB7XG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKTtcbiAgfSkudG9UaHJvdygvYXNzaWducyB0aGUgc2FtZSBvcmRlciB0byBkaWZmZXJlbnQgQ29tcHV0ZUVudmlyb25tZW50cy8pO1xufSk7XG5cbnRlc3QoJ0pvYlF1ZXVlIHRocm93cyB3aGVuIHRoZXJlIGFyZSBubyBsaW5rZWQgQ29tcHV0ZUVudmlyb25tZW50cycsICgpID0+IHtcbiAgLy8gR0lWRU5cbiAgY29uc3Qgc3RhY2sgPSBuZXcgU3RhY2soKTtcblxuICAvLyBXSEVOXG4gIG5ldyBKb2JRdWV1ZShzdGFjaywgJ2pvQkJRJyk7XG5cbiAgZXhwZWN0KCgpID0+IHtcbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spO1xuICB9KS50b1Rocm93KC9UaGlzIEpvYlF1ZXVlIGRvZXMgbm90IGxpbmsgYW55IENvbXB1dGVFbnZpcm9ubWVudHMvKTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js new file mode 100644 index 0000000000000..012dc0b22f7ed --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js @@ -0,0 +1,860 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const ec2 = require("aws-cdk-lib/aws-ec2"); +const eks = require("aws-cdk-lib/aws-eks"); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const utils_1 = require("./utils"); +const batch = require("../lib"); +const lib_1 = require("../lib"); +const defaultExpectedEcsProps = { + type: 'managed', + computeEnvironmentName: undefined, + serviceRole: undefined, + state: 'ENABLED', + eksConfiguration: undefined, + computeResources: { + allocationStrategy: lib_1.AllocationStrategy.BEST_FIT_PROGRESSIVE, + bidPercentage: undefined, + desiredvCpus: undefined, + maxvCpus: 256, + type: 'EC2', + ec2Configuration: undefined, + minvCpus: 0, + subnets: [ + { Ref: 'vpcPrivateSubnet1Subnet934893E8' }, + { Ref: 'vpcPrivateSubnet2Subnet7031C2BA' }, + ], + ec2KeyPair: undefined, + imageId: undefined, + instanceRole: { 'Fn::GetAtt': ['MyCEInstanceProfile6D69963F', 'Arn'] }, + instanceTypes: ['optimal'], + launchTemplate: undefined, + placementGroup: undefined, + securityGroupIds: [{ + 'Fn::GetAtt': ['MyCESecurityGroup81DCAA06', 'GroupId'], + }], + spotIamFleetRole: undefined, + updateToLatestImageVersion: true, + }, + replaceComputeEnvironment: false, +}; +const defaultExpectedEksProps = { + ...defaultExpectedEcsProps, + eksConfiguration: { + eksClusterArn: { + 'Fn::GetAtt': ['eksTestCluster1B416C0E', 'Arn'], + }, + kubernetesNamespace: 'cdk-test-namespace', + }, +}; +let stack; +let vpc; +let pascalCaseExpectedEcsProps; +let pascalCaseExpectedEksProps; +let defaultComputeResources; +let defaultEcsProps; +let defaultEksProps; +let expectedProps; +let defaultProps; +describe.each([lib_1.ManagedEc2EcsComputeEnvironment, lib_1.ManagedEc2EksComputeEnvironment])('%p type ComputeEnvironment', (ComputeEnvironment) => { + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + vpc = new ec2.Vpc(stack, 'vpc'); + pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); + pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); + defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; + defaultEcsProps = { + vpc, + }; + defaultEksProps = { + vpc, + kubernetesNamespace: 'cdk-test-namespace', + eksCluster: new eks.Cluster(stack, 'eksTestCluster', { + version: eks.KubernetesVersion.V1_24, + }), + }; + expectedProps = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment + ? pascalCaseExpectedEcsProps + : pascalCaseExpectedEksProps; + defaultProps = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment + ? defaultEcsProps + : defaultEksProps; + }); + test('default props', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::InstanceProfile', { + Roles: [{ Ref: 'MyCEInstanceProfileRole895D248D' }], + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + AssumeRolePolicyDocument: { + Statement: [{ + Action: 'sts:AssumeRole', + Effect: 'Allow', + Principal: { Service: 'ec2.amazonaws.com' }, + }], + Version: '2012-10-17', + }, + }); + }); + test('can specify maxvCpus', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + maxvCpus: 512, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + MaxvCpus: 512, + }, + }); + }); + test('can specify minvCpus', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + minvCpus: 8, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + MinvCpus: 8, + }, + }); + }); + test('can be disabled', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + enabled: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + State: 'DISABLED', + }); + }); + test('spot => AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spot: true, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + Type: 'SPOT', + AllocationStrategy: 'SPOT_PRICE_CAPACITY_OPTIMIZED', + }, + }); + }); + test('images are correctly rendered as EC2ConfigurationObjects', () => { + const expectedImageType = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment + ? batch.EcsMachineImageType.ECS_AL2 + : batch.EksMachineImageType.EKS_AL2; + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + images: [ + { + image: ec2.MachineImage.latestAmazonLinux2(), + }, + ], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + Ec2Configuration: [ + { + ImageIdOverride: { Ref: 'SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amikernel510hvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter' }, + ImageType: expectedImageType, + }, + ], + }, + }); + }); + test('instance classes are correctly rendered', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + instanceClasses: [ec2.InstanceClass.R4], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + InstanceTypes: [ + 'r4', + 'optimal', + ], + }, + }); + }); + test('instance types are correctly rendered', () => { + // WHEN + const ce = new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE)], + }); + ce.addInstanceClass(ec2.InstanceClass.M4); + ce.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.C4, ec2.InstanceSize.LARGE)); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + InstanceTypes: [ + 'r4.large', + 'c4.large', + 'm4', + 'optimal', + ], + }, + }); + }); + test('respects useOptimalInstanceClasses: false', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + useOptimalInstanceClasses: false, + instanceClasses: [ec2.InstanceClass.R4], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + InstanceTypes: [ + 'r4', + ], + }, + }); + }); + test('does not throw with useOptimalInstanceClasses: false and a call to addInstanceClass()', () => { + // WHEN + const myCE = new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + useOptimalInstanceClasses: false, + }); + myCE.addInstanceClass(ec2.InstanceClass.C4); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + InstanceTypes: [ + 'c4', + ], + }, + }); + }); + test('does not throw with useOptimalInstanceClasses: false and a call to addInstanceType()', () => { + // WHEN + const myCE = new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + useOptimalInstanceClasses: false, + }); + myCE.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.C4, ec2.InstanceSize.XLARGE112)); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + InstanceTypes: [ + 'c4.112xlarge', + ], + }, + }); + }); + test('creates and uses instanceProfile, even when instanceRole is specified', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + instanceRole: new aws_iam_1.Role(stack, 'myRole', { + assumedBy: new aws_iam_1.ServicePrincipal('foo.amazonaws.com', { + region: 'bermuda-triangle-1337', + }), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + // instanceRole is unchanged from default + }, + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::InstanceProfile', { + Roles: [{ Ref: 'myRoleE60D68E8' }], + }); + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + AssumeRolePolicyDocument: { + Statement: [{ + Action: 'sts:AssumeRole', + Effect: 'Allow', + Principal: { Service: 'foo.amazonaws.com' }, + }], + Version: '2012-10-17', + }, + }); + }); + test('respects launch template', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + launchTemplate: new ec2.LaunchTemplate(stack, 'launchTemplate'), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + LaunchTemplate: { + LaunchTemplateId: { Ref: 'launchTemplateDEE5742D' }, + }, + }, + }); + }); + test('respects name', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + computeEnvironmentName: 'NamedCE', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeEnvironmentName: 'NamedCE', + ComputeResources: { + ...defaultComputeResources, + }, + }); + }); + test('respects placement group', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + placementGroup: new ec2.PlacementGroup(stack, 'myPlacementGroup'), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + PlacementGroup: { + 'Fn::GetAtt': ['myPlacementGroup2E94D14E', 'GroupName'], + }, + }, + }); + }); + test('respects replaceComputeEnvironment', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + replaceComputeEnvironment: true, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + }, + ReplaceComputeEnvironment: true, + }); + }); + test('respects security groups', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + securityGroups: [new ec2.SecurityGroup(stack, 'TestSG', { + vpc, + allowAllOutbound: false, + })], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + SecurityGroupIds: [{ + 'Fn::GetAtt': ['TestSG581D3391', 'GroupId'], + }], + }, + }); + }); + test('respects service role', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + serviceRole: new aws_iam_1.Role(stack, 'TestSLR', { + assumedBy: new aws_iam_1.ServicePrincipal('cdk.amazonaws.com'), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ServiceRole: { + 'Fn::GetAtt': ['TestSLR05974C22', 'Arn'], + }, + ComputeResources: { + ...defaultComputeResources, + }, + }); + }); + test('respects vpcSubnets', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpcSubnets: { + subnets: [new ec2.Subnet(stack, 'testSubnet', { + availabilityZone: 'az-3', + cidrBlock: '10.0.0.0/32', + vpcId: new ec2.Vpc(stack, 'subnetVpc').vpcId, + })], + }, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + Subnets: [ + { Ref: 'testSubnet42F0FA0C' }, + ], + }, + }); + }); + test('respects updateTimeout', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + updateTimeout: aws_cdk_lib_1.Duration.minutes(1), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + }, + UpdatePolicy: { + JobExecutionTimeoutMinutes: 1, + }, + }); + }); + test('respects terminateOnUpdate', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + terminateOnUpdate: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + }, + UpdatePolicy: { + TerminateJobsOnUpdate: false, + }, + }); + }); + test('respects updateToLatestImageVersion', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + updateToLatestImageVersion: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + UpdateToLatestImageVersion: false, + }, + }); + }); + test('respects tags', () => { + // WHEN + const ce = new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + }); + aws_cdk_lib_1.Tags.of(ce).add('superfood', 'acai'); + aws_cdk_lib_1.Tags.of(ce).add('super', 'salamander'); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...expectedProps, + ComputeResources: { + ...defaultComputeResources, + Tags: { + superfood: 'acai', + super: 'salamander', + }, + }, + }); + }); + test('can be imported from arn', () => { + // WHEN + const ce = lib_1.ManagedEc2EcsComputeEnvironment.fromManagedEc2EcsComputeEnvironmentArn(stack, 'import', 'arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); + // THEN + expect(ce.computeEnvironmentArn).toEqual('arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); + }); + test('attach necessary managed policy to instance role', () => { + // WHEN + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { + ManagedPolicyArns: [ + { + 'Fn::Join': [ + '', + [ + 'arn:', + { + Ref: 'AWS::Partition', + }, + ':iam::aws:policy/service-role/AmazonEC2ContainerServiceforEC2Role', + ], + ], + }, + ], + }); + }); + test('throws when no instance types are provided', () => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + useOptimalInstanceClasses: false, + vpc, + }); + expect(() => { + assertions_1.Template.fromStack(stack); + }).toThrow(/Specifies 'useOptimalInstanceClasses: false' without specifying any instance types or classes/); + }); + test('throws error when AllocationStrategy.SPOT_CAPACITY_OPTIMIZED is used without specfiying spot', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + allocationStrategy: lib_1.AllocationStrategy.SPOT_CAPACITY_OPTIMIZED, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'AllocationStrategy.SPOT_CAPACITY_OPTIMIZED' without using spot instances/); + }); + test('throws error when AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED is used without specfiying spot', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + allocationStrategy: lib_1.AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED' without using spot instances/); + }); + test('throws error when spotBidPercentage is specified without spot', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spotBidPercentage: 80, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' without specifying 'spot'/); + }); + test('throws error when spotBidPercentage is specified and spot is false', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spotBidPercentage: 80, + spot: false, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' without specifying 'spot'/); + }); + test('throws error when spotBidPercentage > 100', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spotBidPercentage: 120, + spot: true, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' > 100/); + }); + test('throws error when spotBidPercentage < 0', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spotBidPercentage: -120, + spot: true, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' < 0/); + }); + test('throws error when minvCpus > maxvCpus', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + maxvCpus: 512, + minvCpus: 1024, + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' has 'minvCpus' = 1024 > 'maxvCpus' = 512; 'minvCpus' cannot be greater than 'maxvCpus'/); + }); + test('throws error when minvCpus < 0', () => { + // THEN + expect(() => { + new ComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + minvCpus: -256, + }); + }).toThrowError(/Managed ComputeEnvironment 'MyCE' has 'minvCpus' = -256 < 0; 'minvCpus' cannot be less than zero/); + }); +}); +describe('ManagedEc2EcsComputeEnvironment', () => { + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + vpc = new ec2.Vpc(stack, 'vpc'); + pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); + pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); + defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; + defaultEcsProps = { + vpc, + }; + defaultEksProps = { + vpc, + kubernetesNamespace: 'cdk-test-namespace', + eksCluster: new eks.Cluster(stack, 'eksTestCluster', { + version: eks.KubernetesVersion.V1_24, + }), + }; + }); + test('respects spotFleetRole', () => { + // WHEN + new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { + ...defaultEcsProps, + spot: true, + spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { + assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:magicuser/foobar'), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEcsProps, + ComputeResources: { + ...defaultComputeResources, + AllocationStrategy: lib_1.AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED, + Type: 'SPOT', + SpotIamFleetRole: { + 'Fn::GetAtt': ['SpotFleetRole6D4F7558', 'Arn'], + }, + }, + }); + }); + test('image types are correctly rendered as EC2ConfigurationObjects', () => { + // WHEN + new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { + ...defaultEcsProps, + vpc, + images: [ + { + imageType: batch.EcsMachineImageType.ECS_AL2_NVIDIA, + }, + ], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEcsProps, + ComputeResources: { + ...defaultComputeResources, + Ec2Configuration: [ + { + ImageType: 'ECS_AL2_NVIDIA', + }, + ], + }, + }); + }); + test('can use non-default allocation strategy', () => { + // WHEN + new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEcsProps, + ComputeResources: { + ...defaultComputeResources, + AllocationStrategy: 'BEST_FIT', + }, + }); + }); + test('spot and AllocationStrategy.BEST_FIT => a default spot fleet role is created', () => { + // WHEN + new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + vpc, + spot: true, + allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEcsProps, + ComputeResources: { + ...defaultComputeResources, + Type: 'SPOT', + AllocationStrategy: 'BEST_FIT', + SpotIamFleetRole: { 'Fn::GetAtt': ['MyCESpotFleetRole70BE30A0', 'Arn'] }, + }, + }); + }); + test('throws when spotFleetRole is specified without spot', () => { + // WHEN + expect(() => { + new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { + ...defaultEcsProps, + spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { + assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:magicuser/foobar'), + }), + }); + }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotFleetRole' without specifying 'spot'/); + }); +}); +describe('ManagedEc2EksComputeEnvironment', () => { + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + vpc = new ec2.Vpc(stack, 'vpc'); + pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); + pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); + defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; + defaultEcsProps = { + vpc, + }; + defaultEksProps = { + vpc, + kubernetesNamespace: 'cdk-test-namespace', + eksCluster: new eks.Cluster(stack, 'eksTestCluster', { + version: eks.KubernetesVersion.V1_24, + }), + }; + }); + test('default props', () => { + // WHEN + new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { + ...defaultEksProps, + vpc, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEksProps, + ComputeResources: { + ...defaultComputeResources, + }, + }); + }); + test('throws error when AllocationStrategy.BEST_FIT is used', () => { + // THEN + expect(() => { + new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { + ...defaultProps, + allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, + }); + }).toThrow(/ManagedEc2EksComputeEnvironment 'MyCE' uses invalid allocation strategy 'AllocationStrategy.BEST_FIT'/); + }); + test('image types are correctly rendered as EC2ConfigurationObjects', () => { + // WHEN + new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { + ...defaultEksProps, + vpc, + images: [ + { + imageType: batch.EksMachineImageType.EKS_AL2_NVIDIA, + }, + ], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedEksProps, + ComputeResources: { + ...defaultComputeResources, + Ec2Configuration: [ + { + ImageType: 'EKS_AL2_NVIDIA', + }, + ], + }, + }); + }); +}); +describe('FargateComputeEnvironment', () => { + beforeEach(() => { + stack = new aws_cdk_lib_1.Stack(); + vpc = new ec2.Vpc(stack, 'vpc'); + }); + test('respects name', () => { + // WHEN + new lib_1.FargateComputeEnvironment(stack, 'maximalPropsFargate', { + vpc, + maxvCpus: 512, + computeEnvironmentName: 'maxPropsFargateCE', + replaceComputeEnvironment: true, + spot: true, + terminateOnUpdate: true, + updateTimeout: aws_cdk_lib_1.Duration.minutes(30), + updateToLatestImageVersion: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ComputeEnvironmentName: 'maxPropsFargateCE', + }); + }); + test('can be imported from arn', () => { + // WHEN + const ce = lib_1.FargateComputeEnvironment.fromFargateComputeEnvironmentArn(stack, 'import', 'arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); + // THEN + expect(ce.computeEnvironmentArn).toEqual('arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJtYW5hZ2VkLWNvbX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dGUtZW52aXJvbm1lbnQvY2UtbmFtZScpO1xuICB9KTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js new file mode 100644 index 0000000000000..0120ecf9bd8eb --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js @@ -0,0 +1,155 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); +const ecs = require("aws-cdk-lib/aws-ecs"); +const aws_cdk_lib_1 = require("aws-cdk-lib"); +const lib_1 = require("../lib"); +test('MultiNodeJobDefinition respects mainNode', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { + containers: [{ + container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 0, + endNode: 9, + }], + mainNode: 5, + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + NodeProperties: { + MainNode: 5, + NodeRangeProperties: [{ + Container: { + InstanceType: 'r4.large', + }, + TargetNodes: '0:9', + }], + NumNodes: 10, + }, + PlatformCapabilities: [lib_1.Compatibility.EC2], + }); +}); +test('EcsJobDefinition respects propagateTags', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { + propagateTags: true, + containers: [{ + container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 0, + endNode: 9, + }], + mainNode: 0, + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + PropagateTags: true, + }); +}); +test('MultiNodeJobDefinition one container', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { + containers: [{ + container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 0, + endNode: 9, + }], + mainNode: 0, + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + NodeProperties: { + MainNode: 0, + NodeRangeProperties: [{ + Container: { + InstanceType: 'r4.large', + }, + TargetNodes: '0:9', + }], + NumNodes: 10, + }, + PlatformCapabilities: [lib_1.Compatibility.EC2], + }); +}); +test('MultiNodeJobDefinition two containers', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { + containers: [ + { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer1', { + cpu: 256, + memory: aws_cdk_lib_1.Size.mebibytes(2048), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 0, + endNode: 9, + }, + { + container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer2', { + cpu: 512, + memory: aws_cdk_lib_1.Size.mebibytes(4096), + image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), + }), + startNode: 10, + endNode: 14, + }, + ], + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { + NodeProperties: { + MainNode: 0, + NodeRangeProperties: [ + { + Container: { + InstanceType: 'r4.large', + }, + TargetNodes: '0:9', + }, + { + Container: { + InstanceType: 'r4.large', + }, + TargetNodes: '10:14', + }, + ], + NumNodes: 15, + }, + PlatformCapabilities: [lib_1.Compatibility.EC2], + }); +}); +test('multinode job requires at least one container', () => { + // GIVEN + const stack = new aws_cdk_lib_1.Stack(); + // WHEN + new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { + instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.C4, aws_ec2_1.InstanceSize.LARGE), + }); + // THEN + expect(() => assertions_1.Template.fromStack(stack)).toThrow(/multinode job has no containers!/); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJtdWx0aW5vZGUtam9iLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCxpREFBZ0Y7QUFDaEYsMkNBQTJDO0FBQzNDLDZDQUEwQztBQUMxQyxnQ0FBMEY7QUFFMUYsSUFBSSxDQUFDLDBDQUEwQyxFQUFF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6MTQnLFxuICAgICAgICB9LFxuXG4gICAgICBdLFxuICAgICAgTnVtTm9kZXM6IDE1LFxuICAgIH0sXG4gICAgUGxhdGZvcm1DYXBhYmlsaXRpZXM6IFtDb21wYXRpYmlsaXR5LkVDMl0sXG4gIH0pO1xufSk7XG5cbnRlc3QoJ211bHRpbm9kZSBqb2IgcmVxdWlyZXMgYXQgbGVhc3Qgb25lIGNvbnRhaW5lcicsICgpID0+IHtcbiAgLy8gR0lWRU5cbiAgY29uc3Qgc3RhY2sgPSBuZXcgU3RhY2soKTtcblxuICAvLyBXSEVOXG4gIG5ldyBNdWx0aU5vZGVKb2JEZWZpbml0aW9uKHN0YWNrLCAnRUNTSm9iRGVmbicsIHtcbiAgICBpbnN0YW5jZVR5cGU6IEluc3RhbmNlVHlwZS5vZihJbnN0YW5jZUNsYXNzLkM0LCBJbnN0YW5jZVNpemUuTEFSR0UpLFxuICB9KTtcblxuICAvLyBUSEVOXG4gIGV4cGVjdCgoKSA9PiBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spKS50b1Rocm93KC9tdWx0aW5vZGUgam9iIGhhcyBubyBjb250YWluZXJzIS8pO1xufSk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js new file mode 100644 index 0000000000000..b15d5d7caa7f6 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js @@ -0,0 +1,133 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const core_1 = require("aws-cdk-lib/core"); +const lib_1 = require("../lib"); +test('empty fairshare policy', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy'); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + FairsharePolicy: { + ShareDistribution: [], + }, + }); +}); +test('fairshare policy respects computeReservation', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { + computeReservation: 75, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + FairsharePolicy: { + ComputeReservation: 75, + ShareDistribution: [], + }, + }); +}); +test('fairshare policy respects name', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { + schedulingPolicyName: 'FairsharePolicyName', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + Name: 'FairsharePolicyName', + FairsharePolicy: { + ShareDistribution: [], + }, + }); +}); +test('fairshare policy respects shareDecay', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { + shareDecay: core_1.Duration.hours(1), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + FairsharePolicy: { + ShareDecaySeconds: 3600, + ShareDistribution: [], + }, + }); +}); +test('fairshare policy respects shares', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { + shares: [ + { + shareIdentifier: 'myShareId', + weightFactor: 0.5, + }, + { + shareIdentifier: 'myShareId2', + weightFactor: 1, + }, + ], + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + FairsharePolicy: { + ShareDistribution: [ + { + ShareIdentifier: 'myShareId', + WeightFactor: 0.5, + }, + { + ShareIdentifier: 'myShareId2', + WeightFactor: 1, + }, + ], + }, + }); +}); +test('addShare() works', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + const policy = new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { + shares: [{ + shareIdentifier: 'myShareId', + weightFactor: 0.5, + }], + }); + policy.addShare({ + shareIdentifier: 'addedShareId', + weightFactor: 0.5, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { + FairsharePolicy: { + ShareDistribution: [ + { + ShareIdentifier: 'myShareId', + WeightFactor: 0.5, + }, + { + ShareIdentifier: 'addedShareId', + WeightFactor: 0.5, + }, + ], + }, + }); +}); +test('can be imported from ARN', () => { + // GIVEN + const stack = new core_1.Stack(); + // WHEN + const policy = lib_1.FairshareSchedulingPolicy.fromFairshareSchedulingPolicyArn(stack, 'policyImport', 'arn:aws:batch:us-east-1:123456789012:scheduling-policy/policyImport'); + // THEN + expect(policy.schedulingPolicyArn).toEqual('arn:aws:batch:us-east-1:123456789012:scheduling-policy/policyImport'); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NoZWR1bGluZy1wb2xpY3kudGVzdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbInNjaGVkdWxpbmctcG9saWN5LnRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSx1REFBa0Q7QUFDbEQsMkNBQW1EO0FBQ25ELGdDQUFtRDtBQUVuRCxJQUFJLENBQUMsd0JBQXdCLEVBQUUsR0FBRyxFQUFFO0lBQ2xDLFFBQVE7SUFDUixNQUFNLEtBQUssR0FBRyxJQUFJLFlBQUssRUFBRSxDQUFDO0lBRTFCLE9BQU87SUFDUCxJQUFJLCtCQUF5QixDQUFDLEtBQUssRUFBRSxrQkFBa0IsQ0FBQyxDQUFDO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uICAvLyBUSEVOXG4gIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkJhdGNoOjpTY2hlZHVsaW5nUG9saWN5Jywge1xuICAgIEZhaXJzaGFyZVBvbGljeToge1xuICAgICAgU2hhcmVEaXN0cmlidXRpb246IFtcbiAgICAgICAge1xuICAgICAgICAgIFNoYXJlSWRlbnRpZmllcjogJ215U2hhcmVJZCcsXG4gICAgICAgICAgV2VpZ2h0RmFjdG9yOiAwLjUsXG4gICAgICAgIH0sXG4gICAgICAgIHtcbiAgICAgICAgICBTaGFyZUlkZW50aWZpZXI6ICdhZGRlZFNoYXJlSWQnLFxuICAgICAgICAgIFdlaWdodEZhY3RvcjogMC41LFxuICAgICAgICB9LFxuICAgICAgXSxcbiAgICB9LFxuICB9KTtcbn0pO1xuXG50ZXN0KCdjYW4gYmUgaW1wb3J0ZWQgZnJvbSBBUk4nLCAoKSA9PiB7XG4gIC8vIEdJVkVOXG4gIGNvbnN0IHN0YWNrID0gbmV3IFN0YWNrKCk7XG5cbiAgLy8gV0hFTlxuICBjb25zdCBwb2xpY3kgPSBGYWlyc2hhcmVTY2hlZHVsaW5nUG9saWN5LmZyb21GYWlyc2hhcmVTY2hlZHVsaW5nUG9saWN5QXJuKHN0YWNrLCAncG9saWN5SW1wb3J0JyxcbiAgICAnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOnNjaGVkdWxpbmctcG9saWN5L3BvbGljeUltcG9ydCcpO1xuXG4gIC8vIFRIRU5cbiAgZXhwZWN0KHBvbGljeS5zY2hlZHVsaW5nUG9saWN5QXJuKS50b0VxdWFsKCdhcm46YXdzOmJhdGNoOnVzLWVhc3QtMToxMjM0NTY3ODkwMTI6c2NoZWR1bGluZy1wb2xpY3kvcG9saWN5SW1wb3J0Jyk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts new file mode 100644 index 0000000000000..cb0ff5c3b541f --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts @@ -0,0 +1 @@ +export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js new file mode 100644 index 0000000000000..4c7fe0a2e433a --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js @@ -0,0 +1,90 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +const assertions_1 = require("aws-cdk-lib/assertions"); +const aws_iam_1 = require("aws-cdk-lib/aws-iam"); +const core_1 = require("aws-cdk-lib/core"); +const utils_1 = require("./utils"); +const unmanaged_compute_environment_1 = require("../lib/unmanaged-compute-environment"); +const defaultExpectedProps = { + type: 'unmanaged', + computeEnvironmentName: undefined, + computeResources: undefined, + eksConfiguration: undefined, + replaceComputeEnvironment: undefined, + serviceRole: { + 'Fn::GetAtt': ['MyCEBatchServiceRole4FDA2CB6', 'Arn'], + }, + state: 'ENABLED', + tags: undefined, + unmanagedvCpus: undefined, + updatePolicy: undefined, +}; +let stack = new core_1.Stack(); +const pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedProps); +test('default props', () => { + // GIVEN + stack = new core_1.Stack(); + // WHEN + new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE'); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedProps, + }); +}); +test('respects enabled: false', () => { + // GIVEN + stack = new core_1.Stack(); + // WHEN + new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { + enabled: false, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedProps, + State: 'DISABLED', + }); +}); +test('respects name', () => { + // GIVEN + stack = new core_1.Stack(); + // WHEN + new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { + computeEnvironmentName: 'magic', + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedProps, + ComputeEnvironmentName: 'magic', + }); +}); +test('respects serviceRole', () => { + // GIVEN + stack = new core_1.Stack(); + // WHEN + new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { + serviceRole: new aws_iam_1.Role(stack, 'myMagicRole', { + assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), + }), + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedProps, + ServiceRole: { + 'Fn::GetAtt': ['myMagicRole2BBD827A', 'Arn'], + }, + }); +}); +test('respects unmanagedvCpus', () => { + // GIVEN + stack = new core_1.Stack(); + // WHEN + new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { + unmanagedvCpus: 256, + }); + // THEN + assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { + ...pascalCaseExpectedProps, + UnmanagedvCpus: 256, + }); +}); +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidW5tYW5hZ2VkLWNvbXB1dGUtZW52aXJvbm1lbnQudGVzdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbInVubWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LnRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSx1REFBa0Q7QUFDbEQsaURBQTZEO0FBQzdELDJDQUF5QztBQUN6QyxtQ0FBa0Q7QUFFbEQsd0ZBQW1GO0FBRW5GLE1BQU0sb0JBQ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ubWFuYWdlZHZDcHVzOiAyNTYsXG4gIH0pO1xufSk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts new file mode 100644 index 0000000000000..934fcac4357e0 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts @@ -0,0 +1,6 @@ +import { IConstruct } from 'constructs'; +/** + * Given an object, converts all keys to PascalCase given they are currently in camel case. + * @param obj The object. + */ +export declare function capitalizePropertyNames(construct: IConstruct, obj: any): any; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/utils.js b/packages/@aws-cdk/aws-batch-alpha/test/utils.js new file mode 100644 index 0000000000000..c804b15bf6337 --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/test/utils.js @@ -0,0 +1,28 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +exports.capitalizePropertyNames = void 0; +const aws_cdk_lib_1 = require("aws-cdk-lib"); +/** + * Given an object, converts all keys to PascalCase given they are currently in camel case. + * @param obj The object. + */ +function capitalizePropertyNames(construct, obj) { + const stack = aws_cdk_lib_1.Stack.of(construct); + obj = stack.resolve(obj); + if (typeof (obj) !== 'object') { + return obj; + } + if (Array.isArray(obj)) { + return obj.map(x => capitalizePropertyNames(construct, x)); + } + const newObj = {}; + for (const key of Object.keys(obj)) { + const value = obj[key]; + const first = key.charAt(0).toUpperCase(); + const newKey = first + key.slice(1); + newObj[newKey] = capitalizePropertyNames(construct, value); + } + return newObj; +} +exports.capitalizePropertyNames = capitalizePropertyNames; +//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJ1dGlscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSw2Q0FBb0M7QUFHcEM7OztHQUdHO0FBQ0gsU0FBZ0IsdUJBQXVCLEN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2F3cy1jZGstbGliJztcbmltcG9ydCB7IElDb25zdHJ1Y3QgfSBmcm9tICdjb25zdHJ1Y3RzJztcblxuLyoqXG4gKiBHaXZlbiBhbiBvYmplY3QsIGNvbnZlcnRzIGFsbCBrZXlzIHRvIFBhc2NhbENhc2UgZ2l2ZW4gdGhleSBhcmUgY3VycmVudGx5IGluIGNhbWVsIGNhc2UuXG4gKiBAcGFyYW0gb2JqIFRoZSBvYmplY3QuXG4gKi9cbmV4cG9ydCBmdW5jdGlvbiBjYXBpdGFsaXplUHJvcGVydHlOYW1lcyhjb25zdHJ1Y3Q6IElDb25zdHJ1Y3QsIG9iajogYW55KTogYW55IHtcbiAgY29uc3Qgc3RhY2sgPSBTdGFjay5vZihjb25zdHJ1Y3QpO1xuICBvYmogPSBzdGFjay5yZXNvbHZlKG9iaik7XG5cbiAgaWYgKHR5cGVvZihvYmopICE9PSAnb2JqZWN0Jykge1xuICAgIHJldHVybiBvYmo7XG4gIH1cblxuICBpZiAoQXJyYXkuaXNBcnJheShvYmopKSB7XG4gICAgcmV0dXJuIG9iai5tYXAoeCA9PiBjYXBpdGFsaXplUHJvcGVydHlOYW1lcyhjb25zdHJ1Y3QsIHgpKTtcbiAgfVxuXG4gIGNvbnN0IG5ld09iajogYW55ID0geyB9O1xuICBmb3IgKGNvbnN0IGtleSBvZiBPYmplY3Qua2V5cyhvYmopKSB7XG4gICAgY29uc3QgdmFsdWUgPSBvYmpba2V5XTtcblxuICAgIGNvbnN0IGZpcnN0ID0ga2V5LmNoYXJBdCgwKS50b1VwcGVyQ2FzZSgpO1xuICAgIGNvbnN0IG5ld0tleSA9IGZpcnN0ICsga2V5LnNsaWNlKDEpO1xuICAgIG5ld09ialtuZXdLZXldID0gY2FwaXRhbGl6ZVByb3BlcnR5TmFtZXMoY29uc3RydWN0LCB2YWx1ZSk7XG4gIH1cblxuICByZXR1cm4gbmV3T2JqO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/tsconfig.json b/packages/@aws-cdk/aws-batch-alpha/tsconfig.json new file mode 100644 index 0000000000000..00315950564fd --- /dev/null +++ b/packages/@aws-cdk/aws-batch-alpha/tsconfig.json @@ -0,0 +1,53 @@ +{ + "compilerOptions": { + "declarationMap": false, + "inlineSourceMap": true, + "inlineSources": true, + "alwaysStrict": true, + "declaration": true, + "experimentalDecorators": true, + "incremental": true, + "lib": [ + "es2020" + ], + "module": "CommonJS", + "noEmitOnError": true, + "noFallthroughCasesInSwitch": true, + "noImplicitAny": true, + "noImplicitReturns": true, + "noImplicitThis": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "resolveJsonModule": true, + "skipLibCheck": true, + "strict": true, + "strictNullChecks": true, + "strictPropertyInitialization": true, + "stripInternal": false, + "target": "ES2020", + "composite": true, + "tsBuildInfoFile": "tsconfig.tsbuildinfo" + }, + "include": [ + "**/*.ts" + ], + "exclude": [ + "node_modules", + ".types-compat" + ], + "references": [ + { + "path": "../../../tools/@aws-cdk/cdk-build-tools" + }, + { + "path": "../integ-runner" + }, + { + "path": "../../../tools/@aws-cdk/pkglint" + }, + { + "path": "../integ-tests-alpha" + } + ], + "_generated_by_jsii_": "Generated by jsii - safe to delete, and ideally should be in .gitignore" +} \ No newline at end of file diff --git a/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts b/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts index e97e45bf48689..896a8105d2e3a 100644 --- a/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts +++ b/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts @@ -222,7 +222,7 @@ describe('parallel worker', () => { const results = await runIntegrationTestsInParallel({ pool, tests, - regions: ['us-east-1'], + regions: ['us-west-2'], }); expect(stderrMock.mock.calls[0][0]).toContain( @@ -408,7 +408,7 @@ describe('parallel worker', () => { const results = await runIntegrationTestsInParallel({ tests, pool, - regions: ['us-east-1'], + regions: ['us-west-2'], }); expect(stderrMock.mock.calls[1][0]).toContain( From 82d2e9448b35be16f99b30e47f0ead3a30cceb86 Mon Sep 17 00:00:00 2001 From: Michael Sambol Date: Tue, 12 Sep 2023 18:57:08 -0500 Subject: [PATCH 3/7] oops --- packages/@aws-cdk/aws-batch-alpha/.jsii | 15284 ---------------- .../aws-batch-alpha/.warnings.jsii.js | 515 - .../lib/compute-environment-base.d.ts | 87 - .../lib/compute-environment-base.js | 20 - .../lib/ecs-container-definition.d.ts | 726 - .../lib/ecs-container-definition.js | 531 - .../lib/ecs-job-definition.d.ts | 67 - .../aws-batch-alpha/lib/ecs-job-definition.js | 102 - .../lib/eks-container-definition.d.ts | 728 - .../lib/eks-container-definition.js | 338 - .../lib/eks-job-definition.d.ts | 123 - .../aws-batch-alpha/lib/eks-job-definition.js | 134 - .../@aws-cdk/aws-batch-alpha/lib/index.d.ts | 12 - .../@aws-cdk/aws-batch-alpha/lib/index.js | 29 - .../lib/job-definition-base.d.ts | 217 - .../lib/job-definition-base.js | 153 - .../aws-batch-alpha/lib/job-queue.d.ts | 140 - .../@aws-cdk/aws-batch-alpha/lib/job-queue.js | 102 - .../aws-batch-alpha/lib/linux-parameters.d.ts | 196 - .../aws-batch-alpha/lib/linux-parameters.js | 175 - .../lib/managed-compute-environment.d.ts | 806 - .../lib/managed-compute-environment.js | 451 - .../lib/multinode-job-definition.d.ts | 107 - .../lib/multinode-job-definition.js | 104 - .../lib/scheduling-policy.d.ts | 188 - .../aws-batch-alpha/lib/scheduling-policy.js | 101 - .../lib/unmanaged-compute-environment.d.ts | 47 - .../lib/unmanaged-compute-environment.js | 70 - .../test/aws-events-targets/batch.test.d.ts | 1 - .../test/aws-events-targets/batch.test.js | 294 - .../run-batch-job.test.d.ts | 1 - .../run-batch-job.test.js | 286 - .../submit-job.test.d.ts | 1 - .../submit-job.test.js | 401 - .../test/ecs-container-definition.test.d.ts | 1 - .../test/ecs-container-definition.test.js | 998 - .../test/ecs-job-definition.test.d.ts | 1 - .../test/ecs-job-definition.test.js | 147 - .../test/eks-container-definition.test.d.ts | 1 - .../test/eks-container-definition.test.js | 712 - .../test/eks-job-definition.test.d.ts | 1 - .../test/eks-job-definition.test.js | 72 - .../test/integ.batch-unique-name.d.ts | 1 - .../test/integ.batch-unique-name.js | 34 - .../test/integ.ecs-job-definition.d.ts | 1 - .../test/integ.ecs-job-definition.js | 94 - .../test/integ.eks-job-definition.d.ts | 1 - .../test/integ.eks-job-definition.js | 59 - .../aws-batch-alpha/test/integ.grants.d.ts | 1 - .../aws-batch-alpha/test/integ.grants.js | 35 - .../aws-batch-alpha/test/integ.job-queue.d.ts | 1 - .../aws-batch-alpha/test/integ.job-queue.js | 41 - .../integ.managed-compute-environment.d.ts | 1 - .../test/integ.managed-compute-environment.js | 78 - .../test/integ.multinode-job-definition.d.ts | 1 - .../test/integ.multinode-job-definition.js | 48 - .../integ.unmanaged-compute-environment.d.ts | 1 - .../integ.unmanaged-compute-environment.js | 25 - .../test/job-definition-base.test.d.ts | 1 - .../test/job-definition-base.test.js | 205 - .../aws-batch-alpha/test/job-queue.test.d.ts | 1 - .../aws-batch-alpha/test/job-queue.test.js | 228 - .../managed-compute-environment.test.d.ts | 1 - .../test/managed-compute-environment.test.js | 860 - .../test/multinode-job-definition.test.d.ts | 1 - .../test/multinode-job-definition.test.js | 155 - .../test/scheduling-policy.test.d.ts | 1 - .../test/scheduling-policy.test.js | 133 - .../unmanaged-compute-environment.test.d.ts | 1 - .../unmanaged-compute-environment.test.js | 90 - .../@aws-cdk/aws-batch-alpha/test/utils.d.ts | 6 - .../@aws-cdk/aws-batch-alpha/test/utils.js | 28 - .../@aws-cdk/aws-batch-alpha/tsconfig.json | 53 - .../test/workers/integ-worker.test.ts | 4 +- 74 files changed, 2 insertions(+), 26658 deletions(-) delete mode 100644 packages/@aws-cdk/aws-batch-alpha/.jsii delete mode 100644 packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/index.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts delete mode 100644 packages/@aws-cdk/aws-batch-alpha/test/utils.js delete mode 100644 packages/@aws-cdk/aws-batch-alpha/tsconfig.json diff --git a/packages/@aws-cdk/aws-batch-alpha/.jsii b/packages/@aws-cdk/aws-batch-alpha/.jsii deleted file mode 100644 index c1ba9b1aeaab4..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/.jsii +++ /dev/null @@ -1,15284 +0,0 @@ -{ - "author": { - "name": "Amazon Web Services", - "organization": true, - "roles": [ - "author" - ], - "url": "https://aws.amazon.com" - }, - "dependencies": { - "aws-cdk-lib": "^0.0.0", - "constructs": "^10.0.0" - }, - "dependencyClosure": { - "@aws-cdk/asset-awscli-v1": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Asset.AwsCliV1", - "packageId": "Amazon.CDK.Asset.AwsCliV1" - }, - "go": { - "moduleName": "github.com/cdklabs/awscdk-asset-awscli-go", - "packageName": "awscliv1" - }, - "java": { - "maven": { - "artifactId": "cdk-asset-awscli-v1", - "groupId": "software.amazon.awscdk" - }, - "package": "software.amazon.awscdk.cdk.asset.awscli.v1" - }, - "js": { - "npm": "@aws-cdk/asset-awscli-v1" - }, - "python": { - "distName": "aws-cdk.asset-awscli-v1", - "module": "aws_cdk.asset_awscli_v1" - } - } - }, - "@aws-cdk/asset-kubectl-v20": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Asset.KubectlV20", - "packageId": "Amazon.CDK.Asset.KubectlV20" - }, - "go": { - "moduleName": "github.com/cdklabs/awscdk-asset-kubectl-go", - "packageName": "kubectlv20" - }, - "java": { - "maven": { - "artifactId": "cdk-asset-kubectl-v20", - "groupId": "software.amazon.awscdk" - }, - "package": "software.amazon.awscdk.cdk.asset.kubectl.v20" - }, - "js": { - "npm": "@aws-cdk/asset-kubectl-v20" - }, - "python": { - "distName": "aws-cdk.asset-kubectl-v20", - "module": "aws_cdk.asset_kubectl_v20" - } - } - }, - "@aws-cdk/asset-node-proxy-agent-v6": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Asset.NodeProxyAgentV6", - "packageId": "Amazon.CDK.Asset.NodeProxyAgentV6" - }, - "go": { - "moduleName": "github.com/cdklabs/awscdk-asset-node-proxy-agent-go", - "packageName": "nodeproxyagentv6" - }, - "java": { - "maven": { - "artifactId": "cdk-asset-node-proxy-agent-v6", - "groupId": "software.amazon.awscdk" - }, - "package": "software.amazon.awscdk.cdk.asset.node.proxy.agent.v6" - }, - "js": { - "npm": "@aws-cdk/asset-node-proxy-agent-v6" - }, - "python": { - "distName": "aws-cdk.asset-node-proxy-agent-v6", - "module": "aws_cdk.asset_node_proxy_agent_v6" - } - } - }, - "aws-cdk-lib": { - "submodules": { - "aws-cdk-lib.alexa_ask": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Alexa.Ask" - }, - "java": { - "package": "software.amazon.awscdk.alexa.ask" - }, - "python": { - "module": "aws_cdk.alexa_ask" - } - } - }, - "aws-cdk-lib.assertions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Assertions" - }, - "java": { - "package": "software.amazon.awscdk.assertions" - }, - "python": { - "module": "aws_cdk.assertions" - } - } - }, - "aws-cdk-lib.assets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Assets" - }, - "java": { - "package": "software.amazon.awscdk.assets" - }, - "python": { - "module": "aws_cdk.assets" - } - } - }, - "aws-cdk-lib.aws_accessanalyzer": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AccessAnalyzer" - }, - "java": { - "package": "software.amazon.awscdk.services.accessanalyzer" - }, - "python": { - "module": "aws_cdk.aws_accessanalyzer" - } - } - }, - "aws-cdk-lib.aws_acmpca": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ACMPCA" - }, - "java": { - "package": "software.amazon.awscdk.services.acmpca" - }, - "python": { - "module": "aws_cdk.aws_acmpca" - } - } - }, - "aws-cdk-lib.aws_amazonmq": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AmazonMQ" - }, - "java": { - "package": "software.amazon.awscdk.services.amazonmq" - }, - "python": { - "module": "aws_cdk.aws_amazonmq" - } - } - }, - "aws-cdk-lib.aws_amplify": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Amplify" - }, - "java": { - "package": "software.amazon.awscdk.services.amplify" - }, - "python": { - "module": "aws_cdk.aws_amplify" - } - } - }, - "aws-cdk-lib.aws_amplifyuibuilder": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AmplifyUIBuilder" - }, - "java": { - "package": "software.amazon.awscdk.services.amplifyuibuilder" - }, - "python": { - "module": "aws_cdk.aws_amplifyuibuilder" - } - } - }, - "aws-cdk-lib.aws_apigateway": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.APIGateway" - }, - "java": { - "package": "software.amazon.awscdk.services.apigateway" - }, - "python": { - "module": "aws_cdk.aws_apigateway" - } - } - }, - "aws-cdk-lib.aws_apigatewayv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Apigatewayv2" - }, - "java": { - "package": "software.amazon.awscdk.services.apigatewayv2" - }, - "python": { - "module": "aws_cdk.aws_apigatewayv2" - } - } - }, - "aws-cdk-lib.aws_appconfig": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppConfig" - }, - "java": { - "package": "software.amazon.awscdk.services.appconfig" - }, - "python": { - "module": "aws_cdk.aws_appconfig" - } - } - }, - "aws-cdk-lib.aws_appflow": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppFlow" - }, - "java": { - "package": "software.amazon.awscdk.services.appflow" - }, - "python": { - "module": "aws_cdk.aws_appflow" - } - } - }, - "aws-cdk-lib.aws_appintegrations": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppIntegrations" - }, - "java": { - "package": "software.amazon.awscdk.services.appintegrations" - }, - "python": { - "module": "aws_cdk.aws_appintegrations" - } - } - }, - "aws-cdk-lib.aws_applicationautoscaling": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ApplicationAutoScaling" - }, - "java": { - "package": "software.amazon.awscdk.services.applicationautoscaling" - }, - "python": { - "module": "aws_cdk.aws_applicationautoscaling" - } - } - }, - "aws-cdk-lib.aws_applicationinsights": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ApplicationInsights" - }, - "java": { - "package": "software.amazon.awscdk.services.applicationinsights" - }, - "python": { - "module": "aws_cdk.aws_applicationinsights" - } - } - }, - "aws-cdk-lib.aws_appmesh": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppMesh" - }, - "java": { - "package": "software.amazon.awscdk.services.appmesh" - }, - "python": { - "module": "aws_cdk.aws_appmesh" - } - } - }, - "aws-cdk-lib.aws_apprunner": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppRunner" - }, - "java": { - "package": "software.amazon.awscdk.services.apprunner" - }, - "python": { - "module": "aws_cdk.aws_apprunner" - } - } - }, - "aws-cdk-lib.aws_appstream": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppStream" - }, - "java": { - "package": "software.amazon.awscdk.services.appstream" - }, - "python": { - "module": "aws_cdk.aws_appstream" - } - } - }, - "aws-cdk-lib.aws_appsync": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AppSync" - }, - "java": { - "package": "software.amazon.awscdk.services.appsync" - }, - "python": { - "module": "aws_cdk.aws_appsync" - } - } - }, - "aws-cdk-lib.aws_aps": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.APS" - }, - "java": { - "package": "software.amazon.awscdk.services.aps" - }, - "python": { - "module": "aws_cdk.aws_aps" - } - } - }, - "aws-cdk-lib.aws_athena": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Athena" - }, - "java": { - "package": "software.amazon.awscdk.services.athena" - }, - "python": { - "module": "aws_cdk.aws_athena" - } - } - }, - "aws-cdk-lib.aws_auditmanager": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AuditManager" - }, - "java": { - "package": "software.amazon.awscdk.services.auditmanager" - }, - "python": { - "module": "aws_cdk.aws_auditmanager" - } - } - }, - "aws-cdk-lib.aws_autoscaling": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AutoScaling" - }, - "java": { - "package": "software.amazon.awscdk.services.autoscaling" - }, - "python": { - "module": "aws_cdk.aws_autoscaling" - } - } - }, - "aws-cdk-lib.aws_autoscaling_common": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AutoScaling.Common" - }, - "java": { - "package": "software.amazon.awscdk.services.autoscaling.common" - }, - "python": { - "module": "aws_cdk.aws_autoscaling_common" - } - } - }, - "aws-cdk-lib.aws_autoscaling_hooktargets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AutoScaling.HookTargets" - }, - "java": { - "package": "software.amazon.awscdk.services.autoscaling.hooktargets" - }, - "python": { - "module": "aws_cdk.aws_autoscaling_hooktargets" - } - } - }, - "aws-cdk-lib.aws_autoscalingplans": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.AutoScalingPlans" - }, - "java": { - "package": "software.amazon.awscdk.services.autoscalingplans" - }, - "python": { - "module": "aws_cdk.aws_autoscalingplans" - } - } - }, - "aws-cdk-lib.aws_backup": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Backup" - }, - "java": { - "package": "software.amazon.awscdk.services.backup" - }, - "python": { - "module": "aws_cdk.aws_backup" - } - } - }, - "aws-cdk-lib.aws_backupgateway": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.BackupGateway" - }, - "java": { - "package": "services.backupgateway" - }, - "python": { - "module": "aws_cdk.aws_backupgateway" - } - } - }, - "aws-cdk-lib.aws_batch": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Batch" - }, - "java": { - "package": "software.amazon.awscdk.services.batch" - }, - "python": { - "module": "aws_cdk.aws_batch" - } - } - }, - "aws-cdk-lib.aws_billingconductor": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.BillingConductor" - }, - "java": { - "package": "software.amazon.awscdk.services.billingconductor" - }, - "python": { - "module": "aws_cdk.aws_billingconductor" - } - } - }, - "aws-cdk-lib.aws_budgets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Budgets" - }, - "java": { - "package": "software.amazon.awscdk.services.budgets" - }, - "python": { - "module": "aws_cdk.aws_budgets" - } - } - }, - "aws-cdk-lib.aws_cassandra": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Cassandra" - }, - "java": { - "package": "software.amazon.awscdk.services.cassandra" - }, - "python": { - "module": "aws_cdk.aws_cassandra" - } - } - }, - "aws-cdk-lib.aws_ce": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CE" - }, - "java": { - "package": "software.amazon.awscdk.services.ce" - }, - "python": { - "module": "aws_cdk.aws_ce" - } - } - }, - "aws-cdk-lib.aws_certificatemanager": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CertificateManager" - }, - "java": { - "package": "software.amazon.awscdk.services.certificatemanager" - }, - "python": { - "module": "aws_cdk.aws_certificatemanager" - } - } - }, - "aws-cdk-lib.aws_chatbot": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Chatbot" - }, - "java": { - "package": "software.amazon.awscdk.services.chatbot" - }, - "python": { - "module": "aws_cdk.aws_chatbot" - } - } - }, - "aws-cdk-lib.aws_cleanrooms": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.CleanRooms" - }, - "java": { - "package": "services.cleanrooms" - }, - "python": { - "module": "aws_cdk.aws_cleanrooms" - } - } - }, - "aws-cdk-lib.aws_cloud9": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Cloud9" - }, - "java": { - "package": "software.amazon.awscdk.services.cloud9" - }, - "python": { - "module": "aws_cdk.aws_cloud9" - } - } - }, - "aws-cdk-lib.aws_cloudformation": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudFormation" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudformation" - }, - "python": { - "module": "aws_cdk.aws_cloudformation" - } - } - }, - "aws-cdk-lib.aws_cloudfront": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudFront" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudfront" - }, - "python": { - "module": "aws_cdk.aws_cloudfront" - } - } - }, - "aws-cdk-lib.aws_cloudfront.experimental": {}, - "aws-cdk-lib.aws_cloudfront_origins": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudFront.Origins" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudfront.origins" - }, - "python": { - "module": "aws_cdk.aws_cloudfront_origins" - } - } - }, - "aws-cdk-lib.aws_cloudtrail": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudTrail" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudtrail" - }, - "python": { - "module": "aws_cdk.aws_cloudtrail" - } - } - }, - "aws-cdk-lib.aws_cloudwatch": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudWatch" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudwatch" - }, - "python": { - "module": "aws_cdk.aws_cloudwatch" - } - } - }, - "aws-cdk-lib.aws_cloudwatch_actions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CloudWatch.Actions" - }, - "java": { - "package": "software.amazon.awscdk.services.cloudwatch.actions" - }, - "python": { - "module": "aws_cdk.aws_cloudwatch_actions" - } - } - }, - "aws-cdk-lib.aws_codeartifact": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeArtifact" - }, - "java": { - "package": "software.amazon.awscdk.services.codeartifact" - }, - "python": { - "module": "aws_cdk.aws_codeartifact" - } - } - }, - "aws-cdk-lib.aws_codebuild": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeBuild" - }, - "java": { - "package": "software.amazon.awscdk.services.codebuild" - }, - "python": { - "module": "aws_cdk.aws_codebuild" - } - } - }, - "aws-cdk-lib.aws_codecommit": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeCommit" - }, - "java": { - "package": "software.amazon.awscdk.services.codecommit" - }, - "python": { - "module": "aws_cdk.aws_codecommit" - } - } - }, - "aws-cdk-lib.aws_codedeploy": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeDeploy" - }, - "java": { - "package": "software.amazon.awscdk.services.codedeploy" - }, - "python": { - "module": "aws_cdk.aws_codedeploy" - } - } - }, - "aws-cdk-lib.aws_codeguruprofiler": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeGuruProfiler" - }, - "java": { - "package": "software.amazon.awscdk.services.codeguruprofiler" - }, - "python": { - "module": "aws_cdk.aws_codeguruprofiler" - } - } - }, - "aws-cdk-lib.aws_codegurureviewer": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeGuruReviewer" - }, - "java": { - "package": "software.amazon.awscdk.services.codegurureviewer" - }, - "python": { - "module": "aws_cdk.aws_codegurureviewer" - } - } - }, - "aws-cdk-lib.aws_codepipeline": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodePipeline" - }, - "java": { - "package": "software.amazon.awscdk.services.codepipeline" - }, - "python": { - "module": "aws_cdk.aws_codepipeline" - } - } - }, - "aws-cdk-lib.aws_codepipeline_actions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodePipeline.Actions" - }, - "java": { - "package": "software.amazon.awscdk.services.codepipeline.actions" - }, - "python": { - "module": "aws_cdk.aws_codepipeline_actions" - } - } - }, - "aws-cdk-lib.aws_codestar": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Codestar" - }, - "java": { - "package": "software.amazon.awscdk.services.codestar" - }, - "python": { - "module": "aws_cdk.aws_codestar" - } - } - }, - "aws-cdk-lib.aws_codestarconnections": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeStarConnections" - }, - "java": { - "package": "software.amazon.awscdk.services.codestarconnections" - }, - "python": { - "module": "aws_cdk.aws_codestarconnections" - } - } - }, - "aws-cdk-lib.aws_codestarnotifications": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CodeStarNotifications" - }, - "java": { - "package": "software.amazon.awscdk.services.codestarnotifications" - }, - "python": { - "module": "aws_cdk.aws_codestarnotifications" - } - } - }, - "aws-cdk-lib.aws_cognito": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Cognito" - }, - "java": { - "package": "software.amazon.awscdk.services.cognito" - }, - "python": { - "module": "aws_cdk.aws_cognito" - } - } - }, - "aws-cdk-lib.aws_comprehend": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Comprehend" - }, - "java": { - "package": "software.amazon.awscdk.services.comprehend" - }, - "python": { - "module": "aws_cdk.aws_comprehend" - } - } - }, - "aws-cdk-lib.aws_config": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Config" - }, - "java": { - "package": "software.amazon.awscdk.services.config" - }, - "python": { - "module": "aws_cdk.aws_config" - } - } - }, - "aws-cdk-lib.aws_connect": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Connect" - }, - "java": { - "package": "software.amazon.awscdk.services.connect" - }, - "python": { - "module": "aws_cdk.aws_connect" - } - } - }, - "aws-cdk-lib.aws_connectcampaigns": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ConnectCampaigns" - }, - "java": { - "package": "software.amazon.awscdk.services.connectcampaigns" - }, - "python": { - "module": "aws_cdk.aws_connectcampaigns" - } - } - }, - "aws-cdk-lib.aws_controltower": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ControlTower" - }, - "java": { - "package": "software.amazon.awscdk.services.controltower" - }, - "python": { - "module": "aws_cdk.aws_controltower" - } - } - }, - "aws-cdk-lib.aws_cur": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CUR" - }, - "java": { - "package": "software.amazon.awscdk.services.cur" - }, - "python": { - "module": "aws_cdk.aws_cur" - } - } - }, - "aws-cdk-lib.aws_customerprofiles": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.CustomerProfiles" - }, - "java": { - "package": "software.amazon.awscdk.services.customerprofiles" - }, - "python": { - "module": "aws_cdk.aws_customerprofiles" - } - } - }, - "aws-cdk-lib.aws_databrew": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DataBrew" - }, - "java": { - "package": "software.amazon.awscdk.services.databrew" - }, - "python": { - "module": "aws_cdk.aws_databrew" - } - } - }, - "aws-cdk-lib.aws_datapipeline": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DataPipeline" - }, - "java": { - "package": "software.amazon.awscdk.services.datapipeline" - }, - "python": { - "module": "aws_cdk.aws_datapipeline" - } - } - }, - "aws-cdk-lib.aws_datasync": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DataSync" - }, - "java": { - "package": "software.amazon.awscdk.services.datasync" - }, - "python": { - "module": "aws_cdk.aws_datasync" - } - } - }, - "aws-cdk-lib.aws_dax": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DAX" - }, - "java": { - "package": "software.amazon.awscdk.services.dax" - }, - "python": { - "module": "aws_cdk.aws_dax" - } - } - }, - "aws-cdk-lib.aws_detective": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Detective" - }, - "java": { - "package": "software.amazon.awscdk.services.detective" - }, - "python": { - "module": "aws_cdk.aws_detective" - } - } - }, - "aws-cdk-lib.aws_devicefarm": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DeviceFarm" - }, - "java": { - "package": "software.amazon.awscdk.services.devicefarm" - }, - "python": { - "module": "aws_cdk.aws_devicefarm" - } - } - }, - "aws-cdk-lib.aws_devopsguru": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DevOpsGuru" - }, - "java": { - "package": "software.amazon.awscdk.services.devopsguru" - }, - "python": { - "module": "aws_cdk.aws_devopsguru" - } - } - }, - "aws-cdk-lib.aws_directoryservice": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DirectoryService" - }, - "java": { - "package": "software.amazon.awscdk.services.directoryservice" - }, - "python": { - "module": "aws_cdk.aws_directoryservice" - } - } - }, - "aws-cdk-lib.aws_dlm": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DLM" - }, - "java": { - "package": "software.amazon.awscdk.services.dlm" - }, - "python": { - "module": "aws_cdk.aws_dlm" - } - } - }, - "aws-cdk-lib.aws_dms": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DMS" - }, - "java": { - "package": "software.amazon.awscdk.services.dms" - }, - "python": { - "module": "aws_cdk.aws_dms" - } - } - }, - "aws-cdk-lib.aws_docdb": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DocDB" - }, - "java": { - "package": "software.amazon.awscdk.services.docdb" - }, - "python": { - "module": "aws_cdk.aws_docdb" - } - } - }, - "aws-cdk-lib.aws_docdbelastic": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DocDBElastic" - }, - "java": { - "package": "software.amazon.awscdk.services.docdbelastic" - }, - "python": { - "module": "aws_cdk.aws_docdbelastic" - } - } - }, - "aws-cdk-lib.aws_dynamodb": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.DynamoDB" - }, - "java": { - "package": "software.amazon.awscdk.services.dynamodb" - }, - "python": { - "module": "aws_cdk.aws_dynamodb" - } - } - }, - "aws-cdk-lib.aws_ec2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EC2" - }, - "java": { - "package": "software.amazon.awscdk.services.ec2" - }, - "python": { - "module": "aws_cdk.aws_ec2" - } - } - }, - "aws-cdk-lib.aws_ecr": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ECR" - }, - "java": { - "package": "software.amazon.awscdk.services.ecr" - }, - "python": { - "module": "aws_cdk.aws_ecr" - } - } - }, - "aws-cdk-lib.aws_ecr_assets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Ecr.Assets" - }, - "java": { - "package": "software.amazon.awscdk.services.ecr.assets" - }, - "python": { - "module": "aws_cdk.aws_ecr_assets" - } - } - }, - "aws-cdk-lib.aws_ecs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ECS" - }, - "java": { - "package": "software.amazon.awscdk.services.ecs" - }, - "python": { - "module": "aws_cdk.aws_ecs" - } - } - }, - "aws-cdk-lib.aws_ecs_patterns": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ECS.Patterns" - }, - "java": { - "package": "software.amazon.awscdk.services.ecs.patterns" - }, - "python": { - "module": "aws_cdk.aws_ecs_patterns" - } - } - }, - "aws-cdk-lib.aws_efs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EFS" - }, - "java": { - "package": "software.amazon.awscdk.services.efs" - }, - "python": { - "module": "aws_cdk.aws_efs" - } - } - }, - "aws-cdk-lib.aws_eks": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EKS" - }, - "java": { - "package": "software.amazon.awscdk.services.eks" - }, - "python": { - "module": "aws_cdk.aws_eks" - } - } - }, - "aws-cdk-lib.aws_elasticache": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElastiCache" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticache" - }, - "python": { - "module": "aws_cdk.aws_elasticache" - } - } - }, - "aws-cdk-lib.aws_elasticbeanstalk": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElasticBeanstalk" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticbeanstalk" - }, - "python": { - "module": "aws_cdk.aws_elasticbeanstalk" - } - } - }, - "aws-cdk-lib.aws_elasticloadbalancing": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElasticLoadBalancing" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticloadbalancing" - }, - "python": { - "module": "aws_cdk.aws_elasticloadbalancing" - } - } - }, - "aws-cdk-lib.aws_elasticloadbalancingv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElasticLoadBalancingV2" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticloadbalancingv2" - }, - "python": { - "module": "aws_cdk.aws_elasticloadbalancingv2" - } - } - }, - "aws-cdk-lib.aws_elasticloadbalancingv2_actions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElasticLoadBalancingV2.Actions" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticloadbalancingv2.actions" - }, - "python": { - "module": "aws_cdk.aws_elasticloadbalancingv2_actions" - } - } - }, - "aws-cdk-lib.aws_elasticloadbalancingv2_targets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ElasticLoadBalancingV2.Targets" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticloadbalancingv2.targets" - }, - "python": { - "module": "aws_cdk.aws_elasticloadbalancingv2_targets" - } - } - }, - "aws-cdk-lib.aws_elasticsearch": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Elasticsearch" - }, - "java": { - "package": "software.amazon.awscdk.services.elasticsearch" - }, - "python": { - "module": "aws_cdk.aws_elasticsearch" - } - } - }, - "aws-cdk-lib.aws_emr": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EMR" - }, - "java": { - "package": "software.amazon.awscdk.services.emr" - }, - "python": { - "module": "aws_cdk.aws_emr" - } - } - }, - "aws-cdk-lib.aws_emrcontainers": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EMRContainers" - }, - "java": { - "package": "software.amazon.awscdk.services.emrcontainers" - }, - "python": { - "module": "aws_cdk.aws_emrcontainers" - } - } - }, - "aws-cdk-lib.aws_emrserverless": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EMRServerless" - }, - "java": { - "package": "software.amazon.awscdk.services.emrserverless" - }, - "python": { - "module": "aws_cdk.aws_emrserverless" - } - } - }, - "aws-cdk-lib.aws_events": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Events" - }, - "java": { - "package": "software.amazon.awscdk.services.events" - }, - "python": { - "module": "aws_cdk.aws_events" - } - } - }, - "aws-cdk-lib.aws_events_targets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Events.Targets" - }, - "java": { - "package": "software.amazon.awscdk.services.events.targets" - }, - "python": { - "module": "aws_cdk.aws_events_targets" - } - } - }, - "aws-cdk-lib.aws_eventschemas": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.EventSchemas" - }, - "java": { - "package": "software.amazon.awscdk.services.eventschemas" - }, - "python": { - "module": "aws_cdk.aws_eventschemas" - } - } - }, - "aws-cdk-lib.aws_evidently": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Evidently" - }, - "java": { - "package": "software.amazon.awscdk.services.evidently" - }, - "python": { - "module": "aws_cdk.aws_evidently" - } - } - }, - "aws-cdk-lib.aws_finspace": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.FinSpace" - }, - "java": { - "package": "software.amazon.awscdk.services.finspace" - }, - "python": { - "module": "aws_cdk.aws_finspace" - } - } - }, - "aws-cdk-lib.aws_fis": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.FIS" - }, - "java": { - "package": "software.amazon.awscdk.services.fis" - }, - "python": { - "module": "aws_cdk.aws_fis" - } - } - }, - "aws-cdk-lib.aws_fms": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.FMS" - }, - "java": { - "package": "software.amazon.awscdk.services.fms" - }, - "python": { - "module": "aws_cdk.aws_fms" - } - } - }, - "aws-cdk-lib.aws_forecast": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Forecast" - }, - "java": { - "package": "software.amazon.awscdk.services.forecast" - }, - "python": { - "module": "aws_cdk.aws_forecast" - } - } - }, - "aws-cdk-lib.aws_frauddetector": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.FraudDetector" - }, - "java": { - "package": "software.amazon.awscdk.services.frauddetector" - }, - "python": { - "module": "aws_cdk.aws_frauddetector" - } - } - }, - "aws-cdk-lib.aws_fsx": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.FSx" - }, - "java": { - "package": "software.amazon.awscdk.services.fsx" - }, - "python": { - "module": "aws_cdk.aws_fsx" - } - } - }, - "aws-cdk-lib.aws_gamelift": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GameLift" - }, - "java": { - "package": "software.amazon.awscdk.services.gamelift" - }, - "python": { - "module": "aws_cdk.aws_gamelift" - } - } - }, - "aws-cdk-lib.aws_globalaccelerator": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GlobalAccelerator" - }, - "java": { - "package": "software.amazon.awscdk.services.globalaccelerator" - }, - "python": { - "module": "aws_cdk.aws_globalaccelerator" - } - } - }, - "aws-cdk-lib.aws_globalaccelerator_endpoints": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GlobalAccelerator.Endpoints" - }, - "java": { - "package": "software.amazon.awscdk.services.globalaccelerator.endpoints" - }, - "python": { - "module": "aws_cdk.aws_globalaccelerator_endpoints" - } - } - }, - "aws-cdk-lib.aws_glue": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Glue" - }, - "java": { - "package": "software.amazon.awscdk.services.glue" - }, - "python": { - "module": "aws_cdk.aws_glue" - } - } - }, - "aws-cdk-lib.aws_grafana": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Grafana" - }, - "java": { - "package": "software.amazon.awscdk.services.grafana" - }, - "python": { - "module": "aws_cdk.aws_grafana" - } - } - }, - "aws-cdk-lib.aws_greengrass": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Greengrass" - }, - "java": { - "package": "software.amazon.awscdk.services.greengrass" - }, - "python": { - "module": "aws_cdk.aws_greengrass" - } - } - }, - "aws-cdk-lib.aws_greengrassv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GreengrassV2" - }, - "java": { - "package": "software.amazon.awscdk.services.greengrassv2" - }, - "python": { - "module": "aws_cdk.aws_greengrassv2" - } - } - }, - "aws-cdk-lib.aws_groundstation": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GroundStation" - }, - "java": { - "package": "software.amazon.awscdk.services.groundstation" - }, - "python": { - "module": "aws_cdk.aws_groundstation" - } - } - }, - "aws-cdk-lib.aws_guardduty": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.GuardDuty" - }, - "java": { - "package": "software.amazon.awscdk.services.guardduty" - }, - "python": { - "module": "aws_cdk.aws_guardduty" - } - } - }, - "aws-cdk-lib.aws_healthlake": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.HealthLake" - }, - "java": { - "package": "software.amazon.awscdk.services.healthlake" - }, - "python": { - "module": "aws_cdk.aws_healthlake" - } - } - }, - "aws-cdk-lib.aws_iam": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IAM" - }, - "java": { - "package": "software.amazon.awscdk.services.iam" - }, - "python": { - "module": "aws_cdk.aws_iam" - } - } - }, - "aws-cdk-lib.aws_identitystore": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IdentityStore" - }, - "java": { - "package": "software.amazon.awscdk.services.identitystore" - }, - "python": { - "module": "aws_cdk.aws_identitystore" - } - } - }, - "aws-cdk-lib.aws_imagebuilder": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ImageBuilder" - }, - "java": { - "package": "software.amazon.awscdk.services.imagebuilder" - }, - "python": { - "module": "aws_cdk.aws_imagebuilder" - } - } - }, - "aws-cdk-lib.aws_inspector": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Inspector" - }, - "java": { - "package": "software.amazon.awscdk.services.inspector" - }, - "python": { - "module": "aws_cdk.aws_inspector" - } - } - }, - "aws-cdk-lib.aws_inspectorv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.InspectorV2" - }, - "java": { - "package": "software.amazon.awscdk.services.inspectorv2" - }, - "python": { - "module": "aws_cdk.aws_inspectorv2" - } - } - }, - "aws-cdk-lib.aws_internetmonitor": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.InternetMonitor" - }, - "java": { - "package": "software.amazon.awscdk.services.internetmonitor" - }, - "python": { - "module": "aws_cdk.aws_internetmonitor" - } - } - }, - "aws-cdk-lib.aws_iot": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoT" - }, - "java": { - "package": "software.amazon.awscdk.services.iot" - }, - "python": { - "module": "aws_cdk.aws_iot" - } - } - }, - "aws-cdk-lib.aws_iot1click": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoT1Click" - }, - "java": { - "package": "software.amazon.awscdk.services.iot1click" - }, - "python": { - "module": "aws_cdk.aws_iot1click" - } - } - }, - "aws-cdk-lib.aws_iotanalytics": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTAnalytics" - }, - "java": { - "package": "software.amazon.awscdk.services.iotanalytics" - }, - "python": { - "module": "aws_cdk.aws_iotanalytics" - } - } - }, - "aws-cdk-lib.aws_iotcoredeviceadvisor": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTCoreDeviceAdvisor" - }, - "java": { - "package": "software.amazon.awscdk.services.iotcoredeviceadvisor" - }, - "python": { - "module": "aws_cdk.aws_iotcoredeviceadvisor" - } - } - }, - "aws-cdk-lib.aws_iotevents": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTEvents" - }, - "java": { - "package": "software.amazon.awscdk.services.iotevents" - }, - "python": { - "module": "aws_cdk.aws_iotevents" - } - } - }, - "aws-cdk-lib.aws_iotfleethub": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTFleetHub" - }, - "java": { - "package": "software.amazon.awscdk.services.iotfleethub" - }, - "python": { - "module": "aws_cdk.aws_iotfleethub" - } - } - }, - "aws-cdk-lib.aws_iotfleetwise": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTFleetWise" - }, - "java": { - "package": "software.amazon.awscdk.services.iotfleetwise" - }, - "python": { - "module": "aws_cdk.aws_iotfleetwise" - } - } - }, - "aws-cdk-lib.aws_iotsitewise": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTSiteWise" - }, - "java": { - "package": "software.amazon.awscdk.services.iotsitewise" - }, - "python": { - "module": "aws_cdk.aws_iotsitewise" - } - } - }, - "aws-cdk-lib.aws_iotthingsgraph": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTThingsGraph" - }, - "java": { - "package": "software.amazon.awscdk.services.iotthingsgraph" - }, - "python": { - "module": "aws_cdk.aws_iotthingsgraph" - } - } - }, - "aws-cdk-lib.aws_iottwinmaker": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTTwinMaker" - }, - "java": { - "package": "software.amazon.awscdk.services.iottwinmaker" - }, - "python": { - "module": "aws_cdk.aws_iottwinmaker" - } - } - }, - "aws-cdk-lib.aws_iotwireless": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IoTWireless" - }, - "java": { - "package": "software.amazon.awscdk.services.iotwireless" - }, - "python": { - "module": "aws_cdk.aws_iotwireless" - } - } - }, - "aws-cdk-lib.aws_ivs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Ivs" - }, - "java": { - "package": "software.amazon.awscdk.services.ivs" - }, - "python": { - "module": "aws_cdk.aws_ivs" - } - } - }, - "aws-cdk-lib.aws_ivschat": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.IVSChat" - }, - "java": { - "package": "software.amazon.awscdk.services.ivschat" - }, - "python": { - "module": "aws_cdk.aws_ivschat" - } - } - }, - "aws-cdk-lib.aws_kafkaconnect": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KafkaConnect" - }, - "java": { - "package": "software.amazon.awscdk.services.kafkaconnect" - }, - "python": { - "module": "aws_cdk.aws_kafkaconnect" - } - } - }, - "aws-cdk-lib.aws_kendra": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Kendra" - }, - "java": { - "package": "software.amazon.awscdk.services.kendra" - }, - "python": { - "module": "aws_cdk.aws_kendra" - } - } - }, - "aws-cdk-lib.aws_kendraranking": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KendraRanking" - }, - "java": { - "package": "software.amazon.awscdk.services.kendraranking" - }, - "python": { - "module": "aws_cdk.aws_kendraranking" - } - } - }, - "aws-cdk-lib.aws_kinesis": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Kinesis" - }, - "java": { - "package": "software.amazon.awscdk.services.kinesis" - }, - "python": { - "module": "aws_cdk.aws_kinesis" - } - } - }, - "aws-cdk-lib.aws_kinesisanalytics": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KinesisAnalytics" - }, - "java": { - "package": "software.amazon.awscdk.services.kinesisanalytics" - }, - "python": { - "module": "aws_cdk.aws_kinesisanalytics" - } - } - }, - "aws-cdk-lib.aws_kinesisanalyticsv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KinesisAnalyticsV2" - }, - "java": { - "package": "software.amazon.awscdk.services.kinesisanalyticsv2" - }, - "python": { - "module": "aws_cdk.aws_kinesisanalyticsv2" - } - } - }, - "aws-cdk-lib.aws_kinesisfirehose": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KinesisFirehose" - }, - "java": { - "package": "software.amazon.awscdk.services.kinesisfirehose" - }, - "python": { - "module": "aws_cdk.aws_kinesisfirehose" - } - } - }, - "aws-cdk-lib.aws_kinesisvideo": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KinesisVideo" - }, - "java": { - "package": "software.amazon.awscdk.services.kinesisvideo" - }, - "python": { - "module": "aws_cdk.aws_kinesisvideo" - } - } - }, - "aws-cdk-lib.aws_kms": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.KMS" - }, - "java": { - "package": "software.amazon.awscdk.services.kms" - }, - "python": { - "module": "aws_cdk.aws_kms" - } - } - }, - "aws-cdk-lib.aws_lakeformation": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.LakeFormation" - }, - "java": { - "package": "software.amazon.awscdk.services.lakeformation" - }, - "python": { - "module": "aws_cdk.aws_lakeformation" - } - } - }, - "aws-cdk-lib.aws_lambda": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lambda" - }, - "java": { - "package": "software.amazon.awscdk.services.lambda" - }, - "python": { - "module": "aws_cdk.aws_lambda" - } - } - }, - "aws-cdk-lib.aws_lambda_destinations": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lambda.Destinations" - }, - "java": { - "package": "software.amazon.awscdk.services.lambda.destinations" - }, - "python": { - "module": "aws_cdk.aws_lambda_destinations" - } - } - }, - "aws-cdk-lib.aws_lambda_event_sources": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lambda.EventSources" - }, - "java": { - "package": "software.amazon.awscdk.services.lambda.eventsources" - }, - "python": { - "module": "aws_cdk.aws_lambda_event_sources" - } - } - }, - "aws-cdk-lib.aws_lambda_nodejs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lambda.Nodejs" - }, - "java": { - "package": "software.amazon.awscdk.services.lambda.nodejs" - }, - "python": { - "module": "aws_cdk.aws_lambda_nodejs" - } - } - }, - "aws-cdk-lib.aws_lex": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lex" - }, - "java": { - "package": "software.amazon.awscdk.services.lex" - }, - "python": { - "module": "aws_cdk.aws_lex" - } - } - }, - "aws-cdk-lib.aws_licensemanager": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.LicenseManager" - }, - "java": { - "package": "software.amazon.awscdk.services.licensemanager" - }, - "python": { - "module": "aws_cdk.aws_licensemanager" - } - } - }, - "aws-cdk-lib.aws_lightsail": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Lightsail" - }, - "java": { - "package": "software.amazon.awscdk.services.lightsail" - }, - "python": { - "module": "aws_cdk.aws_lightsail" - } - } - }, - "aws-cdk-lib.aws_location": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Location" - }, - "java": { - "package": "software.amazon.awscdk.services.location" - }, - "python": { - "module": "aws_cdk.aws_location" - } - } - }, - "aws-cdk-lib.aws_logs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Logs" - }, - "java": { - "package": "software.amazon.awscdk.services.logs" - }, - "python": { - "module": "aws_cdk.aws_logs" - } - } - }, - "aws-cdk-lib.aws_logs_destinations": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Logs.Destinations" - }, - "java": { - "package": "software.amazon.awscdk.services.logs.destinations" - }, - "python": { - "module": "aws_cdk.aws_logs_destinations" - } - } - }, - "aws-cdk-lib.aws_lookoutequipment": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.LookoutEquipment" - }, - "java": { - "package": "software.amazon.awscdk.services.lookoutequipment" - }, - "python": { - "module": "aws_cdk.aws_lookoutequipment" - } - } - }, - "aws-cdk-lib.aws_lookoutmetrics": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.LookoutMetrics" - }, - "java": { - "package": "software.amazon.awscdk.services.lookoutmetrics" - }, - "python": { - "module": "aws_cdk.aws_lookoutmetrics" - } - } - }, - "aws-cdk-lib.aws_lookoutvision": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.LookoutVision" - }, - "java": { - "package": "software.amazon.awscdk.services.lookoutvision" - }, - "python": { - "module": "aws_cdk.aws_lookoutvision" - } - } - }, - "aws-cdk-lib.aws_m2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.M2" - }, - "java": { - "package": "software.amazon.awscdk.services.m2" - }, - "python": { - "module": "aws_cdk.aws_m2" - } - } - }, - "aws-cdk-lib.aws_macie": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Macie" - }, - "java": { - "package": "software.amazon.awscdk.services.macie" - }, - "python": { - "module": "aws_cdk.aws_macie" - } - } - }, - "aws-cdk-lib.aws_managedblockchain": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ManagedBlockchain" - }, - "java": { - "package": "software.amazon.awscdk.services.managedblockchain" - }, - "python": { - "module": "aws_cdk.aws_managedblockchain" - } - } - }, - "aws-cdk-lib.aws_mediaconnect": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaConnect" - }, - "java": { - "package": "software.amazon.awscdk.services.mediaconnect" - }, - "python": { - "module": "aws_cdk.aws_mediaconnect" - } - } - }, - "aws-cdk-lib.aws_mediaconvert": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaConvert" - }, - "java": { - "package": "software.amazon.awscdk.services.mediaconvert" - }, - "python": { - "module": "aws_cdk.aws_mediaconvert" - } - } - }, - "aws-cdk-lib.aws_medialive": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaLive" - }, - "java": { - "package": "software.amazon.awscdk.services.medialive" - }, - "python": { - "module": "aws_cdk.aws_medialive" - } - } - }, - "aws-cdk-lib.aws_mediapackage": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaPackage" - }, - "java": { - "package": "software.amazon.awscdk.services.mediapackage" - }, - "python": { - "module": "aws_cdk.aws_mediapackage" - } - } - }, - "aws-cdk-lib.aws_mediastore": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaStore" - }, - "java": { - "package": "software.amazon.awscdk.services.mediastore" - }, - "python": { - "module": "aws_cdk.aws_mediastore" - } - } - }, - "aws-cdk-lib.aws_mediatailor": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MediaTailor" - }, - "java": { - "package": "software.amazon.awscdk.services.mediatailor" - }, - "python": { - "module": "aws_cdk.aws_mediatailor" - } - } - }, - "aws-cdk-lib.aws_memorydb": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MemoryDB" - }, - "java": { - "package": "software.amazon.awscdk.services.memorydb" - }, - "python": { - "module": "aws_cdk.aws_memorydb" - } - } - }, - "aws-cdk-lib.aws_msk": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MSK" - }, - "java": { - "package": "software.amazon.awscdk.services.msk" - }, - "python": { - "module": "aws_cdk.aws_msk" - } - } - }, - "aws-cdk-lib.aws_mwaa": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.MWAA" - }, - "java": { - "package": "software.amazon.awscdk.services.mwaa" - }, - "python": { - "module": "aws_cdk.aws_mwaa" - } - } - }, - "aws-cdk-lib.aws_neptune": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Neptune" - }, - "java": { - "package": "software.amazon.awscdk.services.neptune" - }, - "python": { - "module": "aws_cdk.aws_neptune" - } - } - }, - "aws-cdk-lib.aws_networkfirewall": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.NetworkFirewall" - }, - "java": { - "package": "software.amazon.awscdk.services.networkfirewall" - }, - "python": { - "module": "aws_cdk.aws_networkfirewall" - } - } - }, - "aws-cdk-lib.aws_networkmanager": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.NetworkManager" - }, - "java": { - "package": "software.amazon.awscdk.services.networkmanager" - }, - "python": { - "module": "aws_cdk.aws_networkmanager" - } - } - }, - "aws-cdk-lib.aws_nimblestudio": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.NimbleStudio" - }, - "java": { - "package": "software.amazon.awscdk.services.nimblestudio" - }, - "python": { - "module": "aws_cdk.aws_nimblestudio" - } - } - }, - "aws-cdk-lib.aws_oam": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Oam" - }, - "java": { - "package": "software.amazon.awscdk.services.oam" - }, - "python": { - "module": "aws_cdk.aws_oam" - } - } - }, - "aws-cdk-lib.aws_omics": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Omics" - }, - "java": { - "package": "software.amazon.awscdk.services.omics" - }, - "python": { - "module": "aws_cdk.aws_omics" - } - } - }, - "aws-cdk-lib.aws_opensearchserverless": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.OpenSearchServerless" - }, - "java": { - "package": "software.amazon.awscdk.services.opensearchserverless" - }, - "python": { - "module": "aws_cdk.aws_opensearchserverless" - } - } - }, - "aws-cdk-lib.aws_opensearchservice": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.OpenSearchService" - }, - "java": { - "package": "software.amazon.awscdk.services.opensearchservice" - }, - "python": { - "module": "aws_cdk.aws_opensearchservice" - } - } - }, - "aws-cdk-lib.aws_opsworks": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.OpsWorks" - }, - "java": { - "package": "software.amazon.awscdk.services.opsworks" - }, - "python": { - "module": "aws_cdk.aws_opsworks" - } - } - }, - "aws-cdk-lib.aws_opsworkscm": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.OpsWorksCM" - }, - "java": { - "package": "software.amazon.awscdk.services.opsworkscm" - }, - "python": { - "module": "aws_cdk.aws_opsworkscm" - } - } - }, - "aws-cdk-lib.aws_organizations": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Organizations" - }, - "java": { - "package": "software.amazon.awscdk.services.organizations" - }, - "python": { - "module": "aws_cdk.aws_organizations" - } - } - }, - "aws-cdk-lib.aws_osis": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.OSIS" - }, - "java": { - "package": "services.osis" - }, - "python": { - "module": "aws_cdk.aws_osis" - } - } - }, - "aws-cdk-lib.aws_panorama": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Panorama" - }, - "java": { - "package": "software.amazon.awscdk.services.panorama" - }, - "python": { - "module": "aws_cdk.aws_panorama" - } - } - }, - "aws-cdk-lib.aws_personalize": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Personalize" - }, - "java": { - "package": "software.amazon.awscdk.services.personalize" - }, - "python": { - "module": "aws_cdk.aws_personalize" - } - } - }, - "aws-cdk-lib.aws_pinpoint": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Pinpoint" - }, - "java": { - "package": "software.amazon.awscdk.services.pinpoint" - }, - "python": { - "module": "aws_cdk.aws_pinpoint" - } - } - }, - "aws-cdk-lib.aws_pinpointemail": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.PinpointEmail" - }, - "java": { - "package": "software.amazon.awscdk.services.pinpointemail" - }, - "python": { - "module": "aws_cdk.aws_pinpointemail" - } - } - }, - "aws-cdk-lib.aws_pipes": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Pipes" - }, - "java": { - "package": "software.amazon.awscdk.services.pipes" - }, - "python": { - "module": "aws_cdk.aws_pipes" - } - } - }, - "aws-cdk-lib.aws_proton": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.Proton" - }, - "java": { - "package": "services.proton" - }, - "python": { - "module": "aws_cdk.aws_proton" - } - } - }, - "aws-cdk-lib.aws_qldb": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.QLDB" - }, - "java": { - "package": "software.amazon.awscdk.services.qldb" - }, - "python": { - "module": "aws_cdk.aws_qldb" - } - } - }, - "aws-cdk-lib.aws_quicksight": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.QuickSight" - }, - "java": { - "package": "software.amazon.awscdk.services.quicksight" - }, - "python": { - "module": "aws_cdk.aws_quicksight" - } - } - }, - "aws-cdk-lib.aws_ram": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RAM" - }, - "java": { - "package": "software.amazon.awscdk.services.ram" - }, - "python": { - "module": "aws_cdk.aws_ram" - } - } - }, - "aws-cdk-lib.aws_rds": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RDS" - }, - "java": { - "package": "software.amazon.awscdk.services.rds" - }, - "python": { - "module": "aws_cdk.aws_rds" - } - } - }, - "aws-cdk-lib.aws_redshift": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Redshift" - }, - "java": { - "package": "software.amazon.awscdk.services.redshift" - }, - "python": { - "module": "aws_cdk.aws_redshift" - } - } - }, - "aws-cdk-lib.aws_redshiftserverless": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RedshiftServerless" - }, - "java": { - "package": "software.amazon.awscdk.services.redshiftserverless" - }, - "python": { - "module": "aws_cdk.aws_redshiftserverless" - } - } - }, - "aws-cdk-lib.aws_refactorspaces": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RefactorSpaces" - }, - "java": { - "package": "software.amazon.awscdk.services.refactorspaces" - }, - "python": { - "module": "aws_cdk.aws_refactorspaces" - } - } - }, - "aws-cdk-lib.aws_rekognition": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Rekognition" - }, - "java": { - "package": "software.amazon.awscdk.services.rekognition" - }, - "python": { - "module": "aws_cdk.aws_rekognition" - } - } - }, - "aws-cdk-lib.aws_resiliencehub": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ResilienceHub" - }, - "java": { - "package": "software.amazon.awscdk.services.resiliencehub" - }, - "python": { - "module": "aws_cdk.aws_resiliencehub" - } - } - }, - "aws-cdk-lib.aws_resourceexplorer2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ResourceExplorer2" - }, - "java": { - "package": "software.amazon.awscdk.services.resourceexplorer2" - }, - "python": { - "module": "aws_cdk.aws_resourceexplorer2" - } - } - }, - "aws-cdk-lib.aws_resourcegroups": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ResourceGroups" - }, - "java": { - "package": "software.amazon.awscdk.services.resourcegroups" - }, - "python": { - "module": "aws_cdk.aws_resourcegroups" - } - } - }, - "aws-cdk-lib.aws_robomaker": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RoboMaker" - }, - "java": { - "package": "software.amazon.awscdk.services.robomaker" - }, - "python": { - "module": "aws_cdk.aws_robomaker" - } - } - }, - "aws-cdk-lib.aws_rolesanywhere": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RolesAnywhere" - }, - "java": { - "package": "software.amazon.awscdk.services.rolesanywhere" - }, - "python": { - "module": "aws_cdk.aws_rolesanywhere" - } - } - }, - "aws-cdk-lib.aws_route53": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53" - }, - "java": { - "package": "software.amazon.awscdk.services.route53" - }, - "python": { - "module": "aws_cdk.aws_route53" - } - } - }, - "aws-cdk-lib.aws_route53_patterns": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53.Patterns" - }, - "java": { - "package": "software.amazon.awscdk.services.route53.patterns" - }, - "python": { - "module": "aws_cdk.aws_route53_patterns" - } - } - }, - "aws-cdk-lib.aws_route53_targets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53.Targets" - }, - "java": { - "package": "software.amazon.awscdk.services.route53.targets" - }, - "python": { - "module": "aws_cdk.aws_route53_targets" - } - } - }, - "aws-cdk-lib.aws_route53recoverycontrol": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53RecoveryControl" - }, - "java": { - "package": "software.amazon.awscdk.services.route53recoverycontrol" - }, - "python": { - "module": "aws_cdk.aws_route53recoverycontrol" - } - } - }, - "aws-cdk-lib.aws_route53recoveryreadiness": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53RecoveryReadiness" - }, - "java": { - "package": "software.amazon.awscdk.services.route53recoveryreadiness" - }, - "python": { - "module": "aws_cdk.aws_route53recoveryreadiness" - } - } - }, - "aws-cdk-lib.aws_route53resolver": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Route53Resolver" - }, - "java": { - "package": "software.amazon.awscdk.services.route53resolver" - }, - "python": { - "module": "aws_cdk.aws_route53resolver" - } - } - }, - "aws-cdk-lib.aws_rum": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.RUM" - }, - "java": { - "package": "software.amazon.awscdk.services.rum" - }, - "python": { - "module": "aws_cdk.aws_rum" - } - } - }, - "aws-cdk-lib.aws_s3": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3" - }, - "java": { - "package": "software.amazon.awscdk.services.s3" - }, - "python": { - "module": "aws_cdk.aws_s3" - } - } - }, - "aws-cdk-lib.aws_s3_assets": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3.Assets" - }, - "java": { - "package": "software.amazon.awscdk.services.s3.assets" - }, - "python": { - "module": "aws_cdk.aws_s3_assets" - } - } - }, - "aws-cdk-lib.aws_s3_deployment": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3.Deployment" - }, - "java": { - "package": "software.amazon.awscdk.services.s3.deployment" - }, - "python": { - "module": "aws_cdk.aws_s3_deployment" - } - } - }, - "aws-cdk-lib.aws_s3_notifications": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3.Notifications" - }, - "java": { - "package": "software.amazon.awscdk.services.s3.notifications" - }, - "python": { - "module": "aws_cdk.aws_s3_notifications" - } - } - }, - "aws-cdk-lib.aws_s3objectlambda": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3ObjectLambda" - }, - "java": { - "package": "software.amazon.awscdk.services.s3objectlambda" - }, - "python": { - "module": "aws_cdk.aws_s3objectlambda" - } - } - }, - "aws-cdk-lib.aws_s3outposts": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.S3Outposts" - }, - "java": { - "package": "software.amazon.awscdk.services.s3outposts" - }, - "python": { - "module": "aws_cdk.aws_s3outposts" - } - } - }, - "aws-cdk-lib.aws_sagemaker": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Sagemaker" - }, - "java": { - "package": "software.amazon.awscdk.services.sagemaker" - }, - "python": { - "module": "aws_cdk.aws_sagemaker" - } - } - }, - "aws-cdk-lib.aws_sam": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SAM" - }, - "java": { - "package": "software.amazon.awscdk.services.sam" - }, - "python": { - "module": "aws_cdk.aws_sam" - } - } - }, - "aws-cdk-lib.aws_scheduler": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Scheduler" - }, - "java": { - "package": "software.amazon.awscdk.services.scheduler" - }, - "python": { - "module": "aws_cdk.aws_scheduler" - } - } - }, - "aws-cdk-lib.aws_sdb": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SDB" - }, - "java": { - "package": "software.amazon.awscdk.services.sdb" - }, - "python": { - "module": "aws_cdk.aws_sdb" - } - } - }, - "aws-cdk-lib.aws_secretsmanager": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SecretsManager" - }, - "java": { - "package": "software.amazon.awscdk.services.secretsmanager" - }, - "python": { - "module": "aws_cdk.aws_secretsmanager" - } - } - }, - "aws-cdk-lib.aws_securityhub": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SecurityHub" - }, - "java": { - "package": "software.amazon.awscdk.services.securityhub" - }, - "python": { - "module": "aws_cdk.aws_securityhub" - } - } - }, - "aws-cdk-lib.aws_servicecatalog": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Servicecatalog" - }, - "java": { - "package": "software.amazon.awscdk.services.servicecatalog" - }, - "python": { - "module": "aws_cdk.aws_servicecatalog" - } - } - }, - "aws-cdk-lib.aws_servicecatalogappregistry": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Servicecatalogappregistry" - }, - "java": { - "package": "software.amazon.awscdk.services.servicecatalogappregistry" - }, - "python": { - "module": "aws_cdk.aws_servicecatalogappregistry" - } - } - }, - "aws-cdk-lib.aws_servicediscovery": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.ServiceDiscovery" - }, - "java": { - "package": "software.amazon.awscdk.services.servicediscovery" - }, - "python": { - "module": "aws_cdk.aws_servicediscovery" - } - } - }, - "aws-cdk-lib.aws_ses": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SES" - }, - "java": { - "package": "software.amazon.awscdk.services.ses" - }, - "python": { - "module": "aws_cdk.aws_ses" - } - } - }, - "aws-cdk-lib.aws_ses_actions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SES.Actions" - }, - "java": { - "package": "software.amazon.awscdk.services.ses.actions" - }, - "python": { - "module": "aws_cdk.aws_ses_actions" - } - } - }, - "aws-cdk-lib.aws_shield": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.Shield" - }, - "java": { - "package": "services.shield" - }, - "python": { - "module": "aws_cdk.aws_shield" - } - } - }, - "aws-cdk-lib.aws_signer": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Signer" - }, - "java": { - "package": "software.amazon.awscdk.services.signer" - }, - "python": { - "module": "aws_cdk.aws_signer" - } - } - }, - "aws-cdk-lib.aws_simspaceweaver": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SimSpaceWeaver" - }, - "java": { - "package": "software.amazon.awscdk.services.simspaceweaver" - }, - "python": { - "module": "aws_cdk.aws_simspaceweaver" - } - } - }, - "aws-cdk-lib.aws_sns": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SNS" - }, - "java": { - "package": "software.amazon.awscdk.services.sns" - }, - "python": { - "module": "aws_cdk.aws_sns" - } - } - }, - "aws-cdk-lib.aws_sns_subscriptions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SNS.Subscriptions" - }, - "java": { - "package": "software.amazon.awscdk.services.sns.subscriptions" - }, - "python": { - "module": "aws_cdk.aws_sns_subscriptions" - } - } - }, - "aws-cdk-lib.aws_sqs": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SQS" - }, - "java": { - "package": "software.amazon.awscdk.services.sqs" - }, - "python": { - "module": "aws_cdk.aws_sqs" - } - } - }, - "aws-cdk-lib.aws_ssm": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SSM" - }, - "java": { - "package": "software.amazon.awscdk.services.ssm" - }, - "python": { - "module": "aws_cdk.aws_ssm" - } - } - }, - "aws-cdk-lib.aws_ssmcontacts": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SSMContacts" - }, - "java": { - "package": "software.amazon.awscdk.services.ssmcontacts" - }, - "python": { - "module": "aws_cdk.aws_ssmcontacts" - } - } - }, - "aws-cdk-lib.aws_ssmincidents": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SSMIncidents" - }, - "java": { - "package": "software.amazon.awscdk.services.ssmincidents" - }, - "python": { - "module": "aws_cdk.aws_ssmincidents" - } - } - }, - "aws-cdk-lib.aws_sso": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SSO" - }, - "java": { - "package": "software.amazon.awscdk.services.sso" - }, - "python": { - "module": "aws_cdk.aws_sso" - } - } - }, - "aws-cdk-lib.aws_stepfunctions": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.StepFunctions" - }, - "java": { - "package": "software.amazon.awscdk.services.stepfunctions" - }, - "python": { - "module": "aws_cdk.aws_stepfunctions" - } - } - }, - "aws-cdk-lib.aws_stepfunctions_tasks": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.StepFunctions.Tasks" - }, - "java": { - "package": "software.amazon.awscdk.services.stepfunctions.tasks" - }, - "python": { - "module": "aws_cdk.aws_stepfunctions_tasks" - } - } - }, - "aws-cdk-lib.aws_supportapp": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SupportApp" - }, - "java": { - "package": "software.amazon.awscdk.services.supportapp" - }, - "python": { - "module": "aws_cdk.aws_supportapp" - } - } - }, - "aws-cdk-lib.aws_synthetics": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Synthetics" - }, - "java": { - "package": "software.amazon.awscdk.services.synthetics" - }, - "python": { - "module": "aws_cdk.aws_synthetics" - } - } - }, - "aws-cdk-lib.aws_systemsmanagersap": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.SystemsManagerSAP" - }, - "java": { - "package": "software.amazon.awscdk.services.systemsmanagersap" - }, - "python": { - "module": "aws_cdk.aws_systemsmanagersap" - } - } - }, - "aws-cdk-lib.aws_timestream": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Timestream" - }, - "java": { - "package": "software.amazon.awscdk.services.timestream" - }, - "python": { - "module": "aws_cdk.aws_timestream" - } - } - }, - "aws-cdk-lib.aws_transfer": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Transfer" - }, - "java": { - "package": "software.amazon.awscdk.services.transfer" - }, - "python": { - "module": "aws_cdk.aws_transfer" - } - } - }, - "aws-cdk-lib.aws_verifiedpermissions": { - "targets": { - "dotnet": { - "package": "Amazon.CDK.AWS.VerifiedPermissions" - }, - "java": { - "package": "services.verifiedpermissions" - }, - "python": { - "module": "aws_cdk.aws_verifiedpermissions" - } - } - }, - "aws-cdk-lib.aws_voiceid": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.VoiceID" - }, - "java": { - "package": "software.amazon.awscdk.services.voiceid" - }, - "python": { - "module": "aws_cdk.aws_voiceid" - } - } - }, - "aws-cdk-lib.aws_vpclattice": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.VpcLattice" - }, - "java": { - "package": "software.amazon.awscdk.services.vpclattice" - }, - "python": { - "module": "aws_cdk.aws_vpclattice" - } - } - }, - "aws-cdk-lib.aws_waf": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.WAF" - }, - "java": { - "package": "software.amazon.awscdk.services.waf" - }, - "python": { - "module": "aws_cdk.aws_waf" - } - } - }, - "aws-cdk-lib.aws_wafregional": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.WAFRegional" - }, - "java": { - "package": "software.amazon.awscdk.services.waf.regional" - }, - "python": { - "module": "aws_cdk.aws_wafregional" - } - } - }, - "aws-cdk-lib.aws_wafv2": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.WAFv2" - }, - "java": { - "package": "software.amazon.awscdk.services.wafv2" - }, - "python": { - "module": "aws_cdk.aws_wafv2" - } - } - }, - "aws-cdk-lib.aws_wisdom": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.Wisdom" - }, - "java": { - "package": "software.amazon.awscdk.services.wisdom" - }, - "python": { - "module": "aws_cdk.aws_wisdom" - } - } - }, - "aws-cdk-lib.aws_workspaces": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.WorkSpaces" - }, - "java": { - "package": "software.amazon.awscdk.services.workspaces" - }, - "python": { - "module": "aws_cdk.aws_workspaces" - } - } - }, - "aws-cdk-lib.aws_xray": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.AWS.XRay" - }, - "java": { - "package": "software.amazon.awscdk.services.xray" - }, - "python": { - "module": "aws_cdk.aws_xray" - } - } - }, - "aws-cdk-lib.cloud_assembly_schema": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.CloudAssembly.Schema" - }, - "java": { - "package": "software.amazon.awscdk.cloudassembly.schema" - }, - "python": { - "module": "aws_cdk.cloud_assembly_schema" - } - } - }, - "aws-cdk-lib.cloudformation_include": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.CloudFormation.Include" - }, - "java": { - "package": "software.amazon.awscdk.cloudformation.include" - }, - "python": { - "module": "aws_cdk.cloudformation_include" - } - } - }, - "aws-cdk-lib.custom_resources": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.CustomResources" - }, - "java": { - "package": "software.amazon.awscdk.customresources" - }, - "python": { - "module": "aws_cdk.custom_resources" - } - } - }, - "aws-cdk-lib.cx_api": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.CXAPI" - }, - "java": { - "package": "software.amazon.awscdk.cxapi" - }, - "python": { - "module": "aws_cdk.cx_api" - } - } - }, - "aws-cdk-lib.lambda_layer_awscli": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.LambdaLayer.AwsCli" - }, - "java": { - "package": "software.amazon.awscdk.lambdalayer.awscli" - }, - "python": { - "module": "aws_cdk.lambda_layer_awscli" - } - } - }, - "aws-cdk-lib.lambda_layer_kubectl": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.LambdaLayer.Kubectl" - }, - "java": { - "package": "software.amazon.awscdk.lambdalayer.kubectl" - }, - "python": { - "module": "aws_cdk.lambda_layer_kubectl" - } - } - }, - "aws-cdk-lib.lambda_layer_node_proxy_agent": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.LambdaLayer.NodeProxyAgent" - }, - "java": { - "package": "software.amazon.awscdk.lambda.layer.node.proxy.agent" - }, - "python": { - "module": "aws_cdk.lambda_layer_node_proxy_agent" - } - } - }, - "aws-cdk-lib.pipelines": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Pipelines" - }, - "java": { - "package": "software.amazon.awscdk.pipelines" - }, - "python": { - "module": "aws_cdk.pipelines" - } - } - }, - "aws-cdk-lib.region_info": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.RegionInfo" - }, - "java": { - "package": "software.amazon.awscdk.regioninfo" - }, - "python": { - "module": "aws_cdk.region_info" - } - } - }, - "aws-cdk-lib.triggers": { - "targets": { - "dotnet": { - "namespace": "Amazon.CDK.Triggers" - }, - "java": { - "package": "software.amazon.awscdk.triggers" - }, - "python": { - "module": "aws_cdk.triggers" - } - } - } - }, - "targets": { - "dotnet": { - "iconUrl": "https://raw.githubusercontent.com/aws/aws-cdk/main/logo/default-256-dark.png", - "namespace": "Amazon.CDK", - "packageId": "Amazon.CDK.Lib" - }, - "go": { - "moduleName": "github.com/aws/aws-cdk-go", - "packageName": "awscdk" - }, - "java": { - "maven": { - "artifactId": "aws-cdk-lib", - "groupId": "software.amazon.awscdk" - }, - "package": "software.amazon.awscdk" - }, - "js": { - "npm": "aws-cdk-lib" - }, - "python": { - "distName": "aws-cdk-lib", - "module": "aws_cdk" - } - } - }, - "constructs": { - "targets": { - "dotnet": { - "namespace": "Constructs", - "packageId": "Constructs" - }, - "go": { - "moduleName": "github.com/aws/constructs-go" - }, - "java": { - "maven": { - "artifactId": "constructs", - "groupId": "software.constructs" - }, - "package": "software.constructs" - }, - "js": { - "npm": "constructs" - }, - "python": { - "distName": "constructs", - "module": "constructs" - } - } - } - }, - "description": "The CDK Construct Library for AWS::Batch", - "docs": { - "stability": "experimental" - }, - "homepage": "https://github.com/aws/aws-cdk", - "jsiiVersion": "5.1.12 (build 0675712)", - "keywords": [ - "aws", - "cdk", - "constructs", - "batch" - ], - "license": "Apache-2.0", - "metadata": { - "jsii": { - "compiledWithDeprecationWarnings": true, - "pacmak": { - "hasDefaultInterfaces": true - }, - "rosetta": { - "strict": true - } - } - }, - "name": "@aws-cdk/aws-batch-alpha", - "readme": { - "markdown": "# AWS Batch Construct Library\n\n\n---\n\n![cdk-constructs: Developer Preview](https://img.shields.io/badge/cdk--constructs-developer--preview-informational.svg?style=for-the-badge)\n\n> The APIs of higher level constructs in this module are in **developer preview** before they\n> become stable. We will only make breaking changes to address unforeseen API issues. Therefore,\n> these APIs are not subject to [Semantic Versioning](https://semver.org/), and breaking changes\n> will be announced in release notes. This means that while you may use them, you may need to\n> update your source code when upgrading to a newer version of this package.\n\n---\n\n\n\nThis module is part of the [AWS Cloud Development Kit](https://github.com/aws/aws-cdk) project.\n\nAWS Batch is a batch processing tool for efficiently running hundreds of thousands computing jobs in AWS.\nBatch can dynamically provision [Amazon EC2](https://aws.amazon.com/ec2/) Instances to meet the resource requirements of submitted jobs\nand simplifies the planning, scheduling, and executions of your batch workloads. Batch achieves this through four different resources:\n\n* ComputeEnvironments: Contain the resources used to execute Jobs\n* JobDefinitions: Define a type of Job that can be submitted\n* JobQueues: Route waiting Jobs to ComputeEnvironments\n* SchedulingPolicies: Applied to Queues to control how and when Jobs exit the JobQueue and enter the ComputeEnvironment\n\n`ComputeEnvironment`s can be managed or unmanaged. Batch will automatically provision EC2 Instances in a managed `ComputeEnvironment` and will\nnot provision any Instances in an unmanaged `ComputeEnvironment`. Managed `ComputeEnvironment`s can use ECS, Fargate, or EKS resources to spin up\nEC2 Instances in (ensure your EKS Cluster has [been configured](https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html)\nto support a Batch ComputeEnvironment before linking it). You can use Launch Templates and Placement Groups to configure exactly how these resources\nwill be provisioned.\n\n`JobDefinition`s can use either ECS resources or EKS resources. ECS `JobDefinition`s can use multiple containers to execute distributed workloads.\nEKS `JobDefinition`s can only execute a single container. Submitted Jobs use `JobDefinition`s as templates.\n\n`JobQueue`s must link at least one `ComputeEnvironment`. Jobs exit the Queue in FIFO order unless a `SchedulingPolicy` is specified.\n\n`SchedulingPolicy`s tell the Scheduler how to choose which Jobs should be executed next by the ComputeEnvironment.\n\n## Use Cases & Examples\n\n### Cost Optimization\n\n#### Spot Instances\n\nSpot instances are significantly discounted EC2 instances that can be reclaimed at any time by AWS.\nWorkloads that are fault-tolerant or stateless can take advantage of spot pricing.\nTo use spot spot instances, set `spot` to `true` on a managed Ec2 or Fargate Compute Environment:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\nnew batch.FargateComputeEnvironment(this, 'myFargateComputeEnv', {\n vpc,\n spot: true,\n});\n```\n\nBatch allows you to specify the percentage of the on-demand instance that the current spot price\nmust be to provision the instance using the `spotBidPercentage`.\nThis defaults to 100%, which is the recommended value.\nThis value cannot be specified for `FargateComputeEnvironment`s\nand only applies to `ManagedEc2EcsComputeEnvironment`s.\nThe following code configures a Compute Environment to only use spot instances that\nare at most 20% the price of the on-demand instance price:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n spot: true,\n spotBidPercentage: 20,\n});\n```\n\nFor stateful or otherwise non-interruption-tolerant workflows, omit `spot` or set it to `false` to only provision on-demand instances.\n\n#### Choosing Your Instance Types\n\nBatch allows you to choose the instance types or classes that will run your workload.\nThis example configures your `ComputeEnvironment` to use only the `M5AD.large` instance:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\n\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE)],\n});\n```\n\nBatch allows you to specify only the instance class and to let it choose the size, which you can do like this:\n\n```ts\nconst vpc = new ec2.Vpc(this, 'VPC');\n\ndeclare const computeEnv: batch.IManagedEc2EcsComputeEnvironment\ncomputeEnv.addInstanceClass(ec2.InstanceClass.M5AD);\n// Or, specify it on the constructor:\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.R4],\n});\n```\n\nUnless you explicitly specify `useOptimalInstanceClasses: false`, this compute environment will use `'optimal'` instances,\nwhich tells Batch to pick an instance from the C4, M4, and R4 instance families.\n*Note*: Batch does not allow specifying instance types or classes with different architectures.\nFor example, `InstanceClass.A1` cannot be specified alongside `'optimal'`,\nbecause `A1` uses ARM and `'optimal'` uses x86_64.\nYou can specify both `'optimal'` alongside several different instance types in the same compute environment:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE)],\n useOptimalInstanceClasses: true, // default\n vpc,\n});\n// Note: this is equivalent to specifying\ncomputeEnv.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.M5AD, ec2.InstanceSize.LARGE));\ncomputeEnv.addInstanceClass(ec2.InstanceClass.C4);\ncomputeEnv.addInstanceClass(ec2.InstanceClass.M4);\ncomputeEnv.addInstanceClass(ec2.InstanceClass.R4);\n```\n\n#### Allocation Strategies\n\n| Allocation Strategy | Optimized for | Downsides |\n| ----------------------- | ------------- | ----------------------------- |\n| BEST_FIT | Cost | May limit throughput |\n| BEST_FIT_PROGRESSIVE | Throughput | May increase cost |\n| SPOT_CAPACITY_OPTIMIZED | Least interruption | Only useful on Spot instances |\n| SPOT_PRICE_CAPACITY_OPTIMIZED | Least interruption + Price | Only useful on Spot instances |\n\nBatch provides different Allocation Strategies to help it choose which instances to provision.\nIf your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment`\nand use `SPOT_PRICE_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled).\nThis will tell Batch to choose the instance types from the ones you’ve specified that have\nthe most spot capacity available to minimize the chance of interruption and have the lowest price.\nTo get the most benefit from your spot instances,\nyou should allow Batch to choose from as many different instance types as possible.\nIf you only care about minimal interruptions and not want Batch to optimize for cost, use\n`SPOT_CAPACITY_OPTIMIZED`. `SPOT_PRICE_CAPACITY_OPTIMIZED` is recommended over `SPOT_CAPACITY_OPTIMIZED`\nfor most use cases.\n\nIf your workflow does not tolerate interruptions and you want to minimize your costs at the expense\nof potentially longer waiting times, use `AllocationStrategy.BEST_FIT`.\nThis will choose the lowest-cost instance type that fits all the jobs in the queue.\nIf instances of that type are not available,\nthe queue will not choose a new type; instead, it will wait for the instance to become available.\nThis can stall your `Queue`, with your compute environment only using part of its max capacity\n(or none at all) until the `BEST_FIT` instance becomes available.\n\nIf you are running a workflow that does not tolerate interruptions and you want to maximize throughput,\nyou can use `AllocationStrategy.BEST_FIT_PROGRESSIVE`.\nThis is the default Allocation Strategy if `spot` is `false` or unspecified.\nThis strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements\nof the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`.\nHowever, if not all of the capacity can be filled with this instance type,\nit will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity.\nTo make the most use of this allocation strategy,\nit is recommended to use as many instance classes as is feasible for your workload.\nThis example shows a `ComputeEnvironment` that uses `BEST_FIT_PROGRESSIVE`\nwith `'optimal'` and `InstanceClass.M5` instance types:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.M5],\n});\n```\n\nThis example shows a `ComputeEnvironment` that uses `BEST_FIT` with `'optimal'` instances:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nconst computeEnv = new batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n allocationStrategy: batch.AllocationStrategy.BEST_FIT,\n});\n```\n\n*Note*: `allocationStrategy` cannot be specified on Fargate Compute Environments.\n\n### Controlling vCPU allocation\n\nYou can specify the maximum and minimum vCPUs a managed `ComputeEnvironment` can have at any given time.\nBatch will *always* maintain `minvCpus` worth of instances in your ComputeEnvironment, even if it is not executing any jobs,\nand even if it is disabled. Batch will scale the instances up to `maxvCpus` worth of instances as\njobs exit the JobQueue and enter the ComputeEnvironment. If you use `AllocationStrategy.BEST_FIT_PROGRESSIVE`,\n`AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED`, or `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`,\nbatch may exceed `maxvCpus`; it will never exceed `maxvCpus` by more than a single instance type. This example configures a\n`minvCpus` of 10 and a `maxvCpus` of 100:\n\n```ts\ndeclare const vpc: ec2.IVpc;\n\nnew batch.ManagedEc2EcsComputeEnvironment(this, 'myEc2ComputeEnv', {\n vpc,\n instanceClasses: [ec2.InstanceClass.R4],\n minvCpus: 10,\n maxvCpus: 100,\n});\n```\n\n### Tagging Instances\n\nYou can tag any instances launched by your managed EC2 ComputeEnvironments by using the CDK `Tags` API:\n\n```ts\nimport { Tags } from 'aws-cdk-lib';\n\ndeclare const vpc: ec2.IVpc;\n\nconst tagCE = new batch.ManagedEc2EcsComputeEnvironment(this, 'CEThatMakesTaggedInstnaces', {\n vpc,\n});\n\nTags.of(tagCE).add('super', 'salamander');\n```\n\nUnmanaged `ComputeEnvironment`s do not support `maxvCpus` or `minvCpus` because you must provision and manage the instances yourself;\nthat is, Batch will not scale them up and down as needed.\n\n### Sharing a ComputeEnvironment between multiple JobQueues\n\nMultiple `JobQueue`s can share the same `ComputeEnvironment`.\nIf multiple Queues are attempting to submit Jobs to the same `ComputeEnvironment`,\nBatch will pick the Job from the Queue with the highest priority.\nThis example creates two `JobQueue`s that share a `ComputeEnvironment`:\n\n```ts\ndeclare const vpc: ec2.IVpc;\nconst sharedComputeEnv = new batch.FargateComputeEnvironment(this, 'spotEnv', {\n vpc,\n spot: true,\n});\nconst lowPriorityQueue = new batch.JobQueue(this, 'JobQueue', {\n priority: 1,\n});\nconst highPriorityQueue = new batch.JobQueue(this, 'JobQueue', {\n priority: 10,\n});\nlowPriorityQueue.addComputeEnvironment(sharedComputeEnv, 1);\nhighPriorityQueue.addComputeEnvironment(sharedComputeEnv, 1);\n```\n\n### Fairshare Scheduling\n\nBatch `JobQueue`s execute Jobs submitted to them in FIFO order unless you specify a `SchedulingPolicy`.\nFIFO queuing can cause short-running jobs to be starved while long-running jobs fill the compute environment.\nTo solve this, Jobs can be associated with a share.\n\nShares consist of a `shareIdentifier` and a `weightFactor`, which is inversely correlated with the vCPU allocated to that share identifier.\nWhen submitting a Job, you can specify its `shareIdentifier` to associate that particular job with that share.\nLet's see how the scheduler uses this information to schedule jobs.\n\nFor example, if there are two shares defined as follows:\n\n| Share Identifier | Weight Factor |\n| ---------------- | ------------- |\n| A | 1 |\n| B | 1 |\n\nThe weight factors share the following relationship:\n\n```math\nA_{vCpus} / A_{Weight} = B_{vCpus} / B_{Weight}\n```\n\nwhere `BvCpus` is the number of vCPUs allocated to jobs with share identifier `'B'`, and `B_weight` is the weight factor of `B`.\n\nThe total number of vCpus allocated to a share is equal to the amount of jobs in that share times the number of vCpus necessary for every job.\nLet's say that each A job needs 32 VCpus (`A_requirement` = 32) and each B job needs 64 vCpus (`B_requirement` = 64):\n\n```math\nA_{vCpus} = A_{Jobs} * A_{Requirement}\n```\n\n```math\nB_{vCpus} = B_{Jobs} * B_{Requirement}\n```\n\nWe have:\n\n```math\nA_{vCpus} / A_{Weight} = B_{vCpus} / B_{Weight}\n```\n\n```math\nA_{Jobs} * A_{Requirement} / A_{Weight} = B_{Jobs} * B_{Requirement} / B_{Weight}\n```\n\n```math\nA_{Jobs} * 32 / 1 = B_{Jobs} * 64 / 1\n```\n\n```math\nA_{Jobs} * 32 = B_{Jobs} * 64\n```\n\n```math\nA_{Jobs} = B_{Jobs} * 2\n```\n\nThus the scheduler will schedule two `'A'` jobs for each `'B'` job.\n\nYou can control the weight factors to change these ratios, but note that\nweight factors are inversely correlated with the vCpus allocated to the corresponding share.\n\nThis example would be configured like this:\n\n```ts\nconst fairsharePolicy = new batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy');\n\nfairsharePolicy.addShare({\n shareIdentifier: 'A',\n weightFactor: 1,\n});\nfairsharePolicy.addShare({\n shareIdentifier: 'B',\n weightFactor: 1,\n});\nnew batch.JobQueue(this, 'JobQueue', {\n schedulingPolicy: fairsharePolicy,\n});\n```\n\n*Note*: The scheduler will only consider the current usage of the compute environment unless you specify `shareDecay`.\nFor example, a `shareDecay` of 5 minutes in the above example means that at any given point in time, twice as many `'A'` jobs\nwill be scheduled for each `'B'` job, but only for the past 5 minutes. If `'B'` jobs run longer than 5 minutes, then\nthe scheduler is allowed to put more than two `'A'` jobs for each `'B'` job, because the usage of those long-running\n`'B'` jobs will no longer be considered after 5 minutes. `shareDecay` linearly decreases the usage of\nlong running jobs for calculation purposes. For example if share decay is 60 seconds,\nthen jobs that run for 30 seconds have their usage considered to be only 50% of what it actually is,\nbut after a whole minute the scheduler pretends they don't exist for fairness calculations.\n\nThe following code specifies a `shareDecay` of 5 minutes:\n\n```ts\nimport * as cdk from 'aws-cdk-lib'\nconst fairsharePolicy = new batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy', {\n shareDecay: cdk.Duration.minutes(5),\n});\n```\n\nIf you have high priority jobs that should always be executed as soon as they arrive,\nyou can define a `computeReservation` to specify the percentage of the\nmaximum vCPU capacity that should be reserved for shares that are *not in the queue*.\nThe actual reserved percentage is defined by Batch as:\n\n```math\n (\\frac{computeReservation}{100}) ^ {ActiveFairShares}\n```\n\nwhere `ActiveFairShares` is the number of shares for which there exists\nat least one job in the queue with a unique share identifier.\n\nThis is best illustrated with an example.\nSuppose there are three shares with share identifiers `A`, `B` and `C` respectively\nand we specify the `computeReservation` to be 75%. The queue is currently empty,\nand no other shares exist.\n\nThere are no active fair shares, since the queue is empty.\nThus (75/100)^0 = 1 = 100% of the maximum vCpus are reserved for all shares.\n\nA job with identifier `A` enters the queue.\n\nThe number of active fair shares is now 1, hence\n(75/100)^1 = .75 = 75% of the maximum vCpus are reserved for all shares that do not have the identifier `A`;\nfor this example, this is `B` and `C`,\n(but if jobs are submitted with a share identifier not covered by this fairshare policy, those would be considered just as `B` and `C` are).\n\nNow a `B` job enters the queue. The number of active fair shares is now 2,\nso (75/100)^2 = .5625 = 56.25% of the maximum vCpus are reserved for all shares that do not have the identifier `A` or `B`.\n\nNow a second `A` job enters the queue. The number of active fair shares is still 2,\nso the percentage reserved is still 56.25%\n\nNow a `C` job enters the queue. The number of active fair shares is now 3,\nso (75/100)^3 = .421875 = 42.1875% of the maximum vCpus are reserved for all shares that do not have the identifier `A`, `B`, or `C`.\n\nIf there are no other shares that your jobs can specify, this means that 42.1875% of your capacity will never be used!\n\nNow, `A`, `B`, and `C` can only consume 100% - 42.1875% = 57.8125% of the maximum vCpus.\nNote that the this percentage is **not** split between `A`, `B`, and `C`.\nInstead, the scheduler will use their `weightFactor`s to decide which jobs to schedule;\nthe only difference is that instead of competing for 100% of the max capacity, jobs compete for 57.8125% of the max capacity.\n\nThis example specifies a `computeReservation` of 75% that will behave as explained in the example above:\n\n```ts\nnew batch.FairshareSchedulingPolicy(this, 'myFairsharePolicy', {\n computeReservation: 75,\n shares: [\n { weightFactor: 1, shareIdentifier: 'A' },\n { weightFactor: 0.5, shareIdentifier: 'B' },\n { weightFactor: 2, shareIdentifier: 'C' },\n ],\n});\n```\n\nYou can specify a `priority` on your `JobDefinition`s to tell the scheduler to prioritize certain jobs that share the same share identifier.\n\n### Configuring Job Retry Policies\n\nCertain workflows may result in Jobs failing due to intermittent issues.\nJobs can specify retry policies to respond to different failures with different actions.\nThere are three different ways information about the way a Job exited can be conveyed;\n\n* `exitCode`: the exit code returned from the process executed by the container. Will only match non-zero exit codes.\n* `reason`: any middleware errors, like your Docker registry being down.\n* `statusReason`: infrastructure errors, most commonly your spot instance being reclaimed.\n\nFor most use cases, only one of these will be associated with a particular action at a time.\nTo specify common `exitCode`s, `reason`s, or `statusReason`s, use the corresponding value from\nthe `Reason` class. This example shows some common failure reasons:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n }),\n retryAttempts: 5,\n retryStrategies: [\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER),\n ],\n});\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.SPOT_INSTANCE_RECLAIMED),\n);\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER),\n);\njobDefn.addRetryStrategy(\n batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.custom({\n onExitCode: '40*',\n onReason: 'some reason',\n })),\n);\n```\n\nWhen specifying a custom reason,\nyou can specify a glob string to match each of these and react to different failures accordingly.\nUp to five different retry strategies can be configured for each Job,\nand each strategy can match against some or all of `exitCode`, `reason`, and `statusReason`.\nYou can optionally configure the number of times a job will be retried,\nbut you cannot configure different retry counts for different strategies; they all share the same count.\nIf multiple conditions are specified in a given retry strategy,\nthey must all match for the action to be taken; the conditions are ANDed together, not ORed.\n\n### Running single-container ECS workflows\n\nBatch can run jobs on ECS or EKS. ECS jobs can be defined as single container or multinode.\nThis example creates a `JobDefinition` that runs a single container with ECS:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nimport * as iam from 'aws-cdk-lib/aws-iam';\nimport * as efs from 'aws-cdk-lib/aws-efs';\n\ndeclare const myFileSystem: efs.IFileSystem;\ndeclare const myJobRole: iam.Role;\nmyFileSystem.grantRead(myJobRole);\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n volumes: [batch.EcsVolume.efs({\n name: 'myVolume',\n fileSystem: myFileSystem,\n containerPath: '/Volumes/myVolume',\n useJobRole: true,\n })],\n jobRole: myJobRole,\n }),\n});\n```\n\nFor workflows that need persistent storage, batch supports mounting `Volume`s to the container.\nYou can both provision the volume and mount it to the container in a single operation:\n\n```ts\nimport * as efs from 'aws-cdk-lib/aws-efs';\n\ndeclare const myFileSystem: efs.IFileSystem;\ndeclare const jobDefn: batch.EcsJobDefinition;\n\njobDefn.container.addVolume(batch.EcsVolume.efs({\n name: 'myVolume',\n fileSystem: myFileSystem,\n containerPath: '/Volumes/myVolume',\n}));\n```\n\n### Secrets\n\nYou can expose SecretsManager Secret ARNs or SSM Parameters to your container as environment variables.\nThe following example defines the `MY_SECRET_ENV_VAR` environment variable that contains the\nARN of the Secret defined by `mySecret`:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\n\ndeclare const mySecret: secretsmanager.ISecret;\n\nconst jobDefn = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n secrets: {\n MY_SECRET_ENV_VAR: batch.Secret.fromSecretsManager(mySecret),\n }\n }),\n});\n```\n\n### Running Kubernetes Workflows\n\nBatch also supports running workflows on EKS. The following example creates a `JobDefinition` that runs on EKS:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nconst jobDefn = new batch.EksJobDefinition(this, 'eksf2', {\n container: new batch.EksContainerDefinition(this, 'container', {\n image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'),\n volumes: [batch.EksVolume.emptyDir({\n name: 'myEmptyDirVolume',\n mountPath: '/mount/path',\n medium: batch.EmptyDirMediumType.MEMORY,\n readonly: true,\n sizeLimit: cdk.Size.mebibytes(2048),\n })],\n }),\n});\n```\n\nYou can mount `Volume`s to these containers in a single operation:\n\n```ts\ndeclare const jobDefn: batch.EksJobDefinition;\njobDefn.container.addVolume(batch.EksVolume.emptyDir({\n name: 'emptyDir',\n mountPath: '/Volumes/emptyDir',\n}));\njobDefn.container.addVolume(batch.EksVolume.hostPath({\n name: 'hostPath',\n hostPath: '/sys',\n mountPath: '/Volumes/hostPath',\n}));\njobDefn.container.addVolume(batch.EksVolume.secret({\n name: 'secret',\n optional: true,\n mountPath: '/Volumes/secret',\n secretName: 'mySecret',\n}));\n```\n\n### Running Distributed Workflows\n\nSome workflows benefit from parallellization and are most powerful when run in a distributed environment,\nsuch as certain numerical calculations or simulations. Batch offers `MultiNodeJobDefinition`s,\nwhich allow a single job to run on multiple instances in parallel, for this purpose.\nMessage Passing Interface (MPI) is often used with these workflows.\nYou must configure your containers to use MPI properly,\nbut Batch allows different nodes running different containers to communicate easily with one another.\nYou must configure your containers to use certain environment variables that Batch will provide them,\nwhich lets them know which one is the main node, among other information.\nFor an in-depth example on using MPI to perform numerical computations on Batch,\nsee this [blog post](https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/)\nIn particular, the environment variable that tells the containers which one is the main node can be configured on your `MultiNodeJobDefinition` as follows:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nconst multiNodeJob = new batch.MultiNodeJobDefinition(this, 'JobDefinition', {\n instanceType: ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE),\n containers: [{\n container: new batch.EcsEc2ContainerDefinition(this, 'mainMPIContainer', {\n image: ecs.ContainerImage.fromRegistry('yourregsitry.com/yourMPIImage:latest'),\n cpu: 256,\n memory: cdk.Size.mebibytes(2048),\n }),\n startNode: 0,\n endNode: 5,\n }],\n});\n// convenience method\nmultiNodeJob.addContainer({\n startNode: 6,\n endNode: 10,\n container: new batch.EcsEc2ContainerDefinition(this, 'multiContainer', {\n image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'),\n cpu: 256,\n memory: cdk.Size.mebibytes(2048),\n }),\n});\n```\n\nIf you need to set the control node to an index other than 0, specify it in directly:\n\n```ts\nconst multiNodeJob = new batch.MultiNodeJobDefinition(this, 'JobDefinition', {\n mainNode: 5,\n instanceType: ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE),\n});\n```\n\n### Pass Parameters to a Job\n\nBatch allows you define parameters in your `JobDefinition`, which can be referenced in the container command. For example:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nnew batch.EcsJobDefinition(this, 'JobDefn', {\n parameters: { echoParam: 'foobar' },\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n command: [\n 'echo',\n 'Ref::echoParam',\n ],\n }),\n});\n```\n\n### Understanding Progressive Allocation Strategies\n\nAWS Batch uses an [allocation strategy](https://docs.aws.amazon.com/batch/latest/userguide/allocation-strategies.html) to determine what compute resource will efficiently handle incoming job requests. By default, **BEST_FIT** will pick an available compute instance based on vCPU requirements. If none exist, the job will wait until resources become available. However, with this strategy, you may have jobs waiting in the queue unnecessarily despite having more powerful instances available. Below is an example of how that situation might look like:\n\n```plaintext\nCompute Environment:\n\n1. m5.xlarge => 4 vCPU\n2. m5.2xlarge => 8 vCPU\n```\n\n```plaintext\nJob Queue:\n---------\n| A | B |\n---------\n\nJob Requirements:\nA => 4 vCPU - ALLOCATED TO m5.xlarge\nB => 2 vCPU - WAITING\n```\n\nIn this situation, Batch will allocate **Job A** to compute resource #1 because it is the most cost efficient resource that matches the vCPU requirement. However, with this `BEST_FIT` strategy, **Job B** will not be allocated to our other available compute resource even though it is strong enough to handle it. Instead, it will wait until the first job is finished processing or wait a similar `m5.xlarge` resource to be provisioned.\n\nThe alternative would be to use the `BEST_FIT_PROGRESSIVE` strategy in order for the remaining job to be handled in larger containers regardless of vCPU requirement and costs.\n\n### Permissions\n\nYou can grant any Principal the `batch:submitJob` permission on both a job definition and a job queue like this:\n\n```ts\nimport * as cdk from 'aws-cdk-lib';\nimport * as iam from 'aws-cdk-lib/aws-iam';\n\ndeclare const vpc: ec2.IVpc;\n\nconst ecsJob = new batch.EcsJobDefinition(this, 'JobDefn', {\n container: new batch.EcsEc2ContainerDefinition(this, 'containerDefn', {\n image: ecs.ContainerImage.fromRegistry('public.ecr.aws/amazonlinux/amazonlinux:latest'),\n memory: cdk.Size.mebibytes(2048),\n cpu: 256,\n }),\n});\n\nconst queue = new batch.JobQueue(this, 'JobQueue', {\n computeEnvironments: [{\n computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(this, 'managedEc2CE', {\n vpc,\n }),\n order: 1,\n }],\n priority: 10,\n});\n\nconst user = new iam.User(this, 'MyUser');\necsJob.grantSubmitJob(user, queue);\n```\n" - }, - "repository": { - "directory": "packages/@aws-cdk/aws-batch-alpha", - "type": "git", - "url": "https://github.com/aws/aws-cdk.git" - }, - "schema": "jsii/0.10.0", - "targets": { - "dotnet": { - "iconUrl": "https://raw.githubusercontent.com/aws/aws-cdk/main/logo/default-256-dark.png", - "namespace": "Amazon.CDK.AWS.Batch.Alpha", - "packageId": "Amazon.CDK.AWS.Batch.Alpha" - }, - "go": { - "moduleName": "github.com/aws/aws-cdk-go", - "packageName": "awscdkbatchalpha" - }, - "java": { - "maven": { - "artifactId": "batch-alpha", - "groupId": "software.amazon.awscdk" - }, - "package": "software.amazon.awscdk.services.batch.alpha" - }, - "js": { - "npm": "@aws-cdk/aws-batch-alpha" - }, - "python": { - "classifiers": [ - "Framework :: AWS CDK", - "Framework :: AWS CDK :: 2" - ], - "distName": "aws-cdk.aws-batch-alpha", - "module": "aws_cdk.aws_batch_alpha" - } - }, - "types": { - "@aws-cdk/aws-batch-alpha.Action": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "The Action to take when all specified conditions in a RetryStrategy are met." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Action", - "kind": "enum", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 159 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "The job will not retry." - }, - "name": "EXIT" - }, - { - "docs": { - "remarks": "It can be retried up to the number of times specified in `retryAttempts`.", - "stability": "experimental", - "summary": "The job will retry." - }, - "name": "RETRY" - } - ], - "name": "Action", - "symbolId": "lib/job-definition-base:Action" - }, - "@aws-cdk/aws-batch-alpha.AllocationStrategy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "see": "https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/", - "stability": "experimental", - "summary": "Determines how this compute environment chooses instances to spawn." - }, - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy", - "kind": "enum", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 423 - }, - "members": [ - { - "docs": { - "remarks": "If instances of that type are not available, the queue will not choose a new type;\ninstead, it will wait for the instance to become available.\nThis can stall your `Queue`, with your compute environment only using part of its max capacity\n(or none at all) until the `BEST_FIT` instance becomes available.\nThis allocation strategy keeps costs lower but can limit scaling.\n`BEST_FIT` isn't supported when updating compute environments", - "stability": "experimental", - "summary": "Batch chooses the lowest-cost instance type that fits all the jobs in the queue." - }, - "name": "BEST_FIT" - }, - { - "docs": { - "remarks": "This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements\nof the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`.\nHowever, if not all of the capacity can be filled with this instance type,\nit will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity.\nTo make the most use of this allocation strategy,\nit is recommended to use as many instance classes as is feasible for your workload.", - "stability": "experimental", - "summary": "This is the default Allocation Strategy if `spot` is `false` or unspecified." - }, - "name": "BEST_FIT_PROGRESSIVE" - }, - { - "docs": { - "remarks": "This will tell Batch to choose the instance types from the ones you’ve specified that have\nthe most spot capacity available to minimize the chance of interruption.\nTo get the most benefit from your spot instances,\nyou should allow Batch to choose from as many different instance types as possible.", - "stability": "experimental", - "summary": "If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled)." - }, - "name": "SPOT_CAPACITY_OPTIMIZED" - }, - { - "docs": { - "remarks": "The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances.", - "stability": "experimental", - "summary": "The price and capacity optimized allocation strategy looks at both price and capacity to select the Spot Instance pools that are the least likely to be interrupted and have the lowest possible price." - }, - "name": "SPOT_PRICE_CAPACITY_OPTIMIZED" - } - ], - "name": "AllocationStrategy", - "symbolId": "lib/managed-compute-environment:AllocationStrategy" - }, - "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props common to all ComputeEnvironments." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 50 - }, - "name": "ComputeEnvironmentProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- generated by CloudFormation", - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 56 - }, - "name": "computeEnvironmentName", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 81 - }, - "name": "enabled", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- a serviceRole will be created for managed CEs, none for unmanaged CEs", - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 64 - }, - "name": "serviceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - } - ], - "symbolId": "lib/compute-environment-base:ComputeEnvironmentProps" - }, - "@aws-cdk/aws-batch-alpha.CustomReason": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "The corresponding Action will only be taken if *all* of the conditions specified here are met." - }, - "fqn": "@aws-cdk/aws-batch-alpha.CustomReason", - "kind": "interface", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 173 - }, - "name": "CustomReason", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- will not match on the exit code", - "remarks": "For example, `'40*'` will match 400, 404, 40123456789012", - "stability": "experimental", - "summary": "A glob string that will match on the job exit code." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 179 - }, - "name": "onExitCode", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- will not match on the reason", - "stability": "experimental", - "summary": "A glob string that will match on the reason returned by the exiting job For example, `'CannotPullContainerError*'` indicates that container needed to start the job could not be pulled." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 195 - }, - "name": "onReason", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- will not match on the status reason", - "remarks": "For example, `'Host EC2*'` indicates that the spot instance has been reclaimed.", - "stability": "experimental", - "summary": "A glob string that will match on the statusReason returned by the exiting job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 187 - }, - "name": "onStatusReason", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/job-definition-base:CustomReason" - }, - "@aws-cdk/aws-batch-alpha.Device": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "A container instance host device." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Device", - "kind": "interface", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 143 - }, - "name": "Device", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The path for the device on the host container instance." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 154 - }, - "name": "hostPath", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "Same path as the host", - "stability": "experimental", - "summary": "The path inside the container at which to expose the host device." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 149 - }, - "name": "containerPath", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "Readonly", - "remarks": "By default, the container has permissions for read, write, and mknod for the device.", - "stability": "experimental", - "summary": "The explicit permissions to provide to the container for the device." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 162 - }, - "name": "permissions", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.DevicePermission" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/linux-parameters:Device" - }, - "@aws-cdk/aws-batch-alpha.DevicePermission": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Permissions for device access." - }, - "fqn": "@aws-cdk/aws-batch-alpha.DevicePermission", - "kind": "enum", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 191 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "Read." - }, - "name": "READ" - }, - { - "docs": { - "stability": "experimental", - "summary": "Write." - }, - "name": "WRITE" - }, - { - "docs": { - "stability": "experimental", - "summary": "Make a node." - }, - "name": "MKNOD" - } - ], - "name": "DevicePermission", - "symbolId": "lib/linux-parameters:DevicePermission" - }, - "@aws-cdk/aws-batch-alpha.DnsPolicy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", - "stability": "experimental", - "summary": "The DNS Policy for the pod used by the Job Definition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy", - "kind": "enum", - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 100 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "The Pod inherits the name resolution configuration from the node that the Pods run on." - }, - "name": "DEFAULT" - }, - { - "docs": { - "stability": "experimental", - "summary": "Any DNS query that does not match the configured cluster domain suffix, such as `\"www.kubernetes.io\"`, is forwarded to an upstream nameserver by the DNS server. Cluster administrators may have extra stub-domain and upstream DNS servers configured." - }, - "name": "CLUSTER_FIRST" - }, - { - "docs": { - "remarks": "Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy.", - "stability": "experimental", - "summary": "For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`." - }, - "name": "CLUSTER_FIRST_WITH_HOST_NET" - } - ], - "name": "DnsPolicy", - "symbolId": "lib/eks-job-definition:DnsPolicy" - }, - "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure an EcsContainerDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 472 - }, - "name": "EcsContainerDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", - "stability": "experimental", - "summary": "The number of vCPUs reserved for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 483 - }, - "name": "cpu", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 476 - }, - "name": "image", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "abstract": true, - "docs": { - "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", - "stability": "experimental", - "summary": "The memory hard limit present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 490 - }, - "name": "memory", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "- no command", - "see": "https://docs.docker.com/engine/reference/builder/#cmd", - "stability": "experimental", - "summary": "The command that's passed to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 499 - }, - "name": "command", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no environment variables", - "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", - "stability": "experimental", - "summary": "The environment variables to pass to a container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 508 - }, - "name": "environment", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- a Role will be created", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html", - "stability": "experimental", - "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 517 - }, - "name": "executionRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "- no job role", - "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html", - "stability": "experimental", - "summary": "The role that the container can assume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 526 - }, - "name": "jobRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "stability": "experimental", - "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 533 - }, - "name": "linuxParameters", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" - } - }, - { - "abstract": true, - "docs": { - "default": "- the log configuration of the Docker daemon", - "stability": "experimental", - "summary": "The loging configuration for this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 540 - }, - "name": "logging", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ecs.LogDriver" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Gives the container readonly access to its root filesystem." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 547 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- no secrets", - "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html", - "stability": "experimental", - "summary": "A map from environment variable names to the secrets for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 557 - }, - "name": "secrets", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no user", - "stability": "experimental", - "summary": "The user name to use inside the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 564 - }, - "name": "user", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- no volumes", - "remarks": "Automatically added to the job definition.", - "stability": "experimental", - "summary": "The volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 571 - }, - "name": "volumes", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsContainerDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "constructs.Construct", - "docs": { - "stability": "experimental", - "summary": "A container orchestrated by ECS that uses EC2 resources." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 900 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 895 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Add a ulimit to this container." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 934 - }, - "name": "addUlimit", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "parameters": [ - { - "name": "ulimit", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" - } - } - ] - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a Volume to this container." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 706 - }, - "name": "addVolume", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "parameters": [ - { - "name": "volume", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - } - } - ] - } - ], - "name": "EcsEc2ContainerDefinition", - "properties": [ - { - "docs": { - "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", - "stability": "experimental", - "summary": "The number of vCPUs reserved for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 579 - }, - "name": "cpu", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 583 - }, - "name": "executionRole", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 578 - }, - "name": "image", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "docs": { - "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", - "stability": "experimental", - "summary": "The memory hard limit present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 580 - }, - "name": "memory", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Limits to set for the user this docker container will run as." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 897 - }, - "name": "ulimits", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "Automatically added to the job definition.", - "stability": "experimental", - "summary": "The volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 590 - }, - "name": "volumes", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The command that's passed to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 581 - }, - "name": "command", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", - "stability": "experimental", - "summary": "The environment variables to pass to a container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 582 - }, - "name": "environment", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "docs": { - "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", - "stability": "experimental", - "summary": "The number of physical GPUs to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 898 - }, - "name": "gpu", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role that the container can assume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 584 - }, - "name": "jobRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 585 - }, - "name": "linuxParameters", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The configuration of the log driver." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 586 - }, - "name": "logDriverConfig", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 896 - }, - "name": "privileged", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Gives the container readonly access to its root filesystem." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 587 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", - "stability": "experimental", - "summary": "A map from environment variable names to the secrets for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 588 - }, - "name": "secrets", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - }, - "kind": "map" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The user name to use inside the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 589 - }, - "name": "user", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsEc2ContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure an EcsEc2ContainerDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinitionProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 867 - }, - "name": "EcsEc2ContainerDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- no gpus", - "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", - "stability": "experimental", - "summary": "The number of physical GPUs to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 889 - }, - "name": "gpu", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 873 - }, - "name": "privileged", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- no ulimits", - "stability": "experimental", - "summary": "Limits to set for the user this docker container will run as." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 880 - }, - "name": "ulimits", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsEc2ContainerDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "constructs.Construct", - "docs": { - "stability": "experimental", - "summary": "A container orchestrated by ECS that uses Fargate resources." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1022 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", - "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1017 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Add a Volume to this container." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 706 - }, - "name": "addVolume", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "parameters": [ - { - "name": "volume", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - } - } - ] - } - ], - "name": "EcsFargateContainerDefinition", - "properties": [ - { - "docs": { - "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", - "stability": "experimental", - "summary": "The number of vCPUs reserved for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 579 - }, - "name": "cpu", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 583 - }, - "name": "executionRole", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 578 - }, - "name": "image", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "docs": { - "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", - "stability": "experimental", - "summary": "The memory hard limit present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 580 - }, - "name": "memory", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "remarks": "Automatically added to the job definition.", - "stability": "experimental", - "summary": "The volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 590 - }, - "name": "volumes", - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", - "stability": "experimental", - "summary": "Indicates whether the job has a public IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1019 - }, - "name": "assignPublicIp", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The command that's passed to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 581 - }, - "name": "command", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", - "stability": "experimental", - "summary": "The environment variables to pass to a container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 582 - }, - "name": "environment", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The size for ephemeral storage." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1020 - }, - "name": "ephemeralStorageSize", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Which version of Fargate to use when running this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1018 - }, - "name": "fargatePlatformVersion", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role that the container can assume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 584 - }, - "name": "jobRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 585 - }, - "name": "linuxParameters", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The configuration of the log driver." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 586 - }, - "name": "logDriverConfig", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Gives the container readonly access to its root filesystem." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 587 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", - "stability": "experimental", - "summary": "A map from environment variable names to the secrets for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 588 - }, - "name": "secrets", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - }, - "kind": "map" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The user name to use inside the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 589 - }, - "name": "user", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsFargateContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure an EcsFargateContainerDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinitionProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EcsContainerDefinitionProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 987 - }, - "name": "EcsFargateContainerDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", - "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html", - "stability": "experimental", - "summary": "Indicates whether the job has a public IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 997 - }, - "name": "assignPublicIp", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- 20 GiB", - "stability": "experimental", - "summary": "The size for ephemeral storage." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1011 - }, - "name": "ephemeralStorageSize", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "LATEST", - "stability": "experimental", - "summary": "Which version of Fargate to use when running this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 1004 - }, - "name": "fargatePlatformVersion", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsFargateContainerDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EcsJobDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::JobDefinition" - }, - "stability": "experimental", - "summary": "A JobDefinition that uses ECS orchestration." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 84 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IJobDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 58 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Import a JobDefinition by its arn." - }, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 62 - }, - "name": "fromJobDefinitionArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "jobDefinitionArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a RetryStrategy to this JobDefinition." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 259 - }, - "name": "addRetryStrategy", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "parameters": [ - { - "name": "strategy", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - } - } - ] - }, - { - "docs": { - "stability": "experimental", - "summary": "Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue`." - }, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 110 - }, - "name": "grantSubmitJob", - "parameters": [ - { - "name": "identity", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IGrantable" - } - }, - { - "name": "queue", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue" - } - } - ] - } - ], - "name": "EcsJobDefinition", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The container that this job will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 78 - }, - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 81 - }, - "name": "jobDefinitionArn", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 82 - }, - "name": "jobDefinitionName", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Defines the retry behavior for this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 243 - }, - "name": "retryStrategies", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 241 - }, - "name": "parameters", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "any" - }, - "kind": "map" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 79 - }, - "name": "propagateTags", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "The job is retried on failure the same number of attempts as the value.", - "stability": "experimental", - "summary": "The number of times to retry a job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 242 - }, - "name": "retryAttempts", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", - "stability": "experimental", - "summary": "The priority of this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 244 - }, - "name": "schedulingPriority", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", - "stability": "experimental", - "summary": "The timeout time for jobs that are submitted with this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 245 - }, - "name": "timeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/ecs-job-definition:EcsJobDefinition" - }, - "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for EcsJobDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsJobDefinitionProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.JobDefinitionProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 38 - }, - "name": "EcsJobDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The container that this job will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 42 - }, - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-job-definition.ts", - "line": 50 - }, - "name": "propagateTags", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-job-definition:EcsJobDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EcsMachineImage": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "A Batch MachineImage that is compatible with ECS." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage", - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 367 - }, - "name": "EcsMachineImage", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- chosen by batch", - "stability": "experimental", - "summary": "The machine image to use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 361 - }, - "name": "image", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IMachineImage" - } - }, - { - "abstract": true, - "docs": { - "default": "- 'ECS_AL2' for non-gpu instances, 'ECS_AL2_NVIDIA' for gpu instances", - "stability": "experimental", - "summary": "Tells Batch which instance type to launch this image on." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 373 - }, - "name": "imageType", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImageType" - } - } - ], - "symbolId": "lib/managed-compute-environment:EcsMachineImage" - }, - "@aws-cdk/aws-batch-alpha.EcsMachineImageType": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Maps the image to instance types." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImageType", - "kind": "enum", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 391 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "Tells Batch that this machine image runs on non-GPU instances." - }, - "name": "ECS_AL2" - }, - { - "docs": { - "stability": "experimental", - "summary": "Tells Batch that this machine image runs on GPU instances." - }, - "name": "ECS_AL2_NVIDIA" - } - ], - "name": "EcsMachineImageType", - "symbolId": "lib/managed-compute-environment:EcsMachineImageType" - }, - "@aws-cdk/aws-batch-alpha.EcsVolume": { - "abstract": true, - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Represents a Volume that can be mounted to a container that uses ECS." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 162 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 126 - }, - "methods": [ - { - "docs": { - "remarks": "this volume can grow and shrink as needed", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html", - "stability": "experimental", - "summary": "Creates a Volume that uses an AWS Elastic File System (EFS);" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 132 - }, - "name": "efs", - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EfsVolume" - } - }, - "static": true - }, - { - "docs": { - "remarks": "This volume will persist on the host at the specified `hostPath`.\nIf the `hostPath` is not specified, Docker will choose the host path. In this case,\nthe data may not persist after the containers that use it stop running.", - "stability": "experimental", - "summary": "Creates a Host volume." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 141 - }, - "name": "host", - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostVolume" - } - }, - "static": true - } - ], - "name": "EcsVolume", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The path on the container that this volume will be mounted to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 153 - }, - "name": "containerPath", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 148 - }, - "name": "name", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Whether or not the container has readonly access to this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 160 - }, - "name": "readonly", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsVolume" - }, - "@aws-cdk/aws-batch-alpha.EcsVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Options to configure an EcsVolume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolumeOptions", - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 104 - }, - "name": "EcsVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "the path on the container where this volume is mounted." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 113 - }, - "name": "containerPath", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "the name of this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 108 - }, - "name": "name", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "if set, the container will have readonly access to the volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 120 - }, - "name": "readonly", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:EcsVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.EfsVolume": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "@aws-cdk/aws-batch-alpha.EcsVolume", - "docs": { - "remarks": "this volume can grow and shrink as needed", - "stability": "experimental", - "summary": "A Volume that uses an AWS Elastic File System (EFS);" - }, - "fqn": "@aws-cdk/aws-batch-alpha.EfsVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 297 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 233 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Returns true if x is an EfsVolume, false otherwise." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 237 - }, - "name": "isEfsVolume", - "parameters": [ - { - "name": "x", - "type": { - "primitive": "any" - } - } - ], - "returns": { - "type": { - "primitive": "boolean" - } - }, - "static": true - } - ], - "name": "EfsVolume", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The EFS File System that supports this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 244 - }, - "name": "fileSystem", - "type": { - "fqn": "aws-cdk-lib.aws_efs.IFileSystem" - } - }, - { - "docs": { - "default": "- no accessPointId", - "remarks": "If an access point is specified, `rootDirectory` must either be omitted or set to `/`\nwhich enforces the path set on the EFS access point.\nIf an access point is used, `enableTransitEncryption` must be `true`.", - "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html", - "stability": "experimental", - "summary": "The Amazon EFS access point ID to use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 285 - }, - "name": "accessPointId", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "false", - "see": "https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html", - "stability": "experimental", - "summary": "Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 263 - }, - "name": "enableTransitEncryption", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "default": "- root of the EFS File System", - "remarks": "If this parameter is omitted, the root of the Amazon EFS volume is used instead.\nSpecifying `/` has the same effect as omitting this parameter.\nThe maximum length is 4,096 characters.", - "stability": "experimental", - "summary": "The directory within the Amazon EFS file system to mount as the root directory inside the host." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 254 - }, - "name": "rootDirectory", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "- chosen by the EFS Mount Helper", - "remarks": "The value must be between 0 and 65,535.", - "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html", - "stability": "experimental", - "summary": "The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 273 - }, - "name": "transitEncryptionPort", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "docs": { - "default": "false", - "remarks": "If specified, `enableTransitEncryption` must be `true`.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints", - "stability": "experimental", - "summary": "Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 295 - }, - "name": "useJobRole", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:EfsVolume" - }, - "@aws-cdk/aws-batch-alpha.EfsVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Options for configuring an EfsVolume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EfsVolumeOptions", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 172 - }, - "name": "EfsVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The EFS File System that supports this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 176 - }, - "name": "fileSystem", - "type": { - "fqn": "aws-cdk-lib.aws_efs.IFileSystem" - } - }, - { - "abstract": true, - "docs": { - "default": "- no accessPointId", - "remarks": "If an access point is specified, `rootDirectory` must either be omitted or set to `/`\nwhich enforces the path set on the EFS access point.\nIf an access point is used, `enableTransitEncryption` must be `true`.", - "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html", - "stability": "experimental", - "summary": "The Amazon EFS access point ID to use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 217 - }, - "name": "accessPointId", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "see": "https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html", - "stability": "experimental", - "summary": "Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 195 - }, - "name": "enableTransitEncryption", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- root of the EFS File System", - "remarks": "If this parameter is omitted, the root of the Amazon EFS volume is used instead.\nSpecifying `/` has the same effect as omitting this parameter.\nThe maximum length is 4,096 characters.", - "stability": "experimental", - "summary": "The directory within the Amazon EFS file system to mount as the root directory inside the host." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 186 - }, - "name": "rootDirectory", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- chosen by the EFS Mount Helper", - "remarks": "The value must be between 0 and 65,535.", - "see": "https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html", - "stability": "experimental", - "summary": "The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 205 - }, - "name": "transitEncryptionPort", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "If specified, `enableTransitEncryption` must be `true`.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints", - "stability": "experimental", - "summary": "Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 227 - }, - "name": "useJobRole", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:EfsVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.EksContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "constructs.Construct", - "docs": { - "stability": "experimental", - "summary": "A container that can be run with EKS orchestration on EC2 resources." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 555 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEksContainerDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 533 - }, - "methods": [ - { - "docs": { - "remarks": "Automatically added to the Pod.", - "stability": "experimental", - "summary": "Mount a Volume to this container." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 579 - }, - "name": "addVolume", - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "parameters": [ - { - "name": "volume", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" - } - } - ] - } - ], - "name": "EksContainerDefinition", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 534 - }, - "name": "image", - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "docs": { - "remarks": "Automatically added to the Pod.", - "stability": "experimental", - "summary": "The Volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 551 - }, - "name": "volumes", - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", - "stability": "experimental", - "summary": "An array of arguments to the entrypoint." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 535 - }, - "name": "args", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", - "stability": "experimental", - "summary": "The entrypoint for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 536 - }, - "name": "command", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "stability": "experimental", - "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 542 - }, - "name": "cpuLimit", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 543 - }, - "name": "cpuReservation", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", - "stability": "experimental", - "summary": "The environment variables to pass to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 537 - }, - "name": "env", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "docs": { - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "stability": "experimental", - "summary": "The hard limit of GPUs to present to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 544 - }, - "name": "gpuLimit", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 545 - }, - "name": "gpuReservation", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The image pull policy for this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 538 - }, - "name": "imagePullPolicy", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" - } - }, - { - "docs": { - "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "stability": "experimental", - "summary": "The amount (in MiB) of memory to present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 540 - }, - "name": "memoryLimit", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "stability": "experimental", - "summary": "The soft limit (in MiB) of memory to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 541 - }, - "name": "memoryReservation", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 539 - }, - "name": "name", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "stability": "experimental", - "summary": "If specified, gives this container elevated permissions on the host container instance." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 546 - }, - "name": "privileged", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "stability": "experimental", - "summary": "If specified, gives this container readonly access to its root file system." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 547 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "stability": "experimental", - "summary": "If specified, the container is run as the specified group ID (`gid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 548 - }, - "name": "runAsGroup", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "stability": "experimental", - "summary": "If specified, the container is run as a user with a `uid` other than 0." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 549 - }, - "name": "runAsRoot", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "stability": "experimental", - "summary": "If specified, this container is run as the specified user ID (`uid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 550 - }, - "name": "runAsUser", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/eks-container-definition:EksContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure an EksContainerDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinitionProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 287 - }, - "name": "EksContainerDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 291 - }, - "name": "image", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "abstract": true, - "docs": { - "default": "- no args", - "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", - "see": "https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/", - "stability": "experimental", - "summary": "An array of arguments to the entrypoint." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 308 - }, - "name": "args", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no command", - "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", - "see": "https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint", - "stability": "experimental", - "summary": "The entrypoint for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 327 - }, - "name": "command", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- No CPU limit", - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 411 - }, - "name": "cpuLimit", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- No CPUs reserved", - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 426 - }, - "name": "cpuReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no environment variables", - "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", - "stability": "experimental", - "summary": "The environment variables to pass to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 337 - }, - "name": "env", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- No GPU limit", - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The hard limit of GPUs to present to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 439 - }, - "name": "gpuLimit", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- No GPUs reserved", - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 453 - }, - "name": "gpuReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise", - "see": "https://kubernetes.io/docs/concepts/containers/images/#updating-images", - "stability": "experimental", - "summary": "The image pull policy for this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 346 - }, - "name": "imagePullPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" - } - }, - { - "abstract": true, - "docs": { - "default": "- No memory limit", - "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", - "stability": "experimental", - "summary": "The amount (in MiB) of memory to present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 371 - }, - "name": "memoryLimit", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "- No memory reserved", - "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", - "stability": "experimental", - "summary": "The soft limit (in MiB) of memory to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 396 - }, - "name": "memoryReservation", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": ": `'Default'`", - "stability": "experimental", - "summary": "The name of this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 353 - }, - "name": "name", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", - "stability": "experimental", - "summary": "If specified, gives this container elevated permissions on the host container instance." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 467 - }, - "name": "privileged", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", - "stability": "experimental", - "summary": "If specified, gives this container readonly access to its root file system." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 480 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, the container is run as the specified group ID (`gid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 493 - }, - "name": "runAsGroup", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- the container is *not* required to run as a non-root user", - "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, the container is run as a user with a `uid` other than 0." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 505 - }, - "name": "runAsRoot", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- the user that is specified in the image metadata.", - "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, this container is run as the specified user ID (`uid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 517 - }, - "name": "runAsUser", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no volumes", - "remarks": "Automatically added to the Pod.", - "see": "https://kubernetes.io/docs/concepts/storage/volumes/", - "stability": "experimental", - "summary": "The Volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 527 - }, - "name": "volumes", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/eks-container-definition:EksContainerDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EksJobDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::JobDefinition" - }, - "stability": "experimental", - "summary": "A JobDefinition that uses Eks orchestration." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 151 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "@aws-cdk/aws-batch-alpha.IJobDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 125 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Import an EksJobDefinition by its arn." - }, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 129 - }, - "name": "fromEksJobDefinitionArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "eksJobDefinitionArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IEksJobDefinition" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a RetryStrategy to this JobDefinition." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 259 - }, - "name": "addRetryStrategy", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "parameters": [ - { - "name": "strategy", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - } - } - ] - } - ], - "name": "EksJobDefinition", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The container this Job Definition will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 143 - }, - "name": "container", - "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 148 - }, - "name": "jobDefinitionArn", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 149 - }, - "name": "jobDefinitionName", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Defines the retry behavior for this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 243 - }, - "name": "retryStrategies", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The DNS Policy of the pod used by this Job Definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 144 - }, - "name": "dnsPolicy", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 241 - }, - "name": "parameters", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "any" - }, - "kind": "map" - } - } - }, - { - "docs": { - "remarks": "The job is retried on failure the same number of attempts as the value.", - "stability": "experimental", - "summary": "The number of times to retry a job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 242 - }, - "name": "retryAttempts", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", - "stability": "experimental", - "summary": "The priority of this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 244 - }, - "name": "schedulingPriority", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", - "stability": "experimental", - "summary": "The name of the service account that's used to run the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 146 - }, - "name": "serviceAccount", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", - "stability": "experimental", - "summary": "The timeout time for jobs that are submitted with this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 245 - }, - "name": "timeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "docs": { - "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", - "stability": "experimental", - "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 145 - }, - "name": "useHostNetwork", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-job-definition:EksJobDefinition" - }, - "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for EksJobDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksJobDefinitionProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.JobDefinitionProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 54 - }, - "name": "EksJobDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The container this Job Definition will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 58 - }, - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" - } - }, - { - "abstract": true, - "docs": { - "default": "`DnsPolicy.CLUSTER_FIRST`", - "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", - "stability": "experimental", - "summary": "The DNS Policy of the pod used by this Job Definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 67 - }, - "name": "dnsPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" - } - }, - { - "abstract": true, - "docs": { - "default": "- the default service account of the container", - "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", - "see": "https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html", - "stability": "experimental", - "summary": "The name of the service account that's used to run the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 92 - }, - "name": "serviceAccount", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", - "see": "https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking", - "stability": "experimental", - "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 79 - }, - "name": "useHostNetwork", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-job-definition:EksJobDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.EksMachineImage": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "A Batch MachineImage that is compatible with EKS." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage", - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 379 - }, - "name": "EksMachineImage", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- chosen by batch", - "stability": "experimental", - "summary": "The machine image to use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 361 - }, - "name": "image", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IMachineImage" - } - }, - { - "abstract": true, - "docs": { - "default": "- 'EKS_AL2' for non-gpu instances, 'EKS_AL2_NVIDIA' for gpu instances", - "stability": "experimental", - "summary": "Tells Batch which instance type to launch this image on." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 385 - }, - "name": "imageType", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImageType" - } - } - ], - "symbolId": "lib/managed-compute-environment:EksMachineImage" - }, - "@aws-cdk/aws-batch-alpha.EksMachineImageType": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Maps the image to instance types." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImageType", - "kind": "enum", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 406 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "Tells Batch that this machine image runs on non-GPU instances." - }, - "name": "EKS_AL2" - }, - { - "docs": { - "stability": "experimental", - "summary": "Tells Batch that this machine image runs on GPU instances." - }, - "name": "EKS_AL2_NVIDIA" - } - ], - "name": "EksMachineImageType", - "symbolId": "lib/managed-compute-environment:EksMachineImageType" - }, - "@aws-cdk/aws-batch-alpha.EksVolume": { - "abstract": true, - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A Volume that can be mounted to a container supported by EKS." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 717 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 668 - }, - "methods": [ - { - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", - "stability": "experimental", - "summary": "Creates a Kubernetes EmptyDir volume." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 674 - }, - "name": "emptyDir", - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolume" - } - }, - "static": true - }, - { - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", - "stability": "experimental", - "summary": "Creates a Kubernetes HostPath volume." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 682 - }, - "name": "hostPath", - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolume" - } - }, - "static": true - }, - { - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", - "stability": "experimental", - "summary": "Creates a Kubernetes Secret volume." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 690 - }, - "name": "secret", - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolume" - } - }, - "static": true - } - ], - "name": "EksVolume", - "properties": [ - { - "docs": { - "remarks": "The name must be a valid DNS subdomain name.", - "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", - "stability": "experimental", - "summary": "The name of this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 700 - }, - "name": "name", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "- the container is not mounted", - "stability": "experimental", - "summary": "The path on the container where the container is mounted." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 707 - }, - "name": "containerPath", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "false", - "remarks": "Otherwise, the container has read/write access.", - "stability": "experimental", - "summary": "If specified, the container has readonly access to the volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 715 - }, - "name": "readonly", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-container-definition:EksVolume" - }, - "@aws-cdk/aws-batch-alpha.EksVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Options to configure an EksVolume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EksVolumeOptions", - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 640 - }, - "name": "EksVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "The name must be a valid DNS subdomain name.", - "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", - "stability": "experimental", - "summary": "The name of this volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 647 - }, - "name": "name", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- the volume is not mounted", - "stability": "experimental", - "summary": "The path on the container where the volume is mounted." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 654 - }, - "name": "mountPath", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "Otherwise, the container has read/write access.", - "stability": "experimental", - "summary": "If specified, the container has readonly access to the volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 662 - }, - "name": "readonly", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-container-definition:EksVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.EmptyDirMediumType": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "What medium the volume will live in." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType", - "kind": "enum", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 748 - }, - "members": [ - { - "docs": { - "remarks": "Items written here will survive node reboots.", - "stability": "experimental", - "summary": "Use the disk storage of the node." - }, - "name": "DISK" - }, - { - "docs": { - "remarks": "Items written here will *not* survive node reboots.", - "stability": "experimental", - "summary": "Use the `tmpfs` volume that is backed by RAM of the node." - }, - "name": "MEMORY" - } - ], - "name": "EmptyDirMediumType", - "symbolId": "lib/eks-container-definition:EmptyDirMediumType" - }, - "@aws-cdk/aws-batch-alpha.EmptyDirVolume": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "@aws-cdk/aws-batch-alpha.EksVolume", - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", - "stability": "experimental", - "summary": "A Kubernetes EmptyDir volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 789 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 767 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Returns `true` if `x` is an EmptyDirVolume, `false` otherwise." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 771 - }, - "name": "isEmptyDirVolume", - "parameters": [ - { - "name": "x", - "type": { - "primitive": "any" - } - } - ], - "returns": { - "type": { - "primitive": "boolean" - } - }, - "static": true - } - ], - "name": "EmptyDirVolume", - "properties": [ - { - "docs": { - "default": "`EmptyDirMediumType.DISK`", - "stability": "experimental", - "summary": "The storage type to use for this Volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 780 - }, - "name": "medium", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType" - } - }, - { - "docs": { - "default": "- no size limit", - "stability": "experimental", - "summary": "The maximum size for this Volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 787 - }, - "name": "sizeLimit", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - } - ], - "symbolId": "lib/eks-container-definition:EmptyDirVolume" - }, - "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#emptydir", - "stability": "experimental", - "summary": "Options for a Kubernetes EmptyDir volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirVolumeOptions", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EksVolumeOptions" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 729 - }, - "name": "EmptyDirVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "default": "`EmptyDirMediumType.DISK`", - "stability": "experimental", - "summary": "The storage type to use for this Volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 735 - }, - "name": "medium", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EmptyDirMediumType" - } - }, - { - "abstract": true, - "docs": { - "default": "- no size limit", - "stability": "experimental", - "summary": "The maximum size for this Volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 742 - }, - "name": "sizeLimit", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - } - ], - "symbolId": "lib/eks-container-definition:EmptyDirVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::SchedulingPolicy" - }, - "remarks": "The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs.\nThe scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of\neach share are currently being executed by the ComputeEnvironment*. The weight factors associated with\neach share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of\nfairshare policies.", - "stability": "experimental", - "summary": "Represents a Fairshare Scheduling Policy. Instructs the scheduler to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers." - }, - "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 212 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", - "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 191 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Reference an exisiting Scheduling Policy by its ARN." - }, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 195 - }, - "name": "fromFairshareSchedulingPolicyArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "fairshareSchedulingPolicyArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a share this to this Fairshare SchedulingPolicy." - }, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 242 - }, - "name": "addShare", - "parameters": [ - { - "name": "share", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Share" - } - } - ] - } - ], - "name": "FairshareSchedulingPolicy", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The arn of this scheduling policy." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 209 - }, - "name": "schedulingPolicyArn", - "overrides": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this scheduling policy." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 210 - }, - "name": "schedulingPolicyName", - "overrides": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", - "stability": "experimental", - "summary": "The shares that this Scheduling Policy applies to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 208 - }, - "name": "shares", - "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Share" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", - "stability": "experimental", - "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 206 - }, - "name": "computeReservation", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", - "stability": "experimental", - "summary": "The amount of time to use to measure the usage of each job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 207 - }, - "name": "shareDecay", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/scheduling-policy:FairshareSchedulingPolicy" - }, - "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Fairshare SchedulingPolicy configuration." - }, - "fqn": "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicyProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 136 - }, - "name": "FairshareSchedulingPolicyProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- no vCPU is reserved", - "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", - "stability": "experimental", - "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 155 - }, - "name": "computeReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- generated by CloudFormation", - "stability": "experimental", - "summary": "The name of this SchedulingPolicy." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 34 - }, - "name": "schedulingPolicyName", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- 0: only the current job usage is considered", - "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", - "stability": "experimental", - "summary": "The amount of time to use to measure the usage of each job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 167 - }, - "name": "shareDecay", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "abstract": true, - "docs": { - "default": "- no shares", - "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", - "stability": "experimental", - "summary": "The shares that this Scheduling Policy applies to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 176 - }, - "name": "shares", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Share" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/scheduling-policy:FairshareSchedulingPolicyProps" - }, - "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::ComputeEnvironment" - }, - "stability": "experimental", - "summary": "A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances." - }, - "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1096 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1072 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Reference an existing FargateComputeEnvironment by its arn." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1076 - }, - "name": "fromFargateComputeEnvironmentArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "fargateComputeEnvironmentArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment" - } - }, - "static": true - } - ], - "name": "FargateComputeEnvironment", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this compute environment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1094 - }, - "name": "computeEnvironmentArn", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1093 - }, - "name": "computeEnvironmentName", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The network connections associated with this resource." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 210 - }, - "name": "connections", - "overrides": "aws-cdk-lib.aws_ec2.IConnectable", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.Connections" - } - }, - { - "docs": { - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 92 - }, - "name": "enabled", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", - "stability": "experimental", - "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 201 - }, - "name": "maxvCpus", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The security groups this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 206 - }, - "name": "securityGroups", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "TagManager to set, remove and format tags." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 208 - }, - "name": "tags", - "overrides": "aws-cdk-lib.ITaggable", - "type": { - "fqn": "aws-cdk-lib.TagManager" - } - }, - { - "docs": { - "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", - "stability": "experimental", - "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 202 - }, - "name": "replaceComputeEnvironment", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 91 - }, - "name": "serviceRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", - "stability": "experimental", - "summary": "Whether or not to use spot instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 203 - }, - "name": "spot", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", - "stability": "experimental", - "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 205 - }, - "name": "terminateOnUpdate", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", - "stability": "experimental", - "summary": "Only meaningful if `terminateOnUpdate` is `false`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 204 - }, - "name": "updateTimeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "docs": { - "remarks": "If you specify a specific AMI, this property will be ignored.", - "stability": "experimental", - "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 207 - }, - "name": "updateToLatestImageVersion", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:FargateComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for a FargateComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.FargateComputeEnvironmentProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1065 - }, - "name": "FargateComputeEnvironmentProps", - "symbolId": "lib/managed-compute-environment:FargateComputeEnvironmentProps" - }, - "@aws-cdk/aws-batch-alpha.HostPathVolume": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "@aws-cdk/aws-batch-alpha.EksVolume", - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", - "stability": "experimental", - "summary": "A Kubernetes HostPath volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 840 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 823 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "returns `true` if `x` is a HostPathVolume, `false` otherwise." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 827 - }, - "name": "isHostPathVolume", - "parameters": [ - { - "name": "x", - "type": { - "primitive": "any" - } - } - ], - "returns": { - "type": { - "primitive": "boolean" - } - }, - "static": true - } - ], - "name": "HostPathVolume", - "properties": [ - { - "docs": { - "remarks": "*Note*: HothPath Volumes present many security risks, and should be avoided when possible.", - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", - "stability": "experimental", - "summary": "The path of the file or directory on the host to mount into containers on the pod." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 838 - }, - "name": "path", - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/eks-container-definition:HostPathVolume" - }, - "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", - "stability": "experimental", - "summary": "Options for a kubernetes HostPath volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.HostPathVolumeOptions", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EksVolumeOptions" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 807 - }, - "name": "HostPathVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "*Note*: HothPath Volumes present many security risks, and should be avoided when possible.", - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#hostpath", - "stability": "experimental", - "summary": "The path of the file or directory on the host to mount into containers on the pod." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 815 - }, - "name": "hostPath", - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/eks-container-definition:HostPathVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.HostVolume": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "@aws-cdk/aws-batch-alpha.EcsVolume", - "docs": { - "remarks": "This volume will persist on the host at the specified `hostPath`.\nIf the `hostPath` is not specified, Docker will choose the host path. In this case,\nthe data may not persist after the containers that use it stop running.", - "stability": "experimental", - "summary": "Creates a Host volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.HostVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 346 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 333 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "returns `true` if `x` is a `HostVolume`, `false` otherwise." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 337 - }, - "name": "isHostVolume", - "parameters": [ - { - "name": "x", - "type": { - "primitive": "any" - } - } - ], - "returns": { - "type": { - "primitive": "boolean" - } - }, - "static": true - } - ], - "name": "HostVolume", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The path on the host machine this container will have access to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 344 - }, - "name": "hostPath", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:HostVolume" - }, - "@aws-cdk/aws-batch-alpha.HostVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Options for configuring an ECS HostVolume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.HostVolumeOptions", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EcsVolumeOptions" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 318 - }, - "name": "HostVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- Docker will choose the host path.\nThe data may not persist after the containers that use it stop running.", - "stability": "experimental", - "summary": "The path on the host machine this container will have access to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 325 - }, - "name": "hostPath", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:HostVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.IComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Represents a ComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "interfaces": [ - "aws-cdk-lib.IResource" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 8 - }, - "name": "IComputeEnvironment", - "properties": [ - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The ARN of this compute environment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 21 - }, - "name": "computeEnvironmentArn", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 14 - }, - "name": "computeEnvironmentName", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 44 - }, - "name": "enabled", - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- a serviceRole will be created for managed CEs, none for unmanaged CEs", - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 29 - }, - "name": "serviceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - } - ], - "symbolId": "lib/compute-environment-base:IComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A container that can be run with ECS orchestration." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition", - "interfaces": [ - "constructs.IConstruct" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 361 - }, - "methods": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Add a Volume to this container." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 466 - }, - "name": "addVolume", - "parameters": [ - { - "name": "volume", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - } - } - ] - } - ], - "name": "IEcsContainerDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "Each vCPU is equivalent to 1,024 CPU shares.\nFor containers running on EC2 resources, you must specify at least one vCPU.", - "stability": "experimental", - "summary": "The number of vCPUs reserved for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 372 - }, - "name": "cpu", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "see": "https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html", - "stability": "experimental", - "summary": "The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 402 - }, - "name": "executionRole", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 365 - }, - "name": "image", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "abstract": true, - "docs": { - "remarks": "If your container attempts to exceed the memory specified, the container is terminated.\nYou must specify at least 4 MiB of memory for a job.", - "stability": "experimental", - "summary": "The memory hard limit present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 379 - }, - "name": "memory", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "- no volumes", - "remarks": "Automatically added to the job definition.", - "stability": "experimental", - "summary": "The volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 454 - }, - "name": "volumes", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsVolume" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "see": "https://docs.docker.com/engine/reference/builder/#cmd", - "stability": "experimental", - "summary": "The command that's passed to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 386 - }, - "name": "command", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no environment variables", - "remarks": "Cannot start with `AWS_BATCH`.\nWe don't recommend using plaintext environment variables for sensitive information, such as credential data.", - "stability": "experimental", - "summary": "The environment variables to pass to a container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 395 - }, - "name": "environment", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no jobRole", - "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html", - "stability": "experimental", - "summary": "The role that the container can assume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 411 - }, - "name": "jobRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "stability": "experimental", - "summary": "Linux-specific modifications that are applied to the container, such as details for device mappings." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 418 - }, - "name": "linuxParameters", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The configuration of the log driver." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 423 - }, - "name": "logDriverConfig", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ecs.LogDriverConfig" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Gives the container readonly access to its root filesystem." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 430 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- no secrets", - "remarks": "Allows your job definitions\nto reference the secret by the environment variable name defined in this property.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html", - "stability": "experimental", - "summary": "A map from environment variable names to the secrets for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 440 - }, - "name": "secrets", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no user", - "stability": "experimental", - "summary": "The user name to use inside the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 447 - }, - "name": "user", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:IEcsContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A container orchestrated by ECS that uses EC2 resources." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IEcsEc2ContainerDefinition", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 836 - }, - "methods": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Add a ulimit to this container." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 861 - }, - "name": "addUlimit", - "parameters": [ - { - "name": "ulimit", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" - } - } - ] - } - ], - "name": "IEcsEc2ContainerDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Limits to set for the user this docker container will run as." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 847 - }, - "name": "ulimits", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no gpus", - "remarks": "Make sure that the number of GPUs reserved for all containers in a job doesn't exceed\nthe number of available GPUs on the compute resource that the job is launched on.", - "stability": "experimental", - "summary": "The number of physical GPUs to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 856 - }, - "name": "gpu", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 842 - }, - "name": "privileged", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:IEcsEc2ContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A container orchestrated by ECS that uses Fargate resources and is orchestrated by ECS." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IEcsFargateContainerDefinition", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 957 - }, - "name": "IEcsFargateContainerDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet\n(for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet.", - "see": "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html", - "stability": "experimental", - "summary": "Indicates whether the job has a public IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 967 - }, - "name": "assignPublicIp", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- 20 GiB", - "stability": "experimental", - "summary": "The size for ephemeral storage." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 981 - }, - "name": "ephemeralStorageSize", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "LATEST", - "stability": "experimental", - "summary": "Which version of Fargate to use when running this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 974 - }, - "name": "fargatePlatformVersion", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ecs.FargatePlatformVersion" - } - } - ], - "symbolId": "lib/ecs-container-definition:IEcsFargateContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.IEksContainerDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A container that can be run with EKS orchestration on EC2 resources." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IEksContainerDefinition", - "interfaces": [ - "constructs.IConstruct" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 13 - }, - "methods": [ - { - "abstract": true, - "docs": { - "remarks": "Automatically added to the Pod.", - "stability": "experimental", - "summary": "Mount a Volume to this container." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 250 - }, - "name": "addVolume", - "parameters": [ - { - "name": "volume", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" - } - } - ] - } - ], - "name": "IEksContainerDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The image that this container will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 17 - }, - "name": "image", - "type": { - "fqn": "aws-cdk-lib.aws_ecs.ContainerImage" - } - }, - { - "abstract": true, - "docs": { - "remarks": "Automatically added to the Pod.", - "see": "https://kubernetes.io/docs/concepts/storage/volumes/", - "stability": "experimental", - "summary": "The Volumes to mount to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 245 - }, - "name": "volumes", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EksVolume" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "remarks": "If this isn't specified, the CMD of the container image is used.\nThis corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to \"$(NAME1)\" and the NAME1 environment variable doesn't exist,\nthe command string will remain \"$(NAME1).\" $$ is replaced with $, and the resulting string isn't expanded.\nor example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists.", - "see": "https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/", - "stability": "experimental", - "summary": "An array of arguments to the entrypoint." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 32 - }, - "name": "args", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "remarks": "This isn't run within a shell.\nIf this isn't specified, the `ENTRYPOINT` of the container image is used.\nEnvironment variable references are expanded using the container's environment.\nIf the referenced environment variable doesn't exist, the reference in the command isn't changed.\nFor example, if the reference is to `\"$(NAME1)\"` and the `NAME1` environment variable doesn't exist,\nthe command string will remain `\"$(NAME1).\"` `$$` is replaced with `$` and the resulting string isn't expanded.\nFor example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists.\n\nThe entrypoint can't be updated.", - "see": "https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint", - "stability": "experimental", - "summary": "The entrypoint for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 49 - }, - "name": "command", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- No CPU limit", - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The hard limit of CPUs to present to this container. Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 131 - }, - "name": "cpuLimit", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- No CPUs reserved", - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nAt least one of `cpuReservation` and `cpuLimit` is required.\nIf both are specified, then `cpuLimit` must be at least as large as `cpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 146 - }, - "name": "cpuReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "remarks": "*Note*: Environment variables cannot start with \"AWS_BATCH\".\nThis naming convention is reserved for variables that AWS Batch sets.", - "stability": "experimental", - "summary": "The environment variables to pass to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 57 - }, - "name": "env", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "string" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- No GPU limit", - "remarks": "If your container attempts to exceed this limit, it will be terminated.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The hard limit of GPUs to present to this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 159 - }, - "name": "gpuLimit", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- No GPUs reserved", - "remarks": "The container will given at least this many CPUs, but may consume more.\n\nIf both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`.", - "see": "https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/", - "stability": "experimental", - "summary": "The soft limit of CPUs to reserve for the container Must be an even multiple of 0.25." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 173 - }, - "name": "gpuReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise", - "see": "https://kubernetes.io/docs/concepts/containers/images/#updating-images", - "stability": "experimental", - "summary": "The image pull policy for this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 66 - }, - "name": "imagePullPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy" - } - }, - { - "abstract": true, - "docs": { - "default": "- No memory limit", - "remarks": "If your container attempts to exceed the allocated memory, it will be terminated.\n\nMust be larger that 4 MiB\n\nAt least one of `memoryLimit` and `memoryReservation` is required\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", - "stability": "experimental", - "summary": "The amount (in MiB) of memory to present to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 91 - }, - "name": "memoryLimit", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "- No memory reserved", - "remarks": "Your container will be given at least this much memory, but may consume more.\n\nMust be larger that 4 MiB\n\nWhen system memory is under heavy contention, Docker attempts to keep the\ncontainer memory to this soft limit. However, your container can consume more\nmemory when it needs to, up to either the hard limit specified with the memory\nparameter (if applicable), or all of the available memory on the container\ninstance, whichever comes first.\n\nAt least one of `memoryLimit` and `memoryReservation` is required.\nIf both are specified, then `memoryLimit` must be equal to `memoryReservation`\n\n*Note*: To maximize your resource utilization, provide your jobs with as much memory as possible\nfor the specific instance type that you are using.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html", - "stability": "experimental", - "summary": "The soft limit (in MiB) of memory to reserve for the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 116 - }, - "name": "memoryReservation", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": ": `'Default'`", - "stability": "experimental", - "summary": "The name of this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 73 - }, - "name": "name", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "The level of permissions are similar to the root user permissions.\n\nThis parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", - "stability": "experimental", - "summary": "If specified, gives this container elevated permissions on the host container instance." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 187 - }, - "name": "privileged", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems", - "stability": "experimental", - "summary": "If specified, gives this container readonly access to its root file system." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 200 - }, - "name": "readonlyRootFilesystem", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "If this parameter isn't specified, the default is the group that's specified in the image metadata.\nThis parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, the container is run as the specified group ID (`gid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 213 - }, - "name": "runAsGroup", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- the container is *not* required to run as a non-root user", - "remarks": "Otherwise, no such rule is enforced.\nThis parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, the container is run as a user with a `uid` other than 0." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 225 - }, - "name": "runAsRoot", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- the user that is specified in the image metadata.", - "remarks": "This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation.\n\n*Note*: this is only compatible with Kubernetes < v1.25", - "see": "https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups", - "stability": "experimental", - "summary": "If specified, this container is run as the specified user ID (`uid`)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 237 - }, - "name": "runAsUser", - "optional": true, - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/eks-container-definition:IEksContainerDefinition" - }, - "@aws-cdk/aws-batch-alpha.IEksJobDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A JobDefinition that uses Eks orchestration." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IEksJobDefinition", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IJobDefinition" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 10 - }, - "name": "IEksJobDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The container this Job Definition will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 14 - }, - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.EksContainerDefinition" - } - }, - { - "abstract": true, - "docs": { - "default": "`DnsPolicy.CLUSTER_FIRST`", - "see": "https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy", - "stability": "experimental", - "summary": "The DNS Policy of the pod used by this Job Definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 23 - }, - "name": "dnsPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.DnsPolicy" - } - }, - { - "abstract": true, - "docs": { - "default": "- the default service account of the container", - "remarks": "service accounts are Kubernetes method of identification and authentication,\nroughly analogous to IAM users.", - "see": "https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html", - "stability": "experimental", - "summary": "The name of the service account that's used to run the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 48 - }, - "name": "serviceAccount", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "Otherwise, the Kubernetes pod networking model is enabled.\nMost AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections.", - "see": "https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking", - "stability": "experimental", - "summary": "If specified, the Pod used by this Job Definition will use the host's network IP address." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-job-definition.ts", - "line": 35 - }, - "name": "useHostNetwork", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-job-definition:IEksJobDefinition" - }, - "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "remarks": "The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs.\nIt does this by deciding how many Jobs of each share to schedule *relative to how many jobs of\neach share are currently being executed by the ComputeEnvironment*. The weight factors associated with\neach share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of\nfairshare policies.", - "stability": "experimental", - "summary": "Represents a Fairshare Scheduling Policy. Instructs the scheduler to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IFairshareSchedulingPolicy", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 92 - }, - "name": "IFairshareSchedulingPolicy", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "*Note*: It is possible to submit Jobs to the queue with Share Identifiers that\nare not recognized by the Scheduling Policy.", - "stability": "experimental", - "summary": "The shares that this Scheduling Policy applies to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 130 - }, - "name": "shares", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Share" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no vCPU is reserved", - "remarks": "The percentage reserved is defined by the Scheduler as:\n`(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers.\n\nFor example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the\nmaximum available vCPU if there's only one fair share identifier.\nIt reserves 25% if there are two fair share identifiers.\nIt reserves 12.5% if there are three fair share identifiers.\n\nA computeReservation value of 25 indicates that AWS Batch should reserve 25% of the\nmaximum available vCPU if there's only one fair share identifier,\n6.25% if there are two fair share identifiers,\nand 1.56% if there are three fair share identifiers.", - "stability": "experimental", - "summary": "Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 111 - }, - "name": "computeReservation", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- 0: only the current job usage is considered", - "remarks": "The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue.\nA value of zero (0) indicates that only current usage is measured.\nThe decay is linear and gives preference to newer jobs.\n\nThe maximum supported value is 604800 seconds (1 week).", - "stability": "experimental", - "summary": "The amount of time to use to measure the usage of each job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 123 - }, - "name": "shareDecay", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/scheduling-policy:IFairshareSchedulingPolicy" - }, - "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IFargateComputeEnvironment", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1060 - }, - "name": "IFargateComputeEnvironment", - "symbolId": "lib/managed-compute-environment:IFargateComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.IJobDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Represents a JobDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "interfaces": [ - "aws-cdk-lib.IResource" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 8 - }, - "methods": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Add a RetryStrategy to this JobDefinition." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 70 - }, - "name": "addRetryStrategy", - "parameters": [ - { - "name": "strategy", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - } - } - ] - } - ], - "name": "IJobDefinition", - "properties": [ - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The ARN of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 14 - }, - "name": "jobDefinitionArn", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The name of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 21 - }, - "name": "jobDefinitionName", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- no `RetryStrategy`", - "stability": "experimental", - "summary": "Defines the retry behavior for this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 47 - }, - "name": "retryStrategies", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters", - "stability": "experimental", - "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 32 - }, - "name": "parameters", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "any" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "1", - "remarks": "The job is retried on failure the same number of attempts as the value.", - "stability": "experimental", - "summary": "The number of times to retry a job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 40 - }, - "name": "retryAttempts", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", - "stability": "experimental", - "summary": "The priority of this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 56 - }, - "name": "schedulingPriority", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no timeout", - "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", - "stability": "experimental", - "summary": "The timeout time for jobs that are submitted with this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 65 - }, - "name": "timeout", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/job-definition-base:IJobDefinition" - }, - "@aws-cdk/aws-batch-alpha.IJobQueue": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Represents a JobQueue." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue", - "interfaces": [ - "aws-cdk-lib.IResource" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 10 - }, - "methods": [ - { - "abstract": true, - "docs": { - "remarks": "The Queue will prefer lower-order `ComputeEnvironment`s.", - "stability": "experimental", - "summary": "Add a `ComputeEnvironment` to this Queue." - }, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 66 - }, - "name": "addComputeEnvironment", - "parameters": [ - { - "name": "computeEnvironment", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - } - }, - { - "name": "order", - "type": { - "primitive": "number" - } - } - ] - } - ], - "name": "IJobQueue", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", - "stability": "experimental", - "summary": "The set of compute environments mapped to a job queue and their order relative to each other." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 37 - }, - "name": "computeEnvironments", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The ARN of this job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 24 - }, - "name": "jobQueueArn", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", - "stability": "experimental", - "summary": "The name of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 17 - }, - "name": "jobQueueName", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1.", - "stability": "experimental", - "summary": "The priority of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 45 - }, - "name": "priority", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", - "stability": "experimental", - "summary": "If the job queue is enabled, it is able to accept jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 53 - }, - "name": "enabled", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- no scheduling policy", - "remarks": "Instructs the Scheduler how to schedule different jobs.", - "stability": "experimental", - "summary": "The SchedulingPolicy for this JobQueue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 60 - }, - "name": "schedulingPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" - } - } - ], - "symbolId": "lib/job-queue:IJobQueue" - }, - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "remarks": "Batch will provision EC2 Instances to\nmeet the requirements of the jobs executing in this ComputeEnvironment.", - "stability": "experimental", - "summary": "Represents a Managed ComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "aws-cdk-lib.aws_ec2.IConnectable", - "aws-cdk-lib.ITaggable" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 14 - }, - "name": "IManagedComputeEnvironment", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", - "stability": "experimental", - "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 23 - }, - "name": "maxvCpus", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The security groups this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 78 - }, - "name": "securityGroups", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", - "see": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html", - "stability": "experimental", - "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 42 - }, - "name": "replaceComputeEnvironment", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", - "stability": "experimental", - "summary": "Whether or not to use spot instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 52 - }, - "name": "spot", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", - "stability": "experimental", - "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 73 - }, - "name": "terminateOnUpdate", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "30 minutes", - "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", - "stability": "experimental", - "summary": "Only meaningful if `terminateOnUpdate` is `false`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 62 - }, - "name": "updateTimeout", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "If you specify a specific AMI, this property will be ignored.", - "stability": "experimental", - "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 93 - }, - "name": "updateToLatestImageVersion", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The VPC Subnets this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 83 - }, - "name": "vpcSubnets", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.SubnetSelection" - } - } - ], - "symbolId": "lib/managed-compute-environment:IManagedComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 235 - }, - "methods": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Add an instance class to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 348 - }, - "name": "addInstanceClass", - "parameters": [ - { - "name": "instanceClass", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - } - } - ] - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Add an instance type to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 343 - }, - "name": "addInstanceType", - "parameters": [ - { - "name": "instanceType", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - } - } - ] - } - ], - "name": "IManagedEc2EcsComputeEnvironment", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the size.", - "stability": "experimental", - "summary": "The instance classes that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 287 - }, - "name": "instanceClasses", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 280 - }, - "name": "instanceTypes", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", - "stability": "experimental", - "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 253 - }, - "name": "allocationStrategy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" - } - }, - { - "abstract": true, - "docs": { - "default": "- ECS_AL2 compatible AMI ids for non-GPU instances, ECS_AL2_NVIDIA compatible AMI ids for GPU instances", - "remarks": "Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches.", - "stability": "experimental", - "summary": "Configure which AMIs this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 244 - }, - "name": "images", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- a role will be created", - "stability": "experimental", - "summary": "The execution Role that instances launched by this Compute Environment will use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 304 - }, - "name": "instanceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "no launch template", - "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", - "stability": "experimental", - "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 317 - }, - "name": "launchTemplate", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" - } - }, - { - "abstract": true, - "docs": { - "default": "0", - "stability": "experimental", - "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 325 - }, - "name": "minvCpus", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no placement group", - "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", - "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", - "stability": "experimental", - "summary": "The EC2 placement group to associate with your compute resources." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 338 - }, - "name": "placementGroup", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" - } - }, - { - "abstract": true, - "docs": { - "default": "- 100%", - "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.", - "stability": "experimental", - "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 265 - }, - "name": "spotBidPercentage", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- a new Role will be created", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html", - "stability": "experimental", - "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 274 - }, - "name": "spotFleetRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", - "stability": "experimental", - "summary": "Whether or not to use batch's optimal instance type." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 297 - }, - "name": "useOptimalInstanceClasses", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:IManagedEc2EcsComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.ISchedulingPolicy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "remarks": "Scheduling Policies tell the Batch\nJob Scheduler how to schedule incoming jobs.", - "stability": "experimental", - "summary": "Represents a Scheduling Policy." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy", - "interfaces": [ - "aws-cdk-lib.IResource" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 9 - }, - "name": "ISchedulingPolicy", - "properties": [ - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The arn of this scheduling policy." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 22 - }, - "name": "schedulingPolicyArn", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "custom": { - "attribute": "true" - }, - "stability": "experimental", - "summary": "The name of this scheduling policy." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 15 - }, - "name": "schedulingPolicyName", - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/scheduling-policy:ISchedulingPolicy" - }, - "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "remarks": "Batch will not provision instances on your behalf\nin this ComputeEvironment.", - "stability": "experimental", - "summary": "Represents an UnmanagedComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 11 - }, - "name": "IUnmanagedComputeEnvironment", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", - "stability": "experimental", - "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 19 - }, - "name": "unmanagedvCPUs", - "optional": true, - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/unmanaged-compute-environment:IUnmanagedComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.ImagePullPolicy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Determines when the image is pulled from the registry to launch a container." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ImagePullPolicy", - "kind": "enum", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 256 - }, - "members": [ - { - "docs": { - "remarks": "If the kubelet has a container image with that exact digest cached locally,\nthe kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest,\nand uses that image to launch the container.", - "see": "https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier", - "stability": "experimental", - "summary": "Every time the kubelet launches a container, the kubelet queries the container image registry to resolve the name to an image digest." - }, - "name": "ALWAYS" - }, - { - "docs": { - "stability": "experimental", - "summary": "The image is pulled only if it is not already present locally." - }, - "name": "IF_NOT_PRESENT" - }, - { - "docs": { - "remarks": "If the image is somehow already present locally,\nthe kubelet attempts to start the container; otherwise, startup fails.\nSee pre-pulled images for more details.", - "see": "https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images", - "stability": "experimental", - "summary": "The kubelet does not try fetching the image." - }, - "name": "NEVER" - } - ], - "name": "ImagePullPolicy", - "symbolId": "lib/eks-container-definition:ImagePullPolicy" - }, - "@aws-cdk/aws-batch-alpha.JobDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props common to all JobDefinitions." - }, - "fqn": "@aws-cdk/aws-batch-alpha.JobDefinitionProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 76 - }, - "name": "JobDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- generated by CloudFormation", - "stability": "experimental", - "summary": "The name of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 82 - }, - "name": "jobDefinitionName", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters", - "stability": "experimental", - "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 93 - }, - "name": "parameters", - "optional": true, - "type": { - "collection": { - "elementtype": { - "primitive": "any" - }, - "kind": "map" - } - } - }, - { - "abstract": true, - "docs": { - "default": "1", - "remarks": "The job is retried on failure the same number of attempts as the value.", - "stability": "experimental", - "summary": "The number of times to retry a job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 101 - }, - "name": "retryAttempts", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no `RetryStrategy`", - "stability": "experimental", - "summary": "Defines the retry behavior for this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 108 - }, - "name": "retryStrategies", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", - "stability": "experimental", - "summary": "The priority of this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 117 - }, - "name": "schedulingPriority", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no timeout", - "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", - "stability": "experimental", - "summary": "The timeout time for jobs that are submitted with this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 126 - }, - "name": "timeout", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/job-definition-base:JobDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.JobQueue": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "remarks": "Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked.", - "stability": "experimental", - "summary": "JobQueues can receive Jobs, which are removed from the queue when sent to the linked ComputeEnvironment(s) to be executed." - }, - "fqn": "@aws-cdk/aws-batch-alpha.JobQueue", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 171 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.JobQueueProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IJobQueue" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 143 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "refer to an existing JobQueue by its arn." - }, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 147 - }, - "name": "fromJobQueueArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "jobQueueArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IJobQueue" - } - }, - "static": true - }, - { - "docs": { - "remarks": "The Queue will prefer lower-order `ComputeEnvironment`s.", - "stability": "experimental", - "summary": "Add a `ComputeEnvironment` to this Queue." - }, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 206 - }, - "name": "addComputeEnvironment", - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "parameters": [ - { - "name": "computeEnvironment", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - } - }, - { - "name": "order", - "type": { - "primitive": "number" - } - } - ] - } - ], - "name": "JobQueue", - "properties": [ - { - "docs": { - "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", - "stability": "experimental", - "summary": "The set of compute environments mapped to a job queue and their order relative to each other." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 163 - }, - "name": "computeEnvironments", - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 168 - }, - "name": "jobQueueArn", - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", - "stability": "experimental", - "summary": "The name of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 169 - }, - "name": "jobQueueName", - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1.", - "stability": "experimental", - "summary": "The priority of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 164 - }, - "name": "priority", - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", - "stability": "experimental", - "summary": "If the job queue is enabled, it is able to accept jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 165 - }, - "name": "enabled", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "Instructs the Scheduler how to schedule different jobs.", - "stability": "experimental", - "summary": "The SchedulingPolicy for this JobQueue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 166 - }, - "name": "schedulingPolicy", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobQueue", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" - } - } - ], - "symbolId": "lib/job-queue:JobQueue" - }, - "@aws-cdk/aws-batch-alpha.JobQueueProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure a JobQueue." - }, - "fqn": "@aws-cdk/aws-batch-alpha.JobQueueProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 72 - }, - "name": "JobQueueProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "The job scheduler uses this parameter to determine which compute environment runs a specific job.\nCompute environments must be in the VALID state before you can associate them with a job queue.\nYou can associate up to three compute environments with a job queue.\nAll of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT);\nEC2 and Fargate compute environments can't be mixed.\n\n*Note*: All compute environments that are associated with a job queue must share the same architecture.\nAWS Batch doesn't support mixing compute environment architecture types in a single job queue.", - "stability": "experimental", - "summary": "The set of compute environments mapped to a job queue and their order relative to each other." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 86 - }, - "name": "computeEnvironments", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish.", - "stability": "experimental", - "summary": "If the job queue is enabled, it is able to accept jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 112 - }, - "name": "enabled", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "- no name", - "remarks": "It can be up to 128 letters long.\nIt can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_)", - "stability": "experimental", - "summary": "The name of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 104 - }, - "name": "jobQueueName", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "1", - "remarks": "Job queues with a higher priority are evaluated first when associated with the same compute environment.\nPriority is determined in descending order.\nFor example, a job queue with a priority of 10 is given scheduling preference over a job queue with a priority of 1.", - "stability": "experimental", - "summary": "The priority of the job queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 96 - }, - "name": "priority", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no scheduling policy", - "remarks": "Instructs the Scheduler how to schedule different jobs.", - "stability": "experimental", - "summary": "The SchedulingPolicy for this JobQueue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 119 - }, - "name": "schedulingPolicy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ISchedulingPolicy" - } - } - ], - "symbolId": "lib/job-queue:JobQueueProps" - }, - "@aws-cdk/aws-batch-alpha.LinuxParameters": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "constructs.Construct", - "docs": { - "stability": "experimental", - "summary": "Linux-specific options that are applied to the container." - }, - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParameters", - "initializer": { - "docs": { - "stability": "experimental", - "summary": "Constructs a new instance of the LinuxParameters class." - }, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 87 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParametersProps" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 53 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Adds one or more host devices to a container." - }, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 111 - }, - "name": "addDevices", - "parameters": [ - { - "name": "device", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Device" - }, - "variadic": true - } - ], - "variadic": true - }, - { - "docs": { - "remarks": "Only works with EC2 launch type.", - "stability": "experimental", - "summary": "Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container." - }, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 120 - }, - "name": "addTmpfs", - "parameters": [ - { - "name": "tmpfs", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs" - }, - "variadic": true - } - ], - "variadic": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Renders the Linux parameters to the Batch version of this resource, which does not have 'capabilities' and requires tmpfs.containerPath to be defined." - }, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 128 - }, - "name": "renderLinuxParameters", - "returns": { - "type": { - "fqn": "aws-cdk-lib.aws_batch.CfnJobDefinition.LinuxParametersProperty" - } - } - } - ], - "name": "LinuxParameters", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "Device mounts." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 77 - }, - "name": "devices", - "protected": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Device" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "TmpFs mounts." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 82 - }, - "name": "tmpfs", - "protected": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Whether the init process is enabled." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 57 - }, - "name": "initProcessEnabled", - "optional": true, - "protected": true, - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The max swap memory." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 67 - }, - "name": "maxSwap", - "optional": true, - "protected": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "remarks": "Not valid for Fargate launch type", - "stability": "experimental", - "summary": "The shared memory size (in MiB)." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 62 - }, - "name": "sharedMemorySize", - "optional": true, - "protected": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The swappiness behavior." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 72 - }, - "name": "swappiness", - "optional": true, - "protected": true, - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/linux-parameters:LinuxParameters" - }, - "@aws-cdk/aws-batch-alpha.LinuxParametersProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "The properties for defining Linux-specific options that are applied to the container." - }, - "fqn": "@aws-cdk/aws-batch-alpha.LinuxParametersProps", - "kind": "interface", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 8 - }, - "name": "LinuxParametersProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Specifies whether to run an init process inside the container that forwards signals and reaps processes." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 14 - }, - "name": "initProcessEnabled", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "No swap.", - "remarks": "This parameter\nwill be translated to the --memory-swap option to docker run.\n\nThis parameter is only supported when you are using the EC2 launch type.\nAccepted values are positive integers.", - "stability": "experimental", - "summary": "The total amount of swap memory a container can use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 32 - }, - "name": "maxSwap", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "No shared memory.", - "stability": "experimental", - "summary": "The value for the size of the /dev/shm volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 21 - }, - "name": "sharedMemorySize", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "60", - "remarks": "This parameter\nmaps to the --memory-swappiness option to docker run. The swappiness relates\nto the kernel's tendency to swap memory. A value of 0 will cause swapping to\nnot happen unless absolutely necessary. A value of 100 will cause pages to\nbe swapped very aggressively.\n\nThis parameter is only supported when you are using the EC2 launch type.\nAccepted values are whole numbers between 0 and 100. If a value is not\nspecified for maxSwap then this parameter is ignored.", - "stability": "experimental", - "summary": "This allows you to tune a container's memory swappiness behavior." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 47 - }, - "name": "swappiness", - "optional": true, - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/linux-parameters:LinuxParametersProps" - }, - "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for a ManagedComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 99 - }, - "name": "ManagedComputeEnvironmentProps", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "VPC in which this Compute Environment will launch Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 169 - }, - "name": "vpc", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IVpc" - } - }, - { - "abstract": true, - "docs": { - "default": "256", - "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", - "stability": "experimental", - "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to. Each vCPU is equivalent to 1024 CPU shares." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 111 - }, - "name": "maxvCpus", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", - "see": "https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html", - "stability": "experimental", - "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 132 - }, - "name": "replaceComputeEnvironment", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "new security groups will be created", - "stability": "experimental", - "summary": "The security groups this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 176 - }, - "name": "securityGroups", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", - "stability": "experimental", - "summary": "Whether or not to use spot instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 142 - }, - "name": "spot", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", - "stability": "experimental", - "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 164 - }, - "name": "terminateOnUpdate", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "30 minutes", - "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html", - "stability": "experimental", - "summary": "Only meaningful if `terminateOnUpdate` is `false`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 153 - }, - "name": "updateTimeout", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "If you specify a specific AMI, this property will be ignored.", - "stability": "experimental", - "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 193 - }, - "name": "updateToLatestImageVersion", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "abstract": true, - "docs": { - "default": "new subnets will be created", - "stability": "experimental", - "summary": "The VPC Subnets this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 183 - }, - "name": "vpcSubnets", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.SubnetSelection" - } - } - ], - "symbolId": "lib/managed-compute-environment:ManagedComputeEnvironmentProps" - }, - "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::ComputeEnvironment" - }, - "stability": "experimental", - "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 635 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 588 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "refer to an existing ComputeEnvironment by its arn." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 592 - }, - "name": "fromManagedEc2EcsComputeEnvironmentArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "managedEc2EcsComputeEnvironmentArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Add an instance class to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 705 - }, - "name": "addInstanceClass", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "parameters": [ - { - "name": "instanceClass", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - } - } - ] - }, - { - "docs": { - "stability": "experimental", - "summary": "Add an instance type to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 701 - }, - "name": "addInstanceType", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "parameters": [ - { - "name": "instanceType", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - } - } - ] - } - ], - "name": "ManagedEc2EcsComputeEnvironment", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this compute environment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 619 - }, - "name": "computeEnvironmentArn", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 620 - }, - "name": "computeEnvironmentName", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The network connections associated with this resource." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 210 - }, - "name": "connections", - "overrides": "aws-cdk-lib.aws_ec2.IConnectable", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.Connections" - } - }, - { - "docs": { - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 92 - }, - "name": "enabled", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the size.", - "stability": "experimental", - "summary": "The instance classes that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 627 - }, - "name": "instanceClasses", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 626 - }, - "name": "instanceTypes", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", - "stability": "experimental", - "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 201 - }, - "name": "maxvCpus", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The security groups this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 206 - }, - "name": "securityGroups", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "TagManager to set, remove and format tags." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 208 - }, - "name": "tags", - "overrides": "aws-cdk-lib.ITaggable", - "type": { - "fqn": "aws-cdk-lib.TagManager" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 623 - }, - "name": "allocationStrategy", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" - } - }, - { - "docs": { - "remarks": "Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches.", - "stability": "experimental", - "summary": "Configure which AMIs this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 622 - }, - "name": "images", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The execution Role that instances launched by this Compute Environment will use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 628 - }, - "name": "instanceRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", - "stability": "experimental", - "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 629 - }, - "name": "launchTemplate", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 630 - }, - "name": "minvCpus", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", - "stability": "experimental", - "summary": "The EC2 placement group to associate with your compute resources." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 631 - }, - "name": "placementGroup", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" - } - }, - { - "docs": { - "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", - "stability": "experimental", - "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 202 - }, - "name": "replaceComputeEnvironment", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 91 - }, - "name": "serviceRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", - "stability": "experimental", - "summary": "Whether or not to use spot instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 203 - }, - "name": "spot", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.", - "stability": "experimental", - "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 624 - }, - "name": "spotBidPercentage", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 625 - }, - "name": "spotFleetRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedEc2EcsComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", - "stability": "experimental", - "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 205 - }, - "name": "terminateOnUpdate", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", - "stability": "experimental", - "summary": "Only meaningful if `terminateOnUpdate` is `false`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 204 - }, - "name": "updateTimeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "docs": { - "remarks": "If you specify a specific AMI, this property will be ignored.", - "stability": "experimental", - "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 207 - }, - "name": "updateToLatestImageVersion", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:ManagedEc2EcsComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for a ManagedEc2EcsComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironmentProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 469 - }, - "name": "ManagedEc2EcsComputeEnvironmentProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", - "stability": "experimental", - "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 499 - }, - "name": "allocationStrategy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" - } - }, - { - "abstract": true, - "docs": { - "default": "- ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances", - "remarks": "If you specify this property with only `image` specified, then the\n`imageType` will default to `ECS_AL2`. *If your image needs GPU resources,\nspecify `ECS_AL2_NVIDIA`; otherwise, the instances will not be able to properly\njoin the ComputeEnvironment*.", - "stability": "experimental", - "summary": "Configure which AMIs this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 490 - }, - "name": "images", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EcsMachineImage" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the instance size.", - "stability": "experimental", - "summary": "The instance classes that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 539 - }, - "name": "instanceClasses", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- a role will be created", - "stability": "experimental", - "summary": "The execution Role that instances launched by this Compute Environment will use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 546 - }, - "name": "instanceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 530 - }, - "name": "instanceTypes", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "no launch template", - "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", - "stability": "experimental", - "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 559 - }, - "name": "launchTemplate", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" - } - }, - { - "abstract": true, - "docs": { - "default": "0", - "stability": "experimental", - "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 567 - }, - "name": "minvCpus", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no placement group", - "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", - "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", - "stability": "experimental", - "summary": "The EC2 placement group to associate with your compute resources." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 580 - }, - "name": "placementGroup", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" - } - }, - { - "abstract": true, - "docs": { - "default": "100%", - "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", - "stability": "experimental", - "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 513 - }, - "name": "spotBidPercentage", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- a new role will be created", - "see": "https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html", - "stability": "experimental", - "summary": "The service-linked role that Spot Fleet needs to launch instances on your behalf." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 522 - }, - "name": "spotFleetRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", - "stability": "experimental", - "summary": "Whether or not to use batch's optimal instance type." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 478 - }, - "name": "useOptimalInstanceClasses", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:ManagedEc2EcsComputeEnvironmentProps" - }, - "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::ComputeEnvironment" - }, - "stability": "experimental", - "summary": "A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 982 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 963 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Add an instance class to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1052 - }, - "name": "addInstanceClass", - "parameters": [ - { - "name": "instanceClass", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - } - } - ] - }, - { - "docs": { - "stability": "experimental", - "summary": "Add an instance type to this compute environment." - }, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 1048 - }, - "name": "addInstanceType", - "parameters": [ - { - "name": "instanceType", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - } - } - ] - } - ], - "name": "ManagedEc2EksComputeEnvironment", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this compute environment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 968 - }, - "name": "computeEnvironmentArn", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 967 - }, - "name": "computeEnvironmentName", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The network connections associated with this resource." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 210 - }, - "name": "connections", - "overrides": "aws-cdk-lib.aws_ec2.IConnectable", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.Connections" - } - }, - { - "docs": { - "remarks": "Please ensure that you have followed the steps at\n\nhttps://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html\n\nbefore attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster.\nIf you do not follow the steps in the link, the deployment fail with a message that the\ncompute environment did not stabilize.", - "stability": "experimental", - "summary": "The cluster that backs this Compute Environment. Required for Compute Environments running Kubernetes jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 965 - }, - "name": "eksCluster", - "type": { - "fqn": "aws-cdk-lib.aws_eks.ICluster" - } - }, - { - "docs": { - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 92 - }, - "name": "enabled", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 974 - }, - "name": "instanceClasses", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 973 - }, - "name": "instanceTypes", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "*Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or\n`AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances,\nThe scheduler may exceed this number by at most one of the instances specified in `instanceTypes`\nor `instanceClasses`.", - "stability": "experimental", - "summary": "The maximum vCpus this `ManagedComputeEnvironment` can scale up to." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 201 - }, - "name": "maxvCpus", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The security groups this Compute Environment will launch instances in." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 206 - }, - "name": "securityGroups", - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.ISecurityGroup" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "TagManager to set, remove and format tags." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 208 - }, - "name": "tags", - "overrides": "aws-cdk-lib.ITaggable", - "type": { - "fqn": "aws-cdk-lib.TagManager" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 971 - }, - "name": "allocationStrategy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Configure which AMIs this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 970 - }, - "name": "images", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The execution Role that instances launched by this Compute Environment will use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 975 - }, - "name": "instanceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "Cannot be 'default', start with 'kube-', or be longer than 64 characters.", - "stability": "experimental", - "summary": "The namespace of the Cluster." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 964 - }, - "name": "kubernetesNamespace", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.", - "stability": "experimental", - "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 976 - }, - "name": "launchTemplate", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 977 - }, - "name": "minvCpus", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", - "stability": "experimental", - "summary": "The EC2 placement group to associate with your compute resources." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 978 - }, - "name": "placementGroup", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" - } - }, - { - "docs": { - "remarks": "To enable more properties to be updated,\nset this property to `false`. When changing the value of this property to false,\ndo not change any other properties at the same time.\nIf other properties are changed at the same time,\nand the change needs to be rolled back but it can't,\nit's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state.\nYou can't update a stack that is in the UPDATE_ROLLBACK_FAILED state.\nHowever, if you can continue to roll it back,\nyou can return the stack to its original settings and then try to update it again.\n\nThe properties which require a replacement of the Compute Environment are:", - "stability": "experimental", - "summary": "Specifies whether this Compute Environment is replaced if an update is made that requires replacing its instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 202 - }, - "name": "replaceComputeEnvironment", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 91 - }, - "name": "serviceRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "Spot instances are less expensive EC2 instances that can be\nreclaimed by EC2 at any time; your job will be given two minutes\nof notice before reclamation.", - "stability": "experimental", - "summary": "Whether or not to use spot instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 203 - }, - "name": "spot", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", - "stability": "experimental", - "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 972 - }, - "name": "spotBidPercentage", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "If this is enabled, any terminated jobs may be retried, depending on the job's\nretry policy.", - "stability": "experimental", - "summary": "Whether or not any running jobs will be immediately terminated when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 205 - }, - "name": "terminateOnUpdate", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "If so,\nwhen an infrastructure update is triggered, any running jobs\nwill be allowed to run until `updateTimeout` has expired.", - "stability": "experimental", - "summary": "Only meaningful if `terminateOnUpdate` is `false`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 204 - }, - "name": "updateTimeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - }, - { - "docs": { - "remarks": "If you specify a specific AMI, this property will be ignored.", - "stability": "experimental", - "summary": "Whether or not the AMI is updated to the latest one supported by Batch when an infrastructure update occurs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 207 - }, - "name": "updateToLatestImageVersion", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IManagedComputeEnvironment", - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:ManagedEc2EksComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props for a ManagedEc2EksComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironmentProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ManagedComputeEnvironmentProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 835 - }, - "name": "ManagedEc2EksComputeEnvironmentProps", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "Please ensure that you have followed the steps at\n\nhttps://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html\n\nbefore attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster.\nIf you do not follow the steps in the link, the deployment fail with a message that the\ncompute environment did not stabilize.", - "stability": "experimental", - "summary": "The cluster that backs this Compute Environment. Required for Compute Environments running Kubernetes jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 853 - }, - "name": "eksCluster", - "type": { - "fqn": "aws-cdk-lib.aws_eks.ICluster" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The namespace of the Cluster." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 839 - }, - "name": "kubernetesNamespace", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- `BEST_FIT_PROGRESSIVE` if not using Spot instances,\n`SPOT_CAPACITY_OPTIMIZED` if using Spot instances.", - "stability": "experimental", - "summary": "The allocation strategy to use if not enough instances of the best fitting instance type can be allocated." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 883 - }, - "name": "allocationStrategy", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.AllocationStrategy" - } - }, - { - "abstract": true, - "docs": { - "default": "If `imageKubernetesVersion` is specified,\n- EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances,\nOtherwise,\n- ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances,", - "stability": "experimental", - "summary": "Configure which AMIs this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 874 - }, - "name": "images", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.EksMachineImage" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.\nBatch will automatically choose the instance size.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 914 - }, - "name": "instanceClasses", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceClass" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- a role will be created", - "stability": "experimental", - "summary": "The execution Role that instances launched by this Compute Environment will use." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 921 - }, - "name": "instanceRole", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "abstract": true, - "docs": { - "default": "- the instances Batch considers will be used (currently C4, M4, and R4)", - "remarks": "Which one is chosen depends on the `AllocationStrategy` used.", - "stability": "experimental", - "summary": "The instance types that this Compute Environment can launch." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 905 - }, - "name": "instanceTypes", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "- no launch template", - "remarks": "*Note*: if `securityGroups` is specified on both your\nlaunch template and this Compute Environment, **the\n`securityGroup`s on the Compute Environment override the\nones on the launch template.**", - "stability": "experimental", - "summary": "The Launch Template that this Compute Environment will use to provision EC2 Instances." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 934 - }, - "name": "launchTemplate", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.ILaunchTemplate" - } - }, - { - "abstract": true, - "docs": { - "default": "0", - "stability": "experimental", - "summary": "The minimum vCPUs that an environment should maintain, even if the compute environment is DISABLED." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 942 - }, - "name": "minvCpus", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "- no placement group", - "remarks": "If you intend to submit multi-node parallel jobs to this Compute Environment,\nyou should consider creating a cluster placement group and associate it with your compute resources.\nThis keeps your multi-node parallel job on a logical grouping of instances\nwithin a single Availability Zone with high network flow potential.", - "see": "https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html", - "stability": "experimental", - "summary": "The EC2 placement group to associate with your compute resources." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 955 - }, - "name": "placementGroup", - "optional": true, - "type": { - "fqn": "aws-cdk-lib.aws_ec2.IPlacementGroup" - } - }, - { - "abstract": true, - "docs": { - "default": "- 100%", - "remarks": "For example, if your maximum percentage is 20%, the Spot price must be\nless than 20% of the current On-Demand price for that Instance.\nYou always pay the lowest market price and never more than your maximum percentage.\nFor most use cases, Batch recommends leaving this field empty.\n\nImplies `spot == true` if set", - "stability": "experimental", - "summary": "The maximum percentage that a Spot Instance price can be when compared with the On-Demand price for that instance type before instances are launched." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 897 - }, - "name": "spotBidPercentage", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "remarks": "The optimal instance type is equivalent to adding the\nC4, M4, and R4 instance classes. You can specify other instance classes\n(of the same architecture) in addition to the optimal instance classes.", - "stability": "experimental", - "summary": "Whether or not to use batch's optimal instance type." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/managed-compute-environment.ts", - "line": 863 - }, - "name": "useOptimalInstanceClasses", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/managed-compute-environment:ManagedEc2EksComputeEnvironmentProps" - }, - "@aws-cdk/aws-batch-alpha.MultiNodeContainer": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Runs the container on nodes [startNode, endNode]." - }, - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer", - "kind": "interface", - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 47 - }, - "name": "MultiNodeContainer", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The container that this node range will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 65 - }, - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IEcsContainerDefinition" - } - }, - { - "abstract": true, - "docs": { - "remarks": "The container is run on all nodes in the range [startNode, endNode] (inclusive)", - "stability": "experimental", - "summary": "The index of the last node to run this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 60 - }, - "name": "endNode", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "remarks": "The container is run on all nodes in the range [startNode, endNode] (inclusive)", - "stability": "experimental", - "summary": "The index of the first node to run this container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 53 - }, - "name": "startNode", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/multinode-job-definition:MultiNodeContainer" - }, - "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::JobDefinition" - }, - "stability": "experimental", - "summary": "A JobDefinition that uses Ecs orchestration to run multiple containers." - }, - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 134 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IJobDefinition" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 109 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "refer to an existing JobDefinition by its arn." - }, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 113 - }, - "name": "fromJobDefinitionArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "jobDefinitionArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IJobDefinition" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a container to this multinode job." - }, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 174 - }, - "name": "addContainer", - "parameters": [ - { - "name": "container", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" - } - } - ] - }, - { - "docs": { - "stability": "experimental", - "summary": "Add a RetryStrategy to this JobDefinition." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 259 - }, - "name": "addRetryStrategy", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "parameters": [ - { - "name": "strategy", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - } - } - ] - } - ], - "name": "MultiNodeJobDefinition", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The containers that this multinode job will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 126 - }, - "name": "containers", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" - }, - "kind": "array" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The instance type that this job definition will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 127 - }, - "name": "instanceType", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 131 - }, - "name": "jobDefinitionArn", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 132 - }, - "name": "jobDefinitionName", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Defines the retry behavior for this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 243 - }, - "name": "retryStrategies", - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - }, - "kind": "array" - } - } - }, - { - "docs": { - "remarks": "The main node is responsible for orchestration.", - "stability": "experimental", - "summary": "The index of the main node in this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 128 - }, - "name": "mainNode", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The default parameters passed to the container These parameters can be referenced in the `command` that you give to the container." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 241 - }, - "name": "parameters", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "collection": { - "elementtype": { - "primitive": "any" - }, - "kind": "map" - } - } - }, - { - "docs": { - "stability": "experimental", - "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 129 - }, - "name": "propagateTags", - "optional": true, - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "remarks": "The job is retried on failure the same number of attempts as the value.", - "stability": "experimental", - "summary": "The number of times to retry a job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 242 - }, - "name": "retryAttempts", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "Only used in Fairshare Scheduling\nto decide which job to run first when there are multiple jobs\nwith the same share identifier.", - "stability": "experimental", - "summary": "The priority of this Job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 244 - }, - "name": "schedulingPriority", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "primitive": "number" - } - }, - { - "docs": { - "remarks": "After the amount of time you specify passes,\nBatch terminates your jobs if they aren't finished.", - "stability": "experimental", - "summary": "The timeout time for jobs that are submitted with this job definition." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 245 - }, - "name": "timeout", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IJobDefinition", - "type": { - "fqn": "aws-cdk-lib.Duration" - } - } - ], - "symbolId": "lib/multinode-job-definition:MultiNodeJobDefinition" - }, - "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Props to configure a MultiNodeJobDefinition." - }, - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinitionProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.JobDefinitionProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 71 - }, - "name": "MultiNodeJobDefinitionProps", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The instance type that this job definition will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 76 - }, - "name": "instanceType", - "type": { - "fqn": "aws-cdk-lib.aws_ec2.InstanceType" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "see": "https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/", - "stability": "experimental", - "summary": "The containers that this multinode job will run." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 85 - }, - "name": "containers", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.MultiNodeContainer" - }, - "kind": "array" - } - } - }, - { - "abstract": true, - "docs": { - "default": "0", - "remarks": "The main node is responsible for orchestration.", - "stability": "experimental", - "summary": "The index of the main node in this job." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 93 - }, - "name": "mainNode", - "optional": true, - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "default": "false", - "stability": "experimental", - "summary": "Whether to propogate tags from the JobDefinition to the ECS task that Batch spawns." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/multinode-job-definition.ts", - "line": 101 - }, - "name": "propagateTags", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/multinode-job-definition:MultiNodeJobDefinitionProps" - }, - "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "remarks": "The JobQueue will prioritize the lowest-order ComputeEnvironment.", - "stability": "experimental", - "summary": "Assigns an order to a ComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.OrderedComputeEnvironment", - "kind": "interface", - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 126 - }, - "name": "OrderedComputeEnvironment", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The ComputeEnvironment to link to this JobQueue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 130 - }, - "name": "computeEnvironment", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The order associated with `computeEnvironment`." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-queue.ts", - "line": 135 - }, - "name": "order", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/job-queue:OrderedComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.Reason": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Common job exit reasons." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Reason", - "initializer": { - "docs": { - "stability": "experimental" - } - }, - "kind": "class", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 201 - }, - "methods": [ - { - "docs": { - "remarks": "Note that all specified conditions must be met for this reason to match.", - "stability": "experimental", - "summary": "A custom Reason that can match on multiple conditions." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 227 - }, - "name": "custom", - "parameters": [ - { - "name": "customReasonProps", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.CustomReason" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - }, - "static": true - } - ], - "name": "Reason", - "properties": [ - { - "const": true, - "docs": { - "stability": "experimental", - "summary": "Will only match if the Docker container could not be pulled." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 212 - }, - "name": "CANNOT_PULL_CONTAINER", - "static": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - }, - { - "const": true, - "docs": { - "stability": "experimental", - "summary": "Will match any non-zero exit code." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 205 - }, - "name": "NON_ZERO_EXIT_CODE", - "static": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - }, - { - "const": true, - "docs": { - "stability": "experimental", - "summary": "Will only match if the Spot instance executing the job was reclaimed." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 219 - }, - "name": "SPOT_INSTANCE_RECLAIMED", - "static": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - } - ], - "symbolId": "lib/job-definition-base:Reason" - }, - "@aws-cdk/aws-batch-alpha.RetryStrategy": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "Define how Jobs using this JobDefinition respond to different exit conditions." - }, - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 150 - }, - "parameters": [ - { - "name": "action", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Action" - } - }, - { - "name": "on", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 132 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Create a new RetryStrategy." - }, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 136 - }, - "name": "of", - "parameters": [ - { - "name": "action", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Action" - } - }, - { - "name": "on", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.RetryStrategy" - } - }, - "static": true - } - ], - "name": "RetryStrategy", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The action to take when the job exits with the Reason specified." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 143 - }, - "name": "action", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Action" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "If the job exits with this Reason it will trigger the specified Action." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/job-definition-base.ts", - "line": 148 - }, - "name": "on", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Reason" - } - } - ], - "symbolId": "lib/job-definition-base:RetryStrategy" - }, - "@aws-cdk/aws-batch-alpha.Secret": { - "abstract": true, - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "A secret environment variable." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Secret", - "initializer": { - "docs": { - "stability": "experimental" - } - }, - "kind": "class", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 36 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Creates a environment variable value from a secret stored in AWS Secrets Manager." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 58 - }, - "name": "fromSecretsManager", - "parameters": [ - { - "docs": { - "summary": "the secret stored in AWS Secrets Manager." - }, - "name": "secret", - "type": { - "fqn": "aws-cdk-lib.aws_secretsmanager.ISecret" - } - }, - { - "docs": { - "remarks": "Only values in JSON format are supported.\nIf you do not specify a JSON field, then the full content of the secret is\nused.", - "summary": "the name of the field with the value that you want to set as the environment variable value." - }, - "name": "field", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Creates a environment variable value from a secret stored in AWS Secrets Manager." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 77 - }, - "name": "fromSecretsManagerVersion", - "parameters": [ - { - "docs": { - "summary": "the secret stored in AWS Secrets Manager." - }, - "name": "secret", - "type": { - "fqn": "aws-cdk-lib.aws_secretsmanager.ISecret" - } - }, - { - "docs": { - "summary": "the version information to reference the secret." - }, - "name": "versionInfo", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.SecretVersionInfo" - } - }, - { - "docs": { - "remarks": "Only values in JSON format are supported.\nIf you do not specify a JSON field, then the full content of the secret is\nused.", - "summary": "the name of the field with the value that you want to set as the environment variable value." - }, - "name": "field", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - } - }, - "static": true - }, - { - "docs": { - "stability": "experimental", - "summary": "Creates an environment variable value from a parameter stored in AWS Systems Manager Parameter Store." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 41 - }, - "name": "fromSsmParameter", - "parameters": [ - { - "name": "parameter", - "type": { - "fqn": "aws-cdk-lib.aws_ssm.IParameter" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.Secret" - } - }, - "static": true - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Grants reading the secret to a principal." - }, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 98 - }, - "name": "grantRead", - "parameters": [ - { - "name": "grantee", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IGrantable" - } - } - ], - "returns": { - "type": { - "fqn": "aws-cdk-lib.aws_iam.Grant" - } - } - } - ], - "name": "Secret", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The ARN of the secret." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 88 - }, - "name": "arn", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "Whether this secret uses a specific JSON field." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 93 - }, - "name": "hasField", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/ecs-container-definition:Secret" - }, - "@aws-cdk/aws-batch-alpha.SecretPathVolume": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "@aws-cdk/aws-batch-alpha.EksVolume", - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", - "stability": "experimental", - "summary": "Specifies the configuration of a Kubernetes secret volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolume", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 902 - }, - "parameters": [ - { - "name": "options", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions" - } - } - ] - }, - "kind": "class", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 879 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "returns `true` if `x` is a `SecretPathVolume` and `false` otherwise." - }, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 883 - }, - "name": "isSecretPathVolume", - "parameters": [ - { - "name": "x", - "type": { - "primitive": "any" - } - } - ], - "returns": { - "type": { - "primitive": "boolean" - } - }, - "static": true - } - ], - "name": "SecretPathVolume", - "properties": [ - { - "docs": { - "remarks": "Must be a valid DNS subdomain name.", - "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", - "stability": "experimental", - "summary": "The name of the secret." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 893 - }, - "name": "secretName", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "default": "true", - "stability": "experimental", - "summary": "Specifies whether the secret or the secret's keys must be defined." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 900 - }, - "name": "optional", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-container-definition:SecretPathVolume" - }, - "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "see": "https://kubernetes.io/docs/concepts/storage/volumes/#secret", - "stability": "experimental", - "summary": "Options for a Kubernetes SecretPath Volume." - }, - "fqn": "@aws-cdk/aws-batch-alpha.SecretPathVolumeOptions", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.EksVolumeOptions" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 857 - }, - "name": "SecretPathVolumeOptions", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "Must be a valid DNS subdomain name.", - "see": "https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names", - "stability": "experimental", - "summary": "The name of the secret." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 864 - }, - "name": "secretName", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "true", - "stability": "experimental", - "summary": "Specifies whether the secret or the secret's keys must be defined." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/eks-container-definition.ts", - "line": 871 - }, - "name": "optional", - "optional": true, - "type": { - "primitive": "boolean" - } - } - ], - "symbolId": "lib/eks-container-definition:SecretPathVolumeOptions" - }, - "@aws-cdk/aws-batch-alpha.SecretVersionInfo": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "Specify the secret's version id or version stage." - }, - "fqn": "@aws-cdk/aws-batch-alpha.SecretVersionInfo", - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 18 - }, - "name": "SecretVersionInfo", - "properties": [ - { - "abstract": true, - "docs": { - "default": "- use default version id", - "stability": "experimental", - "summary": "version id of the secret." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 24 - }, - "name": "versionId", - "optional": true, - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "default": "- use default version stage", - "stability": "experimental", - "summary": "version stage of the secret." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 30 - }, - "name": "versionStage", - "optional": true, - "type": { - "primitive": "string" - } - } - ], - "symbolId": "lib/ecs-container-definition:SecretVersionInfo" - }, - "@aws-cdk/aws-batch-alpha.Share": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "remarks": "All Job Definitions that\ndeclare a share identifier will be considered members of the Share\ndefined by that share identifier.\n\nThe Scheduler divides the maximum available vCPUs of the ComputeEnvironment\namong Jobs in the Queue based on their shareIdentifier and the weightFactor\nassociated with that shareIdentifier.", - "stability": "experimental", - "summary": "Represents a group of Job Definitions." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Share", - "kind": "interface", - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 60 - }, - "name": "Share", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "All jobs that specify this share identifier\nwhen submitted to the queue will be considered as part of this Share.", - "stability": "experimental", - "summary": "The identifier of this Share." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 65 - }, - "name": "shareIdentifier", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "remarks": "The Scheduler decides which jobs to put in the Compute Environment\nsuch that the following ratio is equal for each job:\n\n`sharevCpu / weightFactor`,\n\nwhere `sharevCpu` is the total amount of vCPU given to that particular share; that is,\nthe sum of the vCPU of each job currently in the Compute Environment for that share.\n\nSee the readme of this module for a detailed example that shows how these are used,\nhow it relates to `computeReservation`, and how `shareDecay` affects these calculations.", - "stability": "experimental", - "summary": "The weight factor given to this Share." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/scheduling-policy.ts", - "line": 79 - }, - "name": "weightFactor", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/scheduling-policy:Share" - }, - "@aws-cdk/aws-batch-alpha.Tmpfs": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "stability": "experimental", - "summary": "The details of a tmpfs mount for a container." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Tmpfs", - "kind": "interface", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 168 - }, - "name": "Tmpfs", - "properties": [ - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The absolute file path where the tmpfs volume is to be mounted." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 172 - }, - "name": "containerPath", - "type": { - "primitive": "string" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The size (in MiB) of the tmpfs volume." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 177 - }, - "name": "size", - "type": { - "fqn": "aws-cdk-lib.Size" - } - }, - { - "abstract": true, - "docs": { - "default": "none", - "remarks": "For more information, see\n[TmpfsMountOptions](https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_Tmpfs.html).", - "stability": "experimental", - "summary": "The list of tmpfs volume mount options." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 185 - }, - "name": "mountOptions", - "optional": true, - "type": { - "collection": { - "elementtype": { - "fqn": "@aws-cdk/aws-batch-alpha.TmpfsMountOption" - }, - "kind": "array" - } - } - } - ], - "symbolId": "lib/linux-parameters:Tmpfs" - }, - "@aws-cdk/aws-batch-alpha.TmpfsMountOption": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "The supported options for a tmpfs mount for a container." - }, - "fqn": "@aws-cdk/aws-batch-alpha.TmpfsMountOption", - "kind": "enum", - "locationInModule": { - "filename": "lib/linux-parameters.ts", - "line": 211 - }, - "members": [ - { - "docs": { - "stability": "experimental" - }, - "name": "DEFAULTS" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RO" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RW" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "SUID" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NOSUID" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "DEV" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NODEV" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "EXEC" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NOEXEC" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "SYNC" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "ASYNC" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "DIRSYNC" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "REMOUNT" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "MAND" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NOMAND" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "ATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NOATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "DIRATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NODIRATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "BIND" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RBIND" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "UNBINDABLE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RUNBINDABLE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "PRIVATE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RPRIVATE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "SHARED" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RSHARED" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "SLAVE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RSLAVE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "RELATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NORELATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "STRICTATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NOSTRICTATIME" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "MODE" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "UID" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "GID" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NR_INODES" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "NR_BLOCKS" - }, - { - "docs": { - "stability": "experimental" - }, - "name": "MPOL" - } - ], - "name": "TmpfsMountOption", - "symbolId": "lib/linux-parameters:TmpfsMountOption" - }, - "@aws-cdk/aws-batch-alpha.Ulimit": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "remarks": "Used by the Docker daemon.", - "stability": "experimental", - "summary": "Sets limits for a resource with `ulimit` on linux systems." - }, - "fqn": "@aws-cdk/aws-batch-alpha.Ulimit", - "kind": "interface", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 734 - }, - "name": "Ulimit", - "properties": [ - { - "abstract": true, - "docs": { - "remarks": "The container will\nbe terminated if it exceeds this limit.", - "stability": "experimental", - "summary": "The hard limit for this resource." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 739 - }, - "name": "hardLimit", - "type": { - "primitive": "number" - } - }, - { - "abstract": true, - "docs": { - "stability": "experimental", - "summary": "The resource to limit." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 744 - }, - "name": "name", - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.UlimitName" - } - }, - { - "abstract": true, - "docs": { - "remarks": "The container will\nnot be terminated if it exceeds this limit.", - "stability": "experimental", - "summary": "The reservation for this resource." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 750 - }, - "name": "softLimit", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/ecs-container-definition:Ulimit" - }, - "@aws-cdk/aws-batch-alpha.UlimitName": { - "assembly": "@aws-cdk/aws-batch-alpha", - "docs": { - "stability": "experimental", - "summary": "The resources to be limited." - }, - "fqn": "@aws-cdk/aws-batch-alpha.UlimitName", - "kind": "enum", - "locationInModule": { - "filename": "lib/ecs-container-definition.ts", - "line": 756 - }, - "members": [ - { - "docs": { - "stability": "experimental", - "summary": "max core dump file size." - }, - "name": "CORE" - }, - { - "docs": { - "stability": "experimental", - "summary": "max cpu time (seconds) for a process." - }, - "name": "CPU" - }, - { - "docs": { - "stability": "experimental", - "summary": "max data segment size." - }, - "name": "DATA" - }, - { - "docs": { - "stability": "experimental", - "summary": "max file size." - }, - "name": "FSIZE" - }, - { - "docs": { - "stability": "experimental", - "summary": "max number of file locks." - }, - "name": "LOCKS" - }, - { - "docs": { - "stability": "experimental", - "summary": "max locked memory." - }, - "name": "MEMLOCK" - }, - { - "docs": { - "stability": "experimental", - "summary": "max POSIX message queue size." - }, - "name": "MSGQUEUE" - }, - { - "docs": { - "stability": "experimental", - "summary": "max nice value for any process this user is running." - }, - "name": "NICE" - }, - { - "docs": { - "stability": "experimental", - "summary": "maximum number of open file descriptors." - }, - "name": "NOFILE" - }, - { - "docs": { - "stability": "experimental", - "summary": "maximum number of processes." - }, - "name": "NPROC" - }, - { - "docs": { - "stability": "experimental", - "summary": "size of the process' resident set (in pages)." - }, - "name": "RSS" - }, - { - "docs": { - "stability": "experimental", - "summary": "max realtime priority." - }, - "name": "RTPRIO" - }, - { - "docs": { - "stability": "experimental", - "summary": "timeout for realtime tasks." - }, - "name": "RTTIME" - }, - { - "docs": { - "stability": "experimental", - "summary": "max number of pending signals." - }, - "name": "SIGPENDING" - }, - { - "docs": { - "stability": "experimental", - "summary": "max stack size (in bytes)." - }, - "name": "STACK" - } - ], - "name": "UlimitName", - "symbolId": "lib/ecs-container-definition:UlimitName" - }, - "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironment": { - "assembly": "@aws-cdk/aws-batch-alpha", - "base": "aws-cdk-lib.Resource", - "docs": { - "custom": { - "resource": "AWS::Batch::ComputeEnvironment" - }, - "stability": "experimental", - "summary": "Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf." - }, - "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironment", - "initializer": { - "docs": { - "stability": "experimental" - }, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 68 - }, - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "props", - "optional": true, - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps" - } - } - ] - }, - "interfaces": [ - "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", - "@aws-cdk/aws-batch-alpha.IComputeEnvironment" - ], - "kind": "class", - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 44 - }, - "methods": [ - { - "docs": { - "stability": "experimental", - "summary": "Import an UnmanagedComputeEnvironment by its arn." - }, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 48 - }, - "name": "fromUnmanagedComputeEnvironmentArn", - "parameters": [ - { - "name": "scope", - "type": { - "fqn": "constructs.Construct" - } - }, - { - "name": "id", - "type": { - "primitive": "string" - } - }, - { - "name": "unmanagedComputeEnvironmentArn", - "type": { - "primitive": "string" - } - } - ], - "returns": { - "type": { - "fqn": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment" - } - }, - "static": true - } - ], - "name": "UnmanagedComputeEnvironment", - "properties": [ - { - "docs": { - "stability": "experimental", - "summary": "The ARN of this compute environment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 65 - }, - "name": "computeEnvironmentArn", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The name of the ComputeEnvironment." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 66 - }, - "name": "computeEnvironmentName", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "string" - } - }, - { - "docs": { - "remarks": "Enabled ComputeEnvironments can accept jobs from a Queue and\ncan scale instances up or down.\nDisabled ComputeEnvironments cannot accept jobs from a Queue or\nscale instances up or down.\n\nIf you change a ComputeEnvironment from enabled to disabled while it is executing jobs,\nJobs in the `STARTED` or `RUNNING` states will not\nbe interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`.\n\nTo ensure you aren't billed for unused capacity, set `minvCpus` to `0`.", - "stability": "experimental", - "summary": "Whether or not this ComputeEnvironment can accept jobs from a Queue." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 92 - }, - "name": "enabled", - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "primitive": "boolean" - } - }, - { - "docs": { - "stability": "experimental", - "summary": "The role Batch uses to perform actions on your behalf in your account, such as provision instances to run your jobs." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/compute-environment-base.ts", - "line": 91 - }, - "name": "serviceRole", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IComputeEnvironment", - "type": { - "fqn": "aws-cdk-lib.aws_iam.IRole" - } - }, - { - "docs": { - "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", - "stability": "experimental", - "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 64 - }, - "name": "unmanagedvCPUs", - "optional": true, - "overrides": "@aws-cdk/aws-batch-alpha.IUnmanagedComputeEnvironment", - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/unmanaged-compute-environment:UnmanagedComputeEnvironment" - }, - "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps": { - "assembly": "@aws-cdk/aws-batch-alpha", - "datatype": true, - "docs": { - "remarks": "Batch will not provision instances on your behalf\nin this ComputeEvironment.", - "stability": "experimental", - "summary": "Represents an UnmanagedComputeEnvironment." - }, - "fqn": "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironmentProps", - "interfaces": [ - "@aws-cdk/aws-batch-alpha.ComputeEnvironmentProps" - ], - "kind": "interface", - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 26 - }, - "name": "UnmanagedComputeEnvironmentProps", - "properties": [ - { - "abstract": true, - "docs": { - "default": "0", - "remarks": "**If this parameter is not provided on a fairshare queue, no capacity is reserved**;\nthat is, the `FairshareSchedulingPolicy` is ignored.", - "stability": "experimental", - "summary": "The vCPUs this Compute Environment provides. Used only by the scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s." - }, - "immutable": true, - "locationInModule": { - "filename": "lib/unmanaged-compute-environment.ts", - "line": 36 - }, - "name": "unmanagedvCpus", - "optional": true, - "type": { - "primitive": "number" - } - } - ], - "symbolId": "lib/unmanaged-compute-environment:UnmanagedComputeEnvironmentProps" - } - }, - "version": "0.0.0", - "fingerprint": "oTncRAlRM55jMKT9Vxi1eKfuNXfCgiLRFVfCY18w+gM=" -} \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js b/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js deleted file mode 100644 index 204b2b9e6ead6..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/.warnings.jsii.js +++ /dev/null @@ -1,515 +0,0 @@ -function _aws_cdk_aws_batch_alpha_IComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_ComputeEnvironmentProps(p) { -} -function _aws_cdk_aws_batch_alpha_EcsJobDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.container)) - _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p.container); - if (p.retryStrategies != null) - for (const o of p.retryStrategies) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_RetryStrategy(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EcsJobDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_IEksJobDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_EksJobDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.container)) - _aws_cdk_aws_batch_alpha_EksContainerDefinition(p.container); - if (!visitedObjects.has(p.dnsPolicy)) - _aws_cdk_aws_batch_alpha_DnsPolicy(p.dnsPolicy); - if (p.retryStrategies != null) - for (const o of p.retryStrategies) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_RetryStrategy(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_DnsPolicy(p) { -} -function _aws_cdk_aws_batch_alpha_EksJobDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_SecretVersionInfo(p) { -} -function _aws_cdk_aws_batch_alpha_Secret(p) { -} -function _aws_cdk_aws_batch_alpha_EcsVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_EcsVolume(p) { -} -function _aws_cdk_aws_batch_alpha_EfsVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_EfsVolume(p) { -} -function _aws_cdk_aws_batch_alpha_HostVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_HostVolume(p) { -} -function _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_EcsContainerDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.linuxParameters)) - _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); - if (p.secrets != null) - for (const o of Object.values(p.secrets)) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_Secret(o); - if (p.volumes != null) - for (const o of p.volumes) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EcsVolume(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_Ulimit(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.name)) - _aws_cdk_aws_batch_alpha_UlimitName(p.name); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_UlimitName(p) { -} -function _aws_cdk_aws_batch_alpha_IEcsEc2ContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.ulimits != null) - for (const o of p.ulimits) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_Ulimit(o); - if (!visitedObjects.has(p.linuxParameters)) - _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); - if (p.secrets != null) - for (const o of Object.values(p.secrets)) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_Secret(o); - if (p.volumes != null) - for (const o of p.volumes) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EcsVolume(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_IEcsFargateContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.linuxParameters)) - _aws_cdk_aws_batch_alpha_LinuxParameters(p.linuxParameters); - if (p.secrets != null) - for (const o of Object.values(p.secrets)) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_Secret(o); - if (p.volumes != null) - for (const o of p.volumes) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EcsVolume(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_IEksContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_ImagePullPolicy(p) { -} -function _aws_cdk_aws_batch_alpha_EksContainerDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.imagePullPolicy)) - _aws_cdk_aws_batch_alpha_ImagePullPolicy(p.imagePullPolicy); - if (p.volumes != null) - for (const o of p.volumes) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EksVolume(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EksContainerDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_EksVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_EksVolume(p) { -} -function _aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.medium)) - _aws_cdk_aws_batch_alpha_EmptyDirMediumType(p.medium); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EmptyDirMediumType(p) { -} -function _aws_cdk_aws_batch_alpha_EmptyDirVolume(p) { -} -function _aws_cdk_aws_batch_alpha_HostPathVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_HostPathVolume(p) { -} -function _aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(p) { -} -function _aws_cdk_aws_batch_alpha_SecretPathVolume(p) { -} -function _aws_cdk_aws_batch_alpha_IJobDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_JobDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.retryStrategies != null) - for (const o of p.retryStrategies) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_RetryStrategy(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_RetryStrategy(p) { -} -function _aws_cdk_aws_batch_alpha_Action(p) { -} -function _aws_cdk_aws_batch_alpha_CustomReason(p) { -} -function _aws_cdk_aws_batch_alpha_Reason(p) { -} -function _aws_cdk_aws_batch_alpha_IJobQueue(p) { -} -function _aws_cdk_aws_batch_alpha_JobQueueProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.computeEnvironments != null) - for (const o of p.computeEnvironments) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment(o); - if (!visitedObjects.has(p.schedulingPolicy)) - _aws_cdk_aws_batch_alpha_ISchedulingPolicy(p.schedulingPolicy); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.computeEnvironment)) - _aws_cdk_aws_batch_alpha_IComputeEnvironment(p.computeEnvironment); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_JobQueue(p) { -} -function _aws_cdk_aws_batch_alpha_LinuxParametersProps(p) { -} -function _aws_cdk_aws_batch_alpha_LinuxParameters(p) { -} -function _aws_cdk_aws_batch_alpha_Device(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.permissions != null) - for (const o of p.permissions) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_DevicePermission(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_Tmpfs(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.mountOptions != null) - for (const o of p.mountOptions) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_TmpfsMountOption(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_DevicePermission(p) { -} -function _aws_cdk_aws_batch_alpha_TmpfsMountOption(p) { -} -function _aws_cdk_aws_batch_alpha_IManagedComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_ManagedComputeEnvironmentProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.securityGroups != null) - for (const o of p.securityGroups) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_IManagedEc2EcsComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_EcsMachineImage(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.imageType)) - _aws_cdk_aws_batch_alpha_EcsMachineImageType(p.imageType); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EksMachineImage(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.imageType)) - _aws_cdk_aws_batch_alpha_EksMachineImageType(p.imageType); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_EcsMachineImageType(p) { -} -function _aws_cdk_aws_batch_alpha_EksMachineImageType(p) { -} -function _aws_cdk_aws_batch_alpha_AllocationStrategy(p) { -} -function _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.allocationStrategy)) - _aws_cdk_aws_batch_alpha_AllocationStrategy(p.allocationStrategy); - if (p.images != null) - for (const o of p.images) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EcsMachineImage(o); - if (p.instanceClasses != null) - for (const o of p.instanceClasses) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceClass(o); - if (p.instanceTypes != null) - for (const o of p.instanceTypes) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceType(o); - if (p.securityGroups != null) - for (const o of p.securityGroups) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.allocationStrategy)) - _aws_cdk_aws_batch_alpha_AllocationStrategy(p.allocationStrategy); - if (p.images != null) - for (const o of p.images) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_EksMachineImage(o); - if (p.instanceClasses != null) - for (const o of p.instanceClasses) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceClass(o); - if (p.instanceTypes != null) - for (const o of p.instanceTypes) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_InstanceType(o); - if (p.securityGroups != null) - for (const o of p.securityGroups) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_IFargateComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.securityGroups != null) - for (const o of p.securityGroups) - if (!visitedObjects.has(o)) - require("aws-cdk-lib/.warnings.jsii.js").aws_cdk_lib_aws_ec2_ISecurityGroup(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_FargateComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_MultiNodeContainer(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (!visitedObjects.has(p.container)) - _aws_cdk_aws_batch_alpha_IEcsContainerDefinition(p.container); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.containers != null) - for (const o of p.containers) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_MultiNodeContainer(o); - if (p.retryStrategies != null) - for (const o of p.retryStrategies) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_RetryStrategy(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_MultiNodeJobDefinition(p) { -} -function _aws_cdk_aws_batch_alpha_ISchedulingPolicy(p) { -} -function _aws_cdk_aws_batch_alpha_Share(p) { -} -function _aws_cdk_aws_batch_alpha_IFairshareSchedulingPolicy(p) { -} -function _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps(p) { - if (p == null) - return; - visitedObjects.add(p); - try { - if (p.shares != null) - for (const o of p.shares) - if (!visitedObjects.has(o)) - _aws_cdk_aws_batch_alpha_Share(o); - } - finally { - visitedObjects.delete(p); - } -} -function _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicy(p) { -} -function _aws_cdk_aws_batch_alpha_IUnmanagedComputeEnvironment(p) { -} -function _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps(p) { -} -function _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironment(p) { -} -function print(name, deprecationMessage) { - const deprecated = process.env.JSII_DEPRECATED; - const deprecationMode = ["warn", "fail", "quiet"].includes(deprecated) ? deprecated : "warn"; - const message = `${name} is deprecated.\n ${deprecationMessage.trim()}\n This API will be removed in the next major release.`; - switch (deprecationMode) { - case "fail": - throw new DeprecationError(message); - case "warn": - console.warn("[WARNING]", message); - break; - } -} -function getPropertyDescriptor(obj, prop) { - const descriptor = Object.getOwnPropertyDescriptor(obj, prop); - if (descriptor) { - return descriptor; - } - const proto = Object.getPrototypeOf(obj); - const prototypeDescriptor = proto && getPropertyDescriptor(proto, prop); - if (prototypeDescriptor) { - return prototypeDescriptor; - } - return {}; -} -const visitedObjects = new Set(); -class DeprecationError extends Error { - constructor(...args) { - super(...args); - Object.defineProperty(this, "name", { - configurable: false, - enumerable: true, - value: "DeprecationError", - writable: false, - }); - } -} -module.exports = { print, getPropertyDescriptor, DeprecationError, _aws_cdk_aws_batch_alpha_IComputeEnvironment, _aws_cdk_aws_batch_alpha_ComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_EcsJobDefinitionProps, _aws_cdk_aws_batch_alpha_EcsJobDefinition, _aws_cdk_aws_batch_alpha_IEksJobDefinition, _aws_cdk_aws_batch_alpha_EksJobDefinitionProps, _aws_cdk_aws_batch_alpha_DnsPolicy, _aws_cdk_aws_batch_alpha_EksJobDefinition, _aws_cdk_aws_batch_alpha_SecretVersionInfo, _aws_cdk_aws_batch_alpha_Secret, _aws_cdk_aws_batch_alpha_EcsVolumeOptions, _aws_cdk_aws_batch_alpha_EcsVolume, _aws_cdk_aws_batch_alpha_EfsVolumeOptions, _aws_cdk_aws_batch_alpha_EfsVolume, _aws_cdk_aws_batch_alpha_HostVolumeOptions, _aws_cdk_aws_batch_alpha_HostVolume, _aws_cdk_aws_batch_alpha_IEcsContainerDefinition, _aws_cdk_aws_batch_alpha_EcsContainerDefinitionProps, _aws_cdk_aws_batch_alpha_Ulimit, _aws_cdk_aws_batch_alpha_UlimitName, _aws_cdk_aws_batch_alpha_IEcsEc2ContainerDefinition, _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinition, _aws_cdk_aws_batch_alpha_IEcsFargateContainerDefinition, _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EcsFargateContainerDefinition, _aws_cdk_aws_batch_alpha_IEksContainerDefinition, _aws_cdk_aws_batch_alpha_ImagePullPolicy, _aws_cdk_aws_batch_alpha_EksContainerDefinitionProps, _aws_cdk_aws_batch_alpha_EksContainerDefinition, _aws_cdk_aws_batch_alpha_EksVolumeOptions, _aws_cdk_aws_batch_alpha_EksVolume, _aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions, _aws_cdk_aws_batch_alpha_EmptyDirMediumType, _aws_cdk_aws_batch_alpha_EmptyDirVolume, _aws_cdk_aws_batch_alpha_HostPathVolumeOptions, _aws_cdk_aws_batch_alpha_HostPathVolume, _aws_cdk_aws_batch_alpha_SecretPathVolumeOptions, _aws_cdk_aws_batch_alpha_SecretPathVolume, _aws_cdk_aws_batch_alpha_IJobDefinition, _aws_cdk_aws_batch_alpha_JobDefinitionProps, _aws_cdk_aws_batch_alpha_RetryStrategy, _aws_cdk_aws_batch_alpha_Action, _aws_cdk_aws_batch_alpha_CustomReason, _aws_cdk_aws_batch_alpha_Reason, _aws_cdk_aws_batch_alpha_IJobQueue, _aws_cdk_aws_batch_alpha_JobQueueProps, _aws_cdk_aws_batch_alpha_OrderedComputeEnvironment, _aws_cdk_aws_batch_alpha_JobQueue, _aws_cdk_aws_batch_alpha_LinuxParametersProps, _aws_cdk_aws_batch_alpha_LinuxParameters, _aws_cdk_aws_batch_alpha_Device, _aws_cdk_aws_batch_alpha_Tmpfs, _aws_cdk_aws_batch_alpha_DevicePermission, _aws_cdk_aws_batch_alpha_TmpfsMountOption, _aws_cdk_aws_batch_alpha_IManagedComputeEnvironment, _aws_cdk_aws_batch_alpha_ManagedComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_IManagedEc2EcsComputeEnvironment, _aws_cdk_aws_batch_alpha_EcsMachineImage, _aws_cdk_aws_batch_alpha_EksMachineImage, _aws_cdk_aws_batch_alpha_EcsMachineImageType, _aws_cdk_aws_batch_alpha_EksMachineImageType, _aws_cdk_aws_batch_alpha_AllocationStrategy, _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironment, _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironment, _aws_cdk_aws_batch_alpha_IFargateComputeEnvironment, _aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_FargateComputeEnvironment, _aws_cdk_aws_batch_alpha_MultiNodeContainer, _aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps, _aws_cdk_aws_batch_alpha_MultiNodeJobDefinition, _aws_cdk_aws_batch_alpha_ISchedulingPolicy, _aws_cdk_aws_batch_alpha_Share, _aws_cdk_aws_batch_alpha_IFairshareSchedulingPolicy, _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps, _aws_cdk_aws_batch_alpha_FairshareSchedulingPolicy, _aws_cdk_aws_batch_alpha_IUnmanagedComputeEnvironment, _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps, _aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironment }; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts deleted file mode 100644 index 61426345d5a13..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.d.ts +++ /dev/null @@ -1,87 +0,0 @@ -import * as iam from 'aws-cdk-lib/aws-iam'; -import { IResource, Resource } from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -/** - * Represents a ComputeEnvironment - */ -export interface IComputeEnvironment extends IResource { - /** - * The name of the ComputeEnvironment - * - * @attribute - */ - readonly computeEnvironmentName: string; - /** - * The ARN of this compute environment. - * - * @attribute - */ - readonly computeEnvironmentArn: string; - /** - * The role Batch uses to perform actions on your behalf - * in your account, such as provision instances to run your jobs - * - * @default - a serviceRole will be created for managed CEs, none for unmanaged CEs - */ - readonly serviceRole?: iam.IRole; - /** - * Whether or not this ComputeEnvironment can accept jobs from a Queue. - * Enabled ComputeEnvironments can accept jobs from a Queue and - * can scale instances up or down. - * Disabled ComputeEnvironments cannot accept jobs from a Queue or - * scale instances up or down. - * - * If you change a ComputeEnvironment from enabled to disabled while it is executing jobs, - * Jobs in the `STARTED` or `RUNNING` states will not - * be interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`. - * - * To ensure you aren't billed for unused capacity, set `minvCpus` to `0`. - */ - readonly enabled: boolean; -} -/** - * Props common to all ComputeEnvironments - */ -export interface ComputeEnvironmentProps { - /** - * The name of the ComputeEnvironment - * - * @default - generated by CloudFormation - */ - readonly computeEnvironmentName?: string; - /** - * The role Batch uses to perform actions on your behalf - * in your account, such as provision instances to run your jobs - * - * @default - a serviceRole will be created for managed CEs, none for unmanaged CEs - */ - readonly serviceRole?: iam.IRole; - /** - * Whether or not this ComputeEnvironment can accept jobs from a Queue. - * Enabled ComputeEnvironments can accept jobs from a Queue and - * can scale instances up or down. - * Disabled ComputeEnvironments cannot accept jobs from a Queue or - * scale instances up or down. - * - * If you change a ComputeEnvironment from enabled to disabled while it is executing jobs, - * Jobs in the `STARTED` or `RUNNING` states will not - * be interrupted. As jobs complete, the ComputeEnvironment will scale instances down to `minvCpus`. - * - * To ensure you aren't billed for unused capacity, set `minvCpus` to `0`. - * - * @default true - */ - readonly enabled?: boolean; -} -/** - * Abstract base class for ComputeEnvironments - * - * @internal - */ -export declare abstract class ComputeEnvironmentBase extends Resource implements IComputeEnvironment { - abstract readonly computeEnvironmentName: string; - readonly serviceRole?: iam.IRole | undefined; - readonly enabled: boolean; - abstract readonly computeEnvironmentArn: string; - constructor(scope: Construct, id: string, props?: ComputeEnvironmentProps); -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js b/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js deleted file mode 100644 index 4af677e1944ac..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/compute-environment-base.js +++ /dev/null @@ -1,20 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.ComputeEnvironmentBase = void 0; -const core_1 = require("aws-cdk-lib/core"); -/** - * Abstract base class for ComputeEnvironments - * - * @internal - */ -class ComputeEnvironmentBase extends core_1.Resource { - constructor(scope, id, props) { - super(scope, id, { - physicalName: props?.computeEnvironmentName, - }); - this.serviceRole = props?.serviceRole; - this.enabled = props?.enabled ?? true; - } -} -exports.ComputeEnvironmentBase = ComputeEnvironmentBase; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tcHV0ZS1lbnZpcm9ubWVudC1iYXNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiY29tcHV0ZS1lbnZpcm9ubWVudC1iYXNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUNBLDJDQUF1RDtBQWtGdkQ7Ozs7R0FJRztBQUNILE1BQXNCLHNCQUF1QixTQUFR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RlZmluZWQ7XG4gIHB1YmxpYyByZWFkb25seSBlbmFibGVkOiBib29sZWFuO1xuICBwdWJsaWMgYWJzdHJhY3QgcmVhZG9ubHkgY29tcHV0ZUVudmlyb25tZW50QXJuOiBzdHJpbmc7XG5cbiAgY29uc3RydWN0b3Ioc2NvcGU6IENvbnN0cnVjdCwgaWQ6IHN0cmluZywgcHJvcHM/OiBDb21wdXRlRW52aXJvbm1lbnRQcm9wcykge1xuICAgIHN1cGVyKHNjb3BlLCBpZCwge1xuICAgICAgcGh5c2ljYWxOYW1lOiBwcm9wcz8uY29tcHV0ZUVudmlyb25tZW50TmFtZSxcbiAgICB9KTtcblxuICAgIHRoaXMuc2VydmljZVJvbGUgPSBwcm9wcz8uc2VydmljZVJvbGU7XG4gICAgdGhpcy5lbmFibGVkID0gcHJvcHM/LmVuYWJsZWQgPz8gdHJ1ZTtcbiAgfVxufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts deleted file mode 100644 index 4d545c302aeec..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.d.ts +++ /dev/null @@ -1,726 +0,0 @@ -import * as ecs from 'aws-cdk-lib/aws-ecs'; -import { IFileSystem } from 'aws-cdk-lib/aws-efs'; -import * as iam from 'aws-cdk-lib/aws-iam'; -import * as ssm from 'aws-cdk-lib/aws-ssm'; -import * as secretsmanager from 'aws-cdk-lib/aws-secretsmanager'; -import { Size } from 'aws-cdk-lib/core'; -import { Construct, IConstruct } from 'constructs'; -import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; -import { LinuxParameters } from './linux-parameters'; -/** - * Specify the secret's version id or version stage - */ -export interface SecretVersionInfo { - /** - * version id of the secret - * - * @default - use default version id - */ - readonly versionId?: string; - /** - * version stage of the secret - * - * @default - use default version stage - */ - readonly versionStage?: string; -} -/** - * A secret environment variable. - */ -export declare abstract class Secret { - /** - * Creates an environment variable value from a parameter stored in AWS - * Systems Manager Parameter Store. - */ - static fromSsmParameter(parameter: ssm.IParameter): Secret; - /** - * Creates a environment variable value from a secret stored in AWS Secrets - * Manager. - * - * @param secret the secret stored in AWS Secrets Manager - * @param field the name of the field with the value that you want to set as - * the environment variable value. Only values in JSON format are supported. - * If you do not specify a JSON field, then the full content of the secret is - * used. - */ - static fromSecretsManager(secret: secretsmanager.ISecret, field?: string): Secret; - /** - * Creates a environment variable value from a secret stored in AWS Secrets - * Manager. - * - * @param secret the secret stored in AWS Secrets Manager - * @param versionInfo the version information to reference the secret - * @param field the name of the field with the value that you want to set as - * the environment variable value. Only values in JSON format are supported. - * If you do not specify a JSON field, then the full content of the secret is - * used. - */ - static fromSecretsManagerVersion(secret: secretsmanager.ISecret, versionInfo: SecretVersionInfo, field?: string): Secret; - /** - * The ARN of the secret - */ - abstract readonly arn: string; - /** - * Whether this secret uses a specific JSON field - */ - abstract readonly hasField?: boolean; - /** - * Grants reading the secret to a principal - */ - abstract grantRead(grantee: iam.IGrantable): iam.Grant; -} -/** - * Options to configure an EcsVolume - */ -export interface EcsVolumeOptions { - /** - * the name of this volume - */ - readonly name: string; - /** - * the path on the container where this volume is mounted - */ - readonly containerPath: string; - /** - * if set, the container will have readonly access to the volume - * - * @default false - */ - readonly readonly?: boolean; -} -/** - * Represents a Volume that can be mounted to a container that uses ECS - */ -export declare abstract class EcsVolume { - /** - * Creates a Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html - */ - static efs(options: EfsVolumeOptions): EfsVolume; - /** - * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. - * If the `hostPath` is not specified, Docker will choose the host path. In this case, - * the data may not persist after the containers that use it stop running. - */ - static host(options: HostVolumeOptions): HostVolume; - /** - * The name of this volume - */ - readonly name: string; - /** - * The path on the container that this volume will be mounted to - */ - readonly containerPath: string; - /** - * Whether or not the container has readonly access to this volume - * - * @default false - */ - readonly readonly?: boolean; - constructor(options: EcsVolumeOptions); -} -/** - * Options for configuring an EfsVolume - */ -export interface EfsVolumeOptions extends EcsVolumeOptions { - /** - * The EFS File System that supports this volume - */ - readonly fileSystem: IFileSystem; - /** - * The directory within the Amazon EFS file system to mount as the root directory inside the host. - * If this parameter is omitted, the root of the Amazon EFS volume is used instead. - * Specifying `/` has the same effect as omitting this parameter. - * The maximum length is 4,096 characters. - * - * @default - root of the EFS File System - */ - readonly rootDirectory?: string; - /** - * Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server - * - * @see https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html - * - * @default false - */ - readonly enableTransitEncryption?: boolean; - /** - * The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server. - * The value must be between 0 and 65,535. - * - * @see https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html - * - * @default - chosen by the EFS Mount Helper - */ - readonly transitEncryptionPort?: number; - /** - * The Amazon EFS access point ID to use. - * If an access point is specified, `rootDirectory` must either be omitted or set to `/` - * which enforces the path set on the EFS access point. - * If an access point is used, `enableTransitEncryption` must be `true`. - * - * @see https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html - * - * @default - no accessPointId - */ - readonly accessPointId?: string; - /** - * Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system. - * If specified, `enableTransitEncryption` must be `true`. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints - * - * @default false - */ - readonly useJobRole?: boolean; -} -/** - * A Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed - */ -export declare class EfsVolume extends EcsVolume { - /** - * Returns true if x is an EfsVolume, false otherwise - */ - static isEfsVolume(x: any): x is EfsVolume; - /** - * The EFS File System that supports this volume - */ - readonly fileSystem: IFileSystem; - /** - * The directory within the Amazon EFS file system to mount as the root directory inside the host. - * If this parameter is omitted, the root of the Amazon EFS volume is used instead. - * Specifying `/` has the same effect as omitting this parameter. - * The maximum length is 4,096 characters. - * - * @default - root of the EFS File System - */ - readonly rootDirectory?: string; - /** - * Enables encryption for Amazon EFS data in transit between the Amazon ECS host and the Amazon EFS server - * - * @see https://docs.aws.amazon.com/efs/latest/ug/encryption-in-transit.html - * - * @default false - */ - readonly enableTransitEncryption?: boolean; - /** - * The port to use when sending encrypted data between the Amazon ECS host and the Amazon EFS server. - * The value must be between 0 and 65,535. - * - * @see https://docs.aws.amazon.com/efs/latest/ug/efs-mount-helper.html - * - * @default - chosen by the EFS Mount Helper - */ - readonly transitEncryptionPort?: number; - /** - * The Amazon EFS access point ID to use. - * If an access point is specified, `rootDirectory` must either be omitted or set to `/` - * which enforces the path set on the EFS access point. - * If an access point is used, `enableTransitEncryption` must be `true`. - * - * @see https://docs.aws.amazon.com/efs/latest/ug/efs-access-points.html - * - * @default - no accessPointId - */ - readonly accessPointId?: string; - /** - * Whether or not to use the AWS Batch job IAM role defined in a job definition when mounting the Amazon EFS file system. - * If specified, `enableTransitEncryption` must be `true`. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html#efs-volume-accesspoints - * - * @default false - */ - readonly useJobRole?: boolean; - constructor(options: EfsVolumeOptions); -} -/** - * Options for configuring an ECS HostVolume - */ -export interface HostVolumeOptions extends EcsVolumeOptions { - /** - * The path on the host machine this container will have access to - * - * @default - Docker will choose the host path. - * The data may not persist after the containers that use it stop running. - */ - readonly hostPath?: string; -} -/** - * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. - * If the `hostPath` is not specified, Docker will choose the host path. In this case, - * the data may not persist after the containers that use it stop running. - */ -export declare class HostVolume extends EcsVolume { - /** - * returns `true` if `x` is a `HostVolume`, `false` otherwise - */ - static isHostVolume(x: any): x is HostVolume; - /** - * The path on the host machine this container will have access to - */ - readonly hostPath?: string; - constructor(options: HostVolumeOptions); -} -/** - * A container that can be run with ECS orchestration - */ -export interface IEcsContainerDefinition extends IConstruct { - /** - * The image that this container will run - */ - readonly image: ecs.ContainerImage; - /** - * The number of vCPUs reserved for the container. - * Each vCPU is equivalent to 1,024 CPU shares. - * For containers running on EC2 resources, you must specify at least one vCPU. - */ - readonly cpu: number; - /** - * The memory hard limit present to the container. - * If your container attempts to exceed the memory specified, the container is terminated. - * You must specify at least 4 MiB of memory for a job. - */ - readonly memory: Size; - /** - * The command that's passed to the container - * - * @see https://docs.docker.com/engine/reference/builder/#cmd - */ - readonly command?: string[]; - /** - * The environment variables to pass to a container. - * Cannot start with `AWS_BATCH`. - * We don't recommend using plaintext environment variables for sensitive information, such as credential data. - * - * @default - no environment variables - */ - readonly environment?: { - [key: string]: string; - }; - /** - * The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html - */ - readonly executionRole: iam.IRole; - /** - * The role that the container can assume. - * - * @default - no jobRole - * - * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html - */ - readonly jobRole?: iam.IRole; - /** - * Linux-specific modifications that are applied to the container, such as details for device mappings. - * - * @default none - */ - readonly linuxParameters?: LinuxParameters; - /** - * The configuration of the log driver - */ - readonly logDriverConfig?: ecs.LogDriverConfig; - /** - * Gives the container readonly access to its root filesystem. - * - * @default false - */ - readonly readonlyRootFilesystem?: boolean; - /** - * A map from environment variable names to the secrets for the container. Allows your job definitions - * to reference the secret by the environment variable name defined in this property. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html - * - * @default - no secrets - */ - readonly secrets?: { - [envVarName: string]: Secret; - }; - /** - * The user name to use inside the container - * - * @default - no user - */ - readonly user?: string; - /** - * The volumes to mount to this container. Automatically added to the job definition. - * - * @default - no volumes - */ - readonly volumes: EcsVolume[]; - /** - * Renders this container to CloudFormation - * - * @internal - */ - _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; - /** - * Add a Volume to this container - */ - addVolume(volume: EcsVolume): void; -} -/** - * Props to configure an EcsContainerDefinition - */ -export interface EcsContainerDefinitionProps { - /** - * The image that this container will run - */ - readonly image: ecs.ContainerImage; - /** - * The number of vCPUs reserved for the container. - * Each vCPU is equivalent to 1,024 CPU shares. - * For containers running on EC2 resources, you must specify at least one vCPU. - */ - readonly cpu: number; - /** - * The memory hard limit present to the container. - * If your container attempts to exceed the memory specified, the container is terminated. - * You must specify at least 4 MiB of memory for a job. - */ - readonly memory: Size; - /** - * The command that's passed to the container - * - * @see https://docs.docker.com/engine/reference/builder/#cmd - * - * @default - no command - */ - readonly command?: string[]; - /** - * The environment variables to pass to a container. - * Cannot start with `AWS_BATCH`. - * We don't recommend using plaintext environment variables for sensitive information, such as credential data. - * - * @default - no environment variables - */ - readonly environment?: { - [key: string]: string; - }; - /** - * The role used by Amazon ECS container and AWS Fargate agents to make AWS API calls on your behalf. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/execution-IAM-role.html - * - * @default - a Role will be created - */ - readonly executionRole?: iam.IRole; - /** - * The role that the container can assume. - * - * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-iam-roles.html - * - * @default - no job role - */ - readonly jobRole?: iam.IRole; - /** - * Linux-specific modifications that are applied to the container, such as details for device mappings. - * - * @default none - */ - readonly linuxParameters?: LinuxParameters; - /** - * The loging configuration for this Job - * - * @default - the log configuration of the Docker daemon - */ - readonly logging?: ecs.LogDriver; - /** - * Gives the container readonly access to its root filesystem. - * - * @default false - */ - readonly readonlyRootFilesystem?: boolean; - /** - * A map from environment variable names to the secrets for the container. Allows your job definitions - * to reference the secret by the environment variable name defined in this property. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/specifying-sensitive-data.html - * - * @default - no secrets - */ - readonly secrets?: { - [envVarName: string]: Secret; - }; - /** - * The user name to use inside the container - * - * @default - no user - */ - readonly user?: string; - /** - * The volumes to mount to this container. Automatically added to the job definition. - * - * @default - no volumes - */ - readonly volumes?: EcsVolume[]; -} -/** - * Abstract base class for ECS Containers - */ -declare abstract class EcsContainerDefinitionBase extends Construct implements IEcsContainerDefinition { - readonly image: ecs.ContainerImage; - readonly cpu: number; - readonly memory: Size; - readonly command?: string[]; - readonly environment?: { - [key: string]: string; - }; - readonly executionRole: iam.IRole; - readonly jobRole?: iam.IRole; - readonly linuxParameters?: LinuxParameters; - readonly logDriverConfig?: ecs.LogDriverConfig; - readonly readonlyRootFilesystem?: boolean; - readonly secrets?: { - [envVarName: string]: Secret; - }; - readonly user?: string; - readonly volumes: EcsVolume[]; - private readonly imageConfig; - constructor(scope: Construct, id: string, props: EcsContainerDefinitionProps); - /** - * @internal - */ - _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; - addVolume(volume: EcsVolume): void; - /** - * @internal - */ - protected _renderResourceRequirements(): { - type: string; - value: string; - }[]; -} -/** - * Sets limits for a resource with `ulimit` on linux systems. - * Used by the Docker daemon. - */ -export interface Ulimit { - /** - * The hard limit for this resource. The container will - * be terminated if it exceeds this limit. - */ - readonly hardLimit: number; - /** - * The resource to limit - */ - readonly name: UlimitName; - /** - * The reservation for this resource. The container will - * not be terminated if it exceeds this limit. - */ - readonly softLimit: number; -} -/** - * The resources to be limited - */ -export declare enum UlimitName { - /** - * max core dump file size - */ - CORE = "core", - /** - * max cpu time (seconds) for a process - */ - CPU = "cpu", - /** - * max data segment size - */ - DATA = "data", - /** - * max file size - */ - FSIZE = "fsize", - /** - * max number of file locks - */ - LOCKS = "locks", - /** - * max locked memory - */ - MEMLOCK = "memlock", - /** - * max POSIX message queue size - */ - MSGQUEUE = "msgqueue", - /** - * max nice value for any process this user is running - */ - NICE = "nice", - /** - * maximum number of open file descriptors - */ - NOFILE = "nofile", - /** - * maximum number of processes - */ - NPROC = "nproc", - /** - * size of the process' resident set (in pages) - */ - RSS = "rss", - /** - * max realtime priority - */ - RTPRIO = "rtprio", - /** - * timeout for realtime tasks - */ - RTTIME = "rttime", - /** - * max number of pending signals - */ - SIGPENDING = "sigpending", - /** - * max stack size (in bytes) - */ - STACK = "stack" -} -/** - * A container orchestrated by ECS that uses EC2 resources - */ -export interface IEcsEc2ContainerDefinition extends IEcsContainerDefinition { - /** - * When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user). - * - * @default false - */ - readonly privileged?: boolean; - /** - * Limits to set for the user this docker container will run as - */ - readonly ulimits: Ulimit[]; - /** - * The number of physical GPUs to reserve for the container. - * Make sure that the number of GPUs reserved for all containers in a job doesn't exceed - * the number of available GPUs on the compute resource that the job is launched on. - * - * @default - no gpus - */ - readonly gpu?: number; - /** - * Add a ulimit to this container - */ - addUlimit(ulimit: Ulimit): void; -} -/** - * Props to configure an EcsEc2ContainerDefinition - */ -export interface EcsEc2ContainerDefinitionProps extends EcsContainerDefinitionProps { - /** - * When this parameter is true, the container is given elevated permissions on the host container instance (similar to the root user). - * - * @default false - */ - readonly privileged?: boolean; - /** - * Limits to set for the user this docker container will run as - * - * @default - no ulimits - */ - readonly ulimits?: Ulimit[]; - /** - * The number of physical GPUs to reserve for the container. - * Make sure that the number of GPUs reserved for all containers in a job doesn't exceed - * the number of available GPUs on the compute resource that the job is launched on. - * - * @default - no gpus - */ - readonly gpu?: number; -} -/** - * A container orchestrated by ECS that uses EC2 resources - */ -export declare class EcsEc2ContainerDefinition extends EcsContainerDefinitionBase implements IEcsEc2ContainerDefinition { - readonly privileged?: boolean; - readonly ulimits: Ulimit[]; - readonly gpu?: number; - constructor(scope: Construct, id: string, props: EcsEc2ContainerDefinitionProps); - /** - * @internal - */ - _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; - /** - * Add a ulimit to this container - */ - addUlimit(ulimit: Ulimit): void; - /** - * @internal - */ - protected _renderResourceRequirements(): { - type: string; - value: string; - }[]; -} -/** - * A container orchestrated by ECS that uses Fargate resources and is orchestrated by ECS - */ -export interface IEcsFargateContainerDefinition extends IEcsContainerDefinition { - /** - * Indicates whether the job has a public IP address. - * For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet - * (for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet. - * - * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html - * - * @default false - */ - readonly assignPublicIp?: boolean; - /** - * Which version of Fargate to use when running this container - * - * @default LATEST - */ - readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; - /** - * The size for ephemeral storage. - * - * @default - 20 GiB - */ - readonly ephemeralStorageSize?: Size; -} -/** - * Props to configure an EcsFargateContainerDefinition - */ -export interface EcsFargateContainerDefinitionProps extends EcsContainerDefinitionProps { - /** - * Indicates whether the job has a public IP address. - * For a job that's running on Fargate resources in a private subnet to send outbound traffic to the internet - * (for example, to pull container images), the private subnet requires a NAT gateway be attached to route requests to the internet. - * - * @see https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html - * - * @default false - */ - readonly assignPublicIp?: boolean; - /** - * Which version of Fargate to use when running this container - * - * @default LATEST - */ - readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; - /** - * The size for ephemeral storage. - * - * @default - 20 GiB - */ - readonly ephemeralStorageSize?: Size; -} -/** - * A container orchestrated by ECS that uses Fargate resources - */ -export declare class EcsFargateContainerDefinition extends EcsContainerDefinitionBase implements IEcsFargateContainerDefinition { - readonly fargatePlatformVersion?: ecs.FargatePlatformVersion; - readonly assignPublicIp?: boolean; - readonly ephemeralStorageSize?: Size; - constructor(scope: Construct, id: string, props: EcsFargateContainerDefinitionProps); - /** - * @internal - */ - _renderContainerDefinition(): CfnJobDefinition.ContainerPropertiesProperty; -} -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js deleted file mode 100644 index 1153535f13eac..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-container-definition.js +++ /dev/null @@ -1,531 +0,0 @@ -"use strict"; -var _a, _b, _c, _d, _e, _f; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.EcsFargateContainerDefinition = exports.EcsEc2ContainerDefinition = exports.UlimitName = exports.HostVolume = exports.EfsVolume = exports.EcsVolume = exports.Secret = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const iam = require("aws-cdk-lib/aws-iam"); -const core_1 = require("aws-cdk-lib/core"); -const constructs_1 = require("constructs"); -const aws_logs_1 = require("aws-cdk-lib/aws-logs"); -const EFS_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/container-definition.EfsVolume'); -const HOST_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/container-definition.HostVolume'); -/** - * A secret environment variable. - */ -class Secret { - /** - * Creates an environment variable value from a parameter stored in AWS - * Systems Manager Parameter Store. - */ - static fromSsmParameter(parameter) { - return { - arn: parameter.parameterArn, - grantRead: grantee => parameter.grantRead(grantee), - }; - } - /** - * Creates a environment variable value from a secret stored in AWS Secrets - * Manager. - * - * @param secret the secret stored in AWS Secrets Manager - * @param field the name of the field with the value that you want to set as - * the environment variable value. Only values in JSON format are supported. - * If you do not specify a JSON field, then the full content of the secret is - * used. - */ - static fromSecretsManager(secret, field) { - return { - arn: field ? `${secret.secretArn}:${field}::` : secret.secretArn, - hasField: !!field, - grantRead: grantee => secret.grantRead(grantee), - }; - } - /** - * Creates a environment variable value from a secret stored in AWS Secrets - * Manager. - * - * @param secret the secret stored in AWS Secrets Manager - * @param versionInfo the version information to reference the secret - * @param field the name of the field with the value that you want to set as - * the environment variable value. Only values in JSON format are supported. - * If you do not specify a JSON field, then the full content of the secret is - * used. - */ - static fromSecretsManagerVersion(secret, versionInfo, field) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretVersionInfo(versionInfo); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.fromSecretsManagerVersion); - } - throw error; - } - return { - arn: `${secret.secretArn}:${field ?? ''}:${versionInfo.versionStage ?? ''}:${versionInfo.versionId ?? ''}`, - hasField: !!field, - grantRead: grantee => secret.grantRead(grantee), - }; - } -} -exports.Secret = Secret; -_a = JSII_RTTI_SYMBOL_1; -Secret[_a] = { fqn: "@aws-cdk/aws-batch-alpha.Secret", version: "0.0.0" }; -/** - * Represents a Volume that can be mounted to a container that uses ECS - */ -class EcsVolume { - /** - * Creates a Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/efs-volumes.html - */ - static efs(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EfsVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.efs); - } - throw error; - } - return new EfsVolume(options); - } - /** - * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. - * If the `hostPath` is not specified, Docker will choose the host path. In this case, - * the data may not persist after the containers that use it stop running. - */ - static host(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.host); - } - throw error; - } - return new HostVolume(options); - } - constructor(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EcsVolume); - } - throw error; - } - this.name = options.name; - this.containerPath = options.containerPath; - this.readonly = options.readonly; - } -} -exports.EcsVolume = EcsVolume; -_b = JSII_RTTI_SYMBOL_1; -EcsVolume[_b] = { fqn: "@aws-cdk/aws-batch-alpha.EcsVolume", version: "0.0.0" }; -/** - * A Volume that uses an AWS Elastic File System (EFS); this volume can grow and shrink as needed - */ -class EfsVolume extends EcsVolume { - /** - * Returns true if x is an EfsVolume, false otherwise - */ - static isEfsVolume(x) { - return x !== null && typeof (x) === 'object' && EFS_VOLUME_SYMBOL in x; - } - constructor(options) { - super(options); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EfsVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EfsVolume); - } - throw error; - } - this.fileSystem = options.fileSystem; - this.rootDirectory = options.rootDirectory; - this.enableTransitEncryption = options.enableTransitEncryption; - this.transitEncryptionPort = options.transitEncryptionPort; - this.accessPointId = options.accessPointId; - this.useJobRole = options.useJobRole; - } -} -exports.EfsVolume = EfsVolume; -_c = JSII_RTTI_SYMBOL_1; -EfsVolume[_c] = { fqn: "@aws-cdk/aws-batch-alpha.EfsVolume", version: "0.0.0" }; -Object.defineProperty(EfsVolume.prototype, EFS_VOLUME_SYMBOL, { - value: true, - enumerable: false, - writable: false, -}); -/** - * Creates a Host volume. This volume will persist on the host at the specified `hostPath`. - * If the `hostPath` is not specified, Docker will choose the host path. In this case, - * the data may not persist after the containers that use it stop running. - */ -class HostVolume extends EcsVolume { - /** - * returns `true` if `x` is a `HostVolume`, `false` otherwise - */ - static isHostVolume(x) { - return x !== null && typeof (x) === 'object' && HOST_VOLUME_SYMBOL in x; - } - constructor(options) { - super(options); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, HostVolume); - } - throw error; - } - this.hostPath = options.hostPath; - } -} -exports.HostVolume = HostVolume; -_d = JSII_RTTI_SYMBOL_1; -HostVolume[_d] = { fqn: "@aws-cdk/aws-batch-alpha.HostVolume", version: "0.0.0" }; -Object.defineProperty(HostVolume.prototype, HOST_VOLUME_SYMBOL, { - value: true, - enumerable: false, - writable: false, -}); -/** - * Abstract base class for ECS Containers - */ -class EcsContainerDefinitionBase extends constructs_1.Construct { - constructor(scope, id, props) { - super(scope, id); - this.image = props.image; - this.cpu = props.cpu; - this.command = props.command; - this.environment = props.environment; - this.executionRole = props.executionRole ?? createExecutionRole(this, 'ExecutionRole', props.logging ? true : false); - this.jobRole = props.jobRole; - this.linuxParameters = props.linuxParameters; - this.memory = props.memory; - if (props.logging) { - this.logDriverConfig = props.logging.bind(this, { - ...this, - // TS! - taskDefinition: { - obtainExecutionRole: () => this.executionRole, - }, - }); - } - this.readonlyRootFilesystem = props.readonlyRootFilesystem ?? false; - this.secrets = props.secrets; - this.user = props.user; - this.volumes = props.volumes ?? []; - this.imageConfig = props.image.bind(this, { - ...this, - taskDefinition: { - obtainExecutionRole: () => this.executionRole, - }, - }); - } - /** - * @internal - */ - _renderContainerDefinition() { - return { - image: this.imageConfig.imageName, - command: this.command, - environment: Object.keys(this.environment ?? {}).map((envKey) => ({ - name: envKey, - value: (this.environment ?? {})[envKey], - })), - jobRoleArn: this.jobRole?.roleArn, - executionRoleArn: this.executionRole?.roleArn, - linuxParameters: this.linuxParameters && this.linuxParameters.renderLinuxParameters(), - logConfiguration: this.logDriverConfig, - readonlyRootFilesystem: this.readonlyRootFilesystem, - resourceRequirements: this._renderResourceRequirements(), - secrets: this.secrets ? Object.entries(this.secrets).map(([name, secret]) => { - secret.grantRead(this.executionRole); - return { - name, - valueFrom: secret.arn, - }; - }) : undefined, - mountPoints: core_1.Lazy.any({ - produce: () => { - if (this.volumes.length === 0) { - return undefined; - } - return this.volumes.map((volume) => { - return { - containerPath: volume.containerPath, - readOnly: volume.readonly, - sourceVolume: volume.name, - }; - }); - }, - }), - volumes: core_1.Lazy.any({ - produce: () => { - if (this.volumes.length === 0) { - return undefined; - } - return this.volumes.map((volume) => { - if (EfsVolume.isEfsVolume(volume)) { - return { - name: volume.name, - efsVolumeConfiguration: { - fileSystemId: volume.fileSystem.fileSystemId, - rootDirectory: volume.rootDirectory, - transitEncryption: volume.enableTransitEncryption ? 'ENABLED' : (volume.enableTransitEncryption === false ? 'DISABLED' : undefined), - transitEncryptionPort: volume.transitEncryptionPort, - authorizationConfig: volume.accessPointId || volume.useJobRole ? { - accessPointId: volume.accessPointId, - iam: volume.useJobRole ? 'ENABLED' : (volume.useJobRole === false ? 'DISABLED' : undefined), - } : undefined, - }, - }; - } - else if (HostVolume.isHostVolume(volume)) { - return { - name: volume.name, - host: { - sourcePath: volume.hostPath, - }, - }; - } - throw new Error('unsupported Volume encountered'); - }); - }, - }), - user: this.user, - }; - } - addVolume(volume) { - this.volumes.push(volume); - } - /** - * @internal - */ - _renderResourceRequirements() { - const resourceRequirements = []; - resourceRequirements.push({ - type: 'MEMORY', - value: this.memory.toMebibytes().toString(), - }); - resourceRequirements.push({ - type: 'VCPU', - value: this.cpu.toString(), - }); - return resourceRequirements; - } -} -/** - * The resources to be limited - */ -var UlimitName; -(function (UlimitName) { - /** - * max core dump file size - */ - UlimitName["CORE"] = "core"; - /** - * max cpu time (seconds) for a process - */ - UlimitName["CPU"] = "cpu"; - /** - * max data segment size - */ - UlimitName["DATA"] = "data"; - /** - * max file size - */ - UlimitName["FSIZE"] = "fsize"; - /** - * max number of file locks - */ - UlimitName["LOCKS"] = "locks"; - /** - * max locked memory - */ - UlimitName["MEMLOCK"] = "memlock"; - /** - * max POSIX message queue size - */ - UlimitName["MSGQUEUE"] = "msgqueue"; - /** - * max nice value for any process this user is running - */ - UlimitName["NICE"] = "nice"; - /** - * maximum number of open file descriptors - */ - UlimitName["NOFILE"] = "nofile"; - /** - * maximum number of processes - */ - UlimitName["NPROC"] = "nproc"; - /** - * size of the process' resident set (in pages) - */ - UlimitName["RSS"] = "rss"; - /** - * max realtime priority - */ - UlimitName["RTPRIO"] = "rtprio"; - /** - * timeout for realtime tasks - */ - UlimitName["RTTIME"] = "rttime"; - /** - * max number of pending signals - */ - UlimitName["SIGPENDING"] = "sigpending"; - /** - * max stack size (in bytes) - */ - UlimitName["STACK"] = "stack"; -})(UlimitName || (exports.UlimitName = UlimitName = {})); -/** - * A container orchestrated by ECS that uses EC2 resources - */ -class EcsEc2ContainerDefinition extends EcsContainerDefinitionBase { - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsEc2ContainerDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EcsEc2ContainerDefinition); - } - throw error; - } - this.privileged = props.privileged; - this.ulimits = props.ulimits ?? []; - this.gpu = props.gpu; - } - /** - * @internal - */ - _renderContainerDefinition() { - return { - ...super._renderContainerDefinition(), - ulimits: core_1.Lazy.any({ - produce: () => { - if (this.ulimits.length === 0) { - return undefined; - } - return this.ulimits.map((ulimit) => ({ - hardLimit: ulimit.hardLimit, - name: ulimit.name, - softLimit: ulimit.softLimit, - })); - }, - }), - privileged: this.privileged, - resourceRequirements: this._renderResourceRequirements(), - }; - } - ; - /** - * Add a ulimit to this container - */ - addUlimit(ulimit) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Ulimit(ulimit); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addUlimit); - } - throw error; - } - this.ulimits.push(ulimit); - } - /** - * @internal - */ - _renderResourceRequirements() { - const resourceRequirements = super._renderResourceRequirements(); - if (this.gpu) { - resourceRequirements.push({ - type: 'GPU', - value: this.gpu.toString(), - }); - } - return resourceRequirements; - } -} -exports.EcsEc2ContainerDefinition = EcsEc2ContainerDefinition; -_e = JSII_RTTI_SYMBOL_1; -EcsEc2ContainerDefinition[_e] = { fqn: "@aws-cdk/aws-batch-alpha.EcsEc2ContainerDefinition", version: "0.0.0" }; -/** - * A container orchestrated by ECS that uses Fargate resources - */ -class EcsFargateContainerDefinition extends EcsContainerDefinitionBase { - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsFargateContainerDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EcsFargateContainerDefinition); - } - throw error; - } - this.assignPublicIp = props.assignPublicIp; - this.fargatePlatformVersion = props.fargatePlatformVersion; - this.ephemeralStorageSize = props.ephemeralStorageSize; - // validates ephemeralStorageSize is within limits - if (props.ephemeralStorageSize) { - if (props.ephemeralStorageSize.toGibibytes() > 200) { - throw new Error(`ECS Fargate container '${id}' specifies 'ephemeralStorageSize' at ${props.ephemeralStorageSize.toGibibytes()} > 200 GB`); - } - else if (props.ephemeralStorageSize.toGibibytes() < 21) { - throw new Error(`ECS Fargate container '${id}' specifies 'ephemeralStorageSize' at ${props.ephemeralStorageSize.toGibibytes()} < 21 GB`); - } - } - } - /** - * @internal - */ - _renderContainerDefinition() { - return { - ...super._renderContainerDefinition(), - ephemeralStorage: this.ephemeralStorageSize ? { - sizeInGiB: this.ephemeralStorageSize?.toGibibytes(), - } : undefined, - fargatePlatformConfiguration: { - platformVersion: this.fargatePlatformVersion?.toString(), - }, - networkConfiguration: { - assignPublicIp: this.assignPublicIp ? 'ENABLED' : 'DISABLED', - }, - }; - } - ; -} -exports.EcsFargateContainerDefinition = EcsFargateContainerDefinition; -_f = JSII_RTTI_SYMBOL_1; -EcsFargateContainerDefinition[_f] = { fqn: "@aws-cdk/aws-batch-alpha.EcsFargateContainerDefinition", version: "0.0.0" }; -function createExecutionRole(scope, id, logging) { - const execRole = new iam.Role(scope, id, { - assumedBy: new iam.ServicePrincipal('ecs-tasks.amazonaws.com'), - // needed for cross-account access with TagParameterContainerImage - roleName: core_1.PhysicalName.GENERATE_IF_NEEDED, - }); - if (!logging) { - // all jobs will fail without this if they produce any output at all when no logging is specified - aws_logs_1.LogGroup.fromLogGroupName(scope, 'batchDefaultLogGroup', '/aws/batch/job').grantWrite(execRole); - } - return execRole; -} -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRzIl0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sXG4gICAgICByZXNvdXJjZVJlcXVpcmVtZW50czogdGhpcy5fcmVuZGVyUmVzb3VyY2VSZXF1aXJlbWVudHMoKSxcbiAgICAgIHNlY3JldHM6IHRoaXMuc2VjcmV0cyA/IE9iamVjdC5lbnRyaWVzKHRoaXMuc2VjcmV0cykubWFwKChbbmFtZSwgc2VjcmV0XSkgPT4ge1xuICAgICAgICBzZWNyZXQuZ3JhbnRSZWFkKHRoaXMuZXhlY3V0aW9uUm9sZSk7XG5cbiAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICBuYW1lLFxuICAgICAgICAgIHZhbHVlRnJvbTogc2VjcmV0LmFybixcbiAgICAgICAgfTtcbiAgICAgIH0pIDogdW5kZWZpbmVkLFxuICAgICAgbW91bnRQb2ludHM6IExhenkuYW55KHtcbiAgICAgICAgcHJvZHVjZTogKCkgPT4ge1xuICAgICAgICAgIGlmICh0aGlzLnZvbHVtZXMubGVuZ3RoID09PSAwKSB7XG4gICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gdGhpcy52b2x1bWVzLm1hcCgodm9sdW1lKSA9PiB7XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICBjb250YWluZXJQYXRoOiB2b2x1bWUuY29udGFpbmVyUGF0aCxcbiAgICAgICAgICAgICAgcmVhZE9ubHk6IHZvbHVtZS5yZWFkb25seSxcbiAgICAgICAgICAgICAgc291cmNlVm9sdW1lOiB2b2x1bWUubmFtZSxcbiAgICAgICAgICAgIH07XG4gICAgICAgICAgfSk7XG4gICAgICAgIH0sXG4gICAgICB9KSxcbiAgICAgIHZvbHVtZXM6IExhenkuYW55KHtcbiAgICAgICAgcHJvZHVjZTogKCkgPT4ge1xuICAgICAgICAgIGlmICh0aGlzLnZvbHVtZXMubGVuZ3RoID09PSAwKSB7XG4gICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkO1xuICAgICAgICAgIH1cblxuICAgIC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ldGVyQ29udGFpbmVySW1hZ2VcbiAgICByb2xlTmFtZTogUGh5c2ljYWxOYW1lLkdFTkVSQVRFX0lGX05FRURFRCxcbiAgfSk7XG5cbiAgaWYgKCFsb2dnaW5nKSB7XG4gICAgLy8gYWxsIGpvYnMgd2lsbCBmYWlsIHdpdGhvdXQgdGhpcyBpZiB0aGV5IHByb2R1Y2UgYW55IG91dHB1dCBhdCBhbGwgd2hlbiBubyBsb2dnaW5nIGlzIHNwZWNpZmllZFxuICAgIExvZ0dyb3VwLmZyb21Mb2dHcm91cE5hbWUoc2NvcGUsICdiYXRjaERlZmF1bHRMb2dHcm91cCcsICcvYXdzL2JhdGNoL2pvYicpLmdyYW50V3JpdGUoZXhlY1JvbGUpO1xuICB9XG5cbiAgcmV0dXJuIGV4ZWNSb2xlO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts deleted file mode 100644 index f387b11752d75..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.d.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { Construct } from 'constructs'; -import { IEcsContainerDefinition } from './ecs-container-definition'; -import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; -import * as iam from 'aws-cdk-lib/aws-iam'; -import { IJobQueue } from './job-queue'; -/** - * A JobDefinition that uses ECS orchestration - */ -interface IEcsJobDefinition extends IJobDefinition { - /** - * The container that this job will run - */ - readonly container: IEcsContainerDefinition; - /** - * Whether to propogate tags from the JobDefinition - * to the ECS task that Batch spawns - * - * @default false - */ - readonly propagateTags?: boolean; -} -/** - * @internal - */ -export declare enum Compatibility { - EC2 = "EC2", - FARGATE = "FARGATE" -} -/** - * Props for EcsJobDefinition - */ -export interface EcsJobDefinitionProps extends JobDefinitionProps { - /** - * The container that this job will run - */ - readonly container: IEcsContainerDefinition; - /** - * Whether to propogate tags from the JobDefinition - * to the ECS task that Batch spawns - * - * @default false - */ - readonly propagateTags?: boolean; -} -/** - * A JobDefinition that uses ECS orchestration - * - * @resource AWS::Batch::JobDefinition - */ -export declare class EcsJobDefinition extends JobDefinitionBase implements IEcsJobDefinition { - /** - * Import a JobDefinition by its arn. - */ - static fromJobDefinitionArn(scope: Construct, id: string, jobDefinitionArn: string): IJobDefinition; - private static getJobDefinitionName; - readonly container: IEcsContainerDefinition; - readonly propagateTags?: boolean; - readonly jobDefinitionArn: string; - readonly jobDefinitionName: string; - constructor(scope: Construct, id: string, props: EcsJobDefinitionProps); - /** - * Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue` - */ - grantSubmitJob(identity: iam.IGrantable, queue: IJobQueue): void; - private renderPlatformCapabilities; -} -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js deleted file mode 100644 index e10f4f02ae1a9..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/ecs-job-definition.js +++ /dev/null @@ -1,102 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.EcsJobDefinition = exports.Compatibility = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -const ecs_container_definition_1 = require("./ecs-container-definition"); -const job_definition_base_1 = require("./job-definition-base"); -const iam = require("aws-cdk-lib/aws-iam"); -/** - * @internal - */ -var Compatibility; -(function (Compatibility) { - Compatibility["EC2"] = "EC2"; - Compatibility["FARGATE"] = "FARGATE"; -})(Compatibility || (exports.Compatibility = Compatibility = {})); -/** - * A JobDefinition that uses ECS orchestration - * - * @resource AWS::Batch::JobDefinition - */ -class EcsJobDefinition extends job_definition_base_1.JobDefinitionBase { - /** - * Import a JobDefinition by its arn. - */ - static fromJobDefinitionArn(scope, id, jobDefinitionArn) { - class Import extends job_definition_base_1.JobDefinitionBase { - constructor() { - super(...arguments); - this.jobDefinitionArn = jobDefinitionArn; - this.jobDefinitionName = EcsJobDefinition.getJobDefinitionName(this, jobDefinitionArn); - this.enabled = true; - this.container = {}; - } - } - return new Import(scope, id); - } - static getJobDefinitionName(scope, jobDefinitionArn) { - const resourceName = core_1.Stack.of(scope).splitArn(jobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - return resourceName.split(':')[0]; - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EcsJobDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EcsJobDefinition); - } - throw error; - } - this.container = props.container; - this.propagateTags = props?.propagateTags; - const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { - ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), - type: 'container', - jobDefinitionName: props.jobDefinitionName, - containerProperties: this.container?._renderContainerDefinition(), - platformCapabilities: this.renderPlatformCapabilities(), - propagateTags: this.propagateTags, - }); - this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { - service: 'batch', - resource: 'job-definition', - resourceName: this.physicalName, - }); - this.jobDefinitionName = EcsJobDefinition.getJobDefinitionName(scope, this.jobDefinitionArn); - } - /** - * Grants the `batch:submitJob` permission to the identity on both this job definition and the `queue` - */ - grantSubmitJob(identity, queue) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_IJobQueue(queue); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.grantSubmitJob); - } - throw error; - } - iam.Grant.addToPrincipal({ - actions: ['batch:SubmitJob'], - grantee: identity, - resourceArns: [this.jobDefinitionArn, queue.jobQueueArn], - }); - } - renderPlatformCapabilities() { - if (this.container instanceof ecs_container_definition_1.EcsEc2ContainerDefinition) { - return [Compatibility.EC2]; - } - return [Compatibility.FARGATE]; - } -} -exports.EcsJobDefinition = EcsJobDefinition; -_a = JSII_RTTI_SYMBOL_1; -EcsJobDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.EcsJobDefinition", version: "0.0.0" }; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWNzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUFvRDtBQUVwRCxxREFBeUQ7QUFDekQseUVBQWdHO0FBQ2hHLCtEQUEySDtBQUMzSCwyQ0FBMkM7QUFxQjNDOztHQUVHO0FBQ0gsSUFBWSxhQUdYO0FBSEQsV0FBWSxhQUFhO0lBQ3ZCLDRCQUFXLENBQUE7SUFDWCxvQ0FBbUIsQ0FBQTtBQUNyQixDQUFDLEVBSFcsYUFBYSw2QkFBYixhQUFhLFFBR3hCO0FBb0JEOzs7O0dBSUc7QUFDSCxNQUFhLGdCQUFpQixTQUFRLHVDQUFpQjtJQUNyRDs7T0FFRztJQUNJLE1BQU0sQ0FBQyxvQkFBb0IsQ0FBQyxLQUFnQixFQUFFLEVBQVUsRUFBRSxnQkFBd0I7UUFDdkYsTUFBTSxNQUFPLFNBQVEsdUNBQWlCO1lBQXRDOztnQkFDa0IscUJBQWdCLEdBQUcsZ0JBQWdCLENBQUM7Z0JBQ3BDLHNCQUFpQixHQUFHLGdCQUFnQixDQUFDLG9CQUFvQixDQUFDLElBQUksRUFBRSxnQkFBZ0IsQ0FBQyxDQUFDO2dCQUNsRixZQUFPLEdBQUcsSUFBSSxDQUFDO2dCQUMvQixjQUFTLEdBQUcsRUFBUyxDQUFDO1lBQ3hCLENBQUM7U0FBQTtRQUVELE9BQU8sSUFBSSxNQUFNLENBQU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8gdGhlIGlkZW50aXR5IG9uIGJvdGggdGhpcyBqb2IgZGVmaW5pdGlvbiBhbmQgdGhlIGBxdWV1ZWBcbiAgKi9cbiAgcHVibGljIGdyYW50U3VibWl0Sm9iKGlkZW50aXR5OiBpYW0uSUdyYW50YWJsZSwgcXVldWU6IElKb2JRdWV1ZSkge1xuICAgIGlhbS5HcmFudC5hZGRUb1ByaW5jaXBhbCh7XG4gICAgICBhY3Rpb25zOiBbJ2JhdGNoOlN1Ym1pdEpvYiddLFxuICAgICAgZ3JhbnRlZTogaWRlbnRpdHksXG4gICAgICByZXNvdXJjZUFybnM6IFt0aGlzLmpvYkRlZmluaXRpb25Bcm4sIHF1ZXVlLmpvYlF1ZXVlQXJuXSxcbiAgICB9KTtcbiAgfVxuXG4gIHByaXZhdGUgcmVuZGVyUGxhdGZvcm1DYXBhYmlsaXRpZXMoKSB7XG4gICAgaWYgKHRoaXMuY29udGFpbmVyIGluc3RhbmNlb2YgRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbikge1xuICAgICAgcmV0dXJuIFtDb21wYXRpYmlsaXR5LkVDMl07XG4gICAgfVxuXG4gICAgcmV0dXJuIFtDb21wYXRpYmlsaXR5LkZBUkdBVEVdO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts deleted file mode 100644 index 4e12fa25a1851..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.d.ts +++ /dev/null @@ -1,728 +0,0 @@ -import * as ecs from 'aws-cdk-lib/aws-ecs'; -import { Size } from 'aws-cdk-lib/core'; -import { Construct, IConstruct } from 'constructs'; -import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; -/** - * A container that can be run with EKS orchestration on EC2 resources - */ -export interface IEksContainerDefinition extends IConstruct { - /** - * The image that this container will run - */ - readonly image: ecs.ContainerImage; - /** - * An array of arguments to the entrypoint. - * If this isn't specified, the CMD of the container image is used. - * This corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes. - * Environment variable references are expanded using the container's environment. - * If the referenced environment variable doesn't exist, the reference in the command isn't changed. - * For example, if the reference is to "$(NAME1)" and the NAME1 environment variable doesn't exist, - * the command string will remain "$(NAME1)." $$ is replaced with $, and the resulting string isn't expanded. - * or example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists. - * - * @see https://docs.docker.com/engine/reference/builder/#cmd - * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ - */ - readonly args?: string[]; - /** - * The entrypoint for the container. This isn't run within a shell. - * If this isn't specified, the `ENTRYPOINT` of the container image is used. - * Environment variable references are expanded using the container's environment. - * If the referenced environment variable doesn't exist, the reference in the command isn't changed. - * For example, if the reference is to `"$(NAME1)"` and the `NAME1` environment variable doesn't exist, - * the command string will remain `"$(NAME1)."` `$$` is replaced with `$` and the resulting string isn't expanded. - * For example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists. - - * The entrypoint can't be updated. - * - * @see https://docs.docker.com/engine/reference/builder/#entrypoint - * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ - * @see https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint - */ - readonly command?: string[]; - /** - * The environment variables to pass to this container. - * - * *Note*: Environment variables cannot start with "AWS_BATCH". - * This naming convention is reserved for variables that AWS Batch sets. - */ - readonly env?: { - [key: string]: string; - }; - /** - * The image pull policy for this container - * - * @see https://kubernetes.io/docs/concepts/containers/images/#updating-images - * - * @default - `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise - */ - readonly imagePullPolicy?: ImagePullPolicy; - /** - * The name of this container - * - * @default: `'Default'` - */ - readonly name?: string; - /** - * The amount (in MiB) of memory to present to the container. - * If your container attempts to exceed the allocated memory, it will be terminated. - * - * Must be larger that 4 MiB - * - * At least one of `memoryLimit` and `memoryReservation` is required - * - * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible - * for the specific instance type that you are using. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html - * - * @default - No memory limit - */ - readonly memoryLimit?: Size; - /** - * The soft limit (in MiB) of memory to reserve for the container. - * Your container will be given at least this much memory, but may consume more. - * - * Must be larger that 4 MiB - * - * When system memory is under heavy contention, Docker attempts to keep the - * container memory to this soft limit. However, your container can consume more - * memory when it needs to, up to either the hard limit specified with the memory - * parameter (if applicable), or all of the available memory on the container - * instance, whichever comes first. - * - * At least one of `memoryLimit` and `memoryReservation` is required. - * If both are specified, then `memoryLimit` must be equal to `memoryReservation` - * - * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible - * for the specific instance type that you are using. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html - * - * @default - No memory reserved - */ - readonly memoryReservation?: Size; - /** - * The hard limit of CPUs to present to this container. - * Must be an even multiple of 0.25 - * - * If your container attempts to exceed this limit, it will be terminated. - * - * At least one of `cpuReservation` and `cpuLimit` is required. - * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No CPU limit - */ - readonly cpuLimit?: number; - /** - * The soft limit of CPUs to reserve for the container - * Must be an even multiple of 0.25 - * - * The container will given at least this many CPUs, but may consume more. - * - * At least one of `cpuReservation` and `cpuLimit` is required. - * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No CPUs reserved - */ - readonly cpuReservation?: number; - /** - * The hard limit of GPUs to present to this container. - * - * If your container attempts to exceed this limit, it will be terminated. - * - * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No GPU limit - */ - readonly gpuLimit?: number; - /** - * The soft limit of CPUs to reserve for the container - * Must be an even multiple of 0.25 - * - * The container will given at least this many CPUs, but may consume more. - * - * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No GPUs reserved - */ - readonly gpuReservation?: number; - /** - * If specified, gives this container elevated permissions on the host container instance. - * The level of permissions are similar to the root user permissions. - * - * This parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems - * - * @default false - */ - readonly privileged?: boolean; - /** - * If specified, gives this container readonly access to its root file system. - * - * This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems - * - * @default false - */ - readonly readonlyRootFilesystem?: boolean; - /** - * If specified, the container is run as the specified group ID (`gid`). - * If this parameter isn't specified, the default is the group that's specified in the image metadata. - * This parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default none - */ - readonly runAsGroup?: number; - /** - * If specified, the container is run as a user with a `uid` other than 0. Otherwise, no such rule is enforced. - * This parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default - the container is *not* required to run as a non-root user - */ - readonly runAsRoot?: boolean; - /** - * If specified, this container is run as the specified user ID (`uid`). - * This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default - the user that is specified in the image metadata. - */ - readonly runAsUser?: number; - /** - * The Volumes to mount to this container. - * Automatically added to the Pod. - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/ - */ - readonly volumes: EksVolume[]; - /** - * Mount a Volume to this container. Automatically added to the Pod. - */ - addVolume(volume: EksVolume): void; -} -/** - * Determines when the image is pulled from the registry to launch a container - */ -export declare enum ImagePullPolicy { - /** - * Every time the kubelet launches a container, - * the kubelet queries the container image registry to resolve the name to an image digest. - * If the kubelet has a container image with that exact digest cached locally, - * the kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest, - * and uses that image to launch the container. - * - * @see https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier - */ - ALWAYS = "Always", - /** - * The image is pulled only if it is not already present locally - */ - IF_NOT_PRESENT = "IfNotPresent", - /** - * The kubelet does not try fetching the image. - * If the image is somehow already present locally, - * the kubelet attempts to start the container; otherwise, startup fails. - * See pre-pulled images for more details. - * - * @see https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images - */ - NEVER = "Never" -} -/** - * Props to configure an EksContainerDefinition - */ -export interface EksContainerDefinitionProps { - /** - * The image that this container will run - */ - readonly image: ecs.ContainerImage; - /** - * An array of arguments to the entrypoint. - * If this isn't specified, the CMD of the container image is used. - * This corresponds to the args member in the Entrypoint portion of the Pod in Kubernetes. - * Environment variable references are expanded using the container's environment. - * If the referenced environment variable doesn't exist, the reference in the command isn't changed. - * For example, if the reference is to "$(NAME1)" and the NAME1 environment variable doesn't exist, - * the command string will remain "$(NAME1)." $$ is replaced with $, and the resulting string isn't expanded. - * or example, $$(VAR_NAME) is passed as $(VAR_NAME) whether or not the VAR_NAME environment variable exists. - * - * @see https://docs.docker.com/engine/reference/builder/#cmd - * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ - * - * @default - no args - */ - readonly args?: string[]; - /** - * The entrypoint for the container. This isn't run within a shell. - * If this isn't specified, the `ENTRYPOINT` of the container image is used. - * Environment variable references are expanded using the container's environment. - * If the referenced environment variable doesn't exist, the reference in the command isn't changed. - * For example, if the reference is to `"$(NAME1)"` and the `NAME1` environment variable doesn't exist, - * the command string will remain `"$(NAME1)."` `$$` is replaced with `$` and the resulting string isn't expanded. - * For example, `$$(VAR_NAME)` will be passed as `$(VAR_NAME)` whether or not the `VAR_NAME` environment variable exists. - - * The entrypoint can't be updated. - * - * @see https://docs.docker.com/engine/reference/builder/#entrypoint - * @see https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/ - * @see https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#entrypoint - * - * @default - no command - */ - readonly command?: string[]; - /** - * The environment variables to pass to this container. - * - * *Note*: Environment variables cannot start with "AWS_BATCH". - * This naming convention is reserved for variables that AWS Batch sets. - * - * @default - no environment variables - */ - readonly env?: { - [key: string]: string; - }; - /** - * The image pull policy for this container - * - * @see https://kubernetes.io/docs/concepts/containers/images/#updating-images - * - * @default - `ALWAYS` if the `:latest` tag is specified, `IF_NOT_PRESENT` otherwise - */ - readonly imagePullPolicy?: ImagePullPolicy; - /** - * The name of this container - * - * @default: `'Default'` - */ - readonly name?: string; - /** - * The amount (in MiB) of memory to present to the container. - * If your container attempts to exceed the allocated memory, it will be terminated. - * - * Must be larger that 4 MiB - * - * At least one of `memoryLimit` and `memoryReservation` is required - * - * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible - * for the specific instance type that you are using. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html - * - * @default - No memory limit - */ - readonly memoryLimit?: Size; - /** - * The soft limit (in MiB) of memory to reserve for the container. - * Your container will be given at least this much memory, but may consume more. - * - * Must be larger that 4 MiB - * - * When system memory is under heavy contention, Docker attempts to keep the - * container memory to this soft limit. However, your container can consume more - * memory when it needs to, up to either the hard limit specified with the memory - * parameter (if applicable), or all of the available memory on the container - * instance, whichever comes first. - * - * At least one of `memoryLimit` and `memoryReservation` is required. - * If both are specified, then `memoryLimit` must be equal to `memoryReservation` - * - * *Note*: To maximize your resource utilization, provide your jobs with as much memory as possible - * for the specific instance type that you are using. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * @see https://docs.aws.amazon.com/batch/latest/userguide/memory-management.html - * - * @default - No memory reserved - */ - readonly memoryReservation?: Size; - /** - * The hard limit of CPUs to present to this container. - * Must be an even multiple of 0.25 - * - * If your container attempts to exceed this limit, it will be terminated. - * - * At least one of `cpuReservation` and `cpuLimit` is required. - * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No CPU limit - */ - readonly cpuLimit?: number; - /** - * The soft limit of CPUs to reserve for the container - * Must be an even multiple of 0.25 - * - * The container will given at least this many CPUs, but may consume more. - * - * At least one of `cpuReservation` and `cpuLimit` is required. - * If both are specified, then `cpuLimit` must be at least as large as `cpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No CPUs reserved - */ - readonly cpuReservation?: number; - /** - * The hard limit of GPUs to present to this container. - * - * If your container attempts to exceed this limit, it will be terminated. - * - * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No GPU limit - */ - readonly gpuLimit?: number; - /** - * The soft limit of CPUs to reserve for the container - * Must be an even multiple of 0.25 - * - * The container will given at least this many CPUs, but may consume more. - * - * If both `gpuReservation` and `gpuLimit` are specified, then `gpuLimit` must be equal to `gpuReservation`. - * - * @see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ - * - * @default - No GPUs reserved - */ - readonly gpuReservation?: number; - /** - * If specified, gives this container elevated permissions on the host container instance. - * The level of permissions are similar to the root user permissions. - * - * This parameter maps to `privileged` policy in the Privileged pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems - * - * @default false - */ - readonly privileged?: boolean; - /** - * If specified, gives this container readonly access to its root file system. - * - * This parameter maps to `ReadOnlyRootFilesystem` policy in the Volumes and file systems pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#volumes-and-file-systems - * - * @default false - */ - readonly readonlyRootFilesystem?: boolean; - /** - * If specified, the container is run as the specified group ID (`gid`). - * If this parameter isn't specified, the default is the group that's specified in the image metadata. - * This parameter maps to `RunAsGroup` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default none - */ - readonly runAsGroup?: number; - /** - * If specified, the container is run as a user with a `uid` other than 0. Otherwise, no such rule is enforced. - * This parameter maps to `RunAsUser` and `MustRunAsNonRoot` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default - the container is *not* required to run as a non-root user - */ - readonly runAsRoot?: boolean; - /** - * If specified, this container is run as the specified user ID (`uid`). - * This parameter maps to `RunAsUser` and `MustRunAs` policy in the Users and groups pod security policies in the Kubernetes documentation. - * - * *Note*: this is only compatible with Kubernetes < v1.25 - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#users-and-groups - * - * @default - the user that is specified in the image metadata. - */ - readonly runAsUser?: number; - /** - * The Volumes to mount to this container. - * Automatically added to the Pod. - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/ - * - * @default - no volumes - */ - readonly volumes?: EksVolume[]; -} -/** - * A container that can be run with EKS orchestration on EC2 resources - */ -export declare class EksContainerDefinition extends Construct implements IEksContainerDefinition { - readonly image: ecs.ContainerImage; - readonly args?: string[]; - readonly command?: string[]; - readonly env?: { - [key: string]: string; - }; - readonly imagePullPolicy?: ImagePullPolicy; - readonly name?: string; - readonly memoryLimit?: Size; - readonly memoryReservation?: Size; - readonly cpuLimit?: number; - readonly cpuReservation?: number; - readonly gpuLimit?: number; - readonly gpuReservation?: number; - readonly privileged?: boolean; - readonly readonlyRootFilesystem?: boolean; - readonly runAsGroup?: number; - readonly runAsRoot?: boolean; - readonly runAsUser?: number; - readonly volumes: EksVolume[]; - private readonly imageConfig; - constructor(scope: Construct, id: string, props: EksContainerDefinitionProps); - addVolume(volume: EksVolume): void; - /** - * - * @internal - */ - _renderContainerDefinition(): CfnJobDefinition.EksContainerProperty; -} -/** - * Options to configure an EksVolume - */ -export interface EksVolumeOptions { - /** - * The name of this volume. - * The name must be a valid DNS subdomain name. - * - * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names - */ - readonly name: string; - /** - * The path on the container where the volume is mounted. - * - * @default - the volume is not mounted - */ - readonly mountPath?: string; - /** - * If specified, the container has readonly access to the volume. - * Otherwise, the container has read/write access. - * - * @default false - */ - readonly readonly?: boolean; -} -/** - * A Volume that can be mounted to a container supported by EKS - */ -export declare abstract class EksVolume { - /** - * Creates a Kubernetes EmptyDir volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir - */ - static emptyDir(options: EmptyDirVolumeOptions): EmptyDirVolume; - /** - * Creates a Kubernetes HostPath volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ - static hostPath(options: HostPathVolumeOptions): HostPathVolume; - /** - * Creates a Kubernetes Secret volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret - */ - static secret(options: SecretPathVolumeOptions): SecretPathVolume; - /** - * The name of this volume. - * The name must be a valid DNS subdomain name. - * - * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names - */ - readonly name: string; - /** - * The path on the container where the container is mounted. - * - * @default - the container is not mounted - */ - readonly containerPath?: string; - /** - * If specified, the container has readonly access to the volume. - * Otherwise, the container has read/write access. - * - * @default false - */ - readonly readonly?: boolean; - constructor(options: EksVolumeOptions); -} -/** - * Options for a Kubernetes EmptyDir volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir - */ -export interface EmptyDirVolumeOptions extends EksVolumeOptions { - /** - * The storage type to use for this Volume. - * - * @default `EmptyDirMediumType.DISK` - */ - readonly medium?: EmptyDirMediumType; - /** - * The maximum size for this Volume - * - * @default - no size limit - */ - readonly sizeLimit?: Size; -} -/** - * What medium the volume will live in - */ -export declare enum EmptyDirMediumType { - /** - * Use the disk storage of the node. - * Items written here will survive node reboots. - */ - DISK = "", - /** - * Use the `tmpfs` volume that is backed by RAM of the node. - * Items written here will *not* survive node reboots. - */ - MEMORY = "Memory" -} -/** - * A Kubernetes EmptyDir volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir - */ -export declare class EmptyDirVolume extends EksVolume { - /** - * Returns `true` if `x` is an EmptyDirVolume, `false` otherwise - */ - static isEmptyDirVolume(x: any): x is EmptyDirVolume; - /** - * The storage type to use for this Volume. - * - * @default `EmptyDirMediumType.DISK` - */ - readonly medium?: EmptyDirMediumType; - /** - * The maximum size for this Volume - * - * @default - no size limit - */ - readonly sizeLimit?: Size; - constructor(options: EmptyDirVolumeOptions); -} -/** - * Options for a kubernetes HostPath volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ -export interface HostPathVolumeOptions extends EksVolumeOptions { - /** - * The path of the file or directory on the host to mount into containers on the pod. - * - * *Note*: HothPath Volumes present many security risks, and should be avoided when possible. - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ - readonly hostPath: string; -} -/** - * A Kubernetes HostPath volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ -export declare class HostPathVolume extends EksVolume { - /** - * returns `true` if `x` is a HostPathVolume, `false` otherwise - */ - static isHostPathVolume(x: any): x is HostPathVolume; - /** - * The path of the file or directory on the host to mount into containers on the pod. - * - * *Note*: HothPath Volumes present many security risks, and should be avoided when possible. - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ - readonly path: string; - constructor(options: HostPathVolumeOptions); -} -/** - * Options for a Kubernetes SecretPath Volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret - */ -export interface SecretPathVolumeOptions extends EksVolumeOptions { - /** - * The name of the secret. - * Must be a valid DNS subdomain name. - * - * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names - */ - readonly secretName: string; - /** - * Specifies whether the secret or the secret's keys must be defined - * - * @default true - */ - readonly optional?: boolean; -} -/** - * Specifies the configuration of a Kubernetes secret volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret - */ -export declare class SecretPathVolume extends EksVolume { - /** - * returns `true` if `x` is a `SecretPathVolume` and `false` otherwise - */ - static isSecretPathVolume(x: any): x is SecretPathVolume; - /** - * The name of the secret. - * Must be a valid DNS subdomain name. - * - * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#dns-subdomain-names - */ - readonly secretName: string; - /** - * Specifies whether the secret or the secret's keys must be defined - * - * @default true - */ - readonly optional?: boolean; - constructor(options: SecretPathVolumeOptions); -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js deleted file mode 100644 index bd9b7beec7a4d..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/eks-container-definition.js +++ /dev/null @@ -1,338 +0,0 @@ -"use strict"; -var _a, _b, _c, _d, _e; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.SecretPathVolume = exports.HostPathVolume = exports.EmptyDirVolume = exports.EmptyDirMediumType = exports.EksVolume = exports.EksContainerDefinition = exports.ImagePullPolicy = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const constructs_1 = require("constructs"); -const EMPTY_DIR_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.EmptyDirVolume'); -const HOST_PATH_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.HostPathVolume'); -const SECRET_PATH_VOLUME_SYMBOL = Symbol.for('aws-cdk-lib/aws-batch/lib/eks-container-definition.SecretVolume'); -/** - * Determines when the image is pulled from the registry to launch a container - */ -var ImagePullPolicy; -(function (ImagePullPolicy) { - /** - * Every time the kubelet launches a container, - * the kubelet queries the container image registry to resolve the name to an image digest. - * If the kubelet has a container image with that exact digest cached locally, - * the kubelet uses its cached image; otherwise, the kubelet pulls the image with the resolved digest, - * and uses that image to launch the container. - * - * @see https://docs.docker.com/engine/reference/commandline/pull/#pull-an-image-by-digest-immutable-identifier - */ - ImagePullPolicy["ALWAYS"] = "Always"; - /** - * The image is pulled only if it is not already present locally - */ - ImagePullPolicy["IF_NOT_PRESENT"] = "IfNotPresent"; - /** - * The kubelet does not try fetching the image. - * If the image is somehow already present locally, - * the kubelet attempts to start the container; otherwise, startup fails. - * See pre-pulled images for more details. - * - * @see https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images - */ - ImagePullPolicy["NEVER"] = "Never"; -})(ImagePullPolicy || (exports.ImagePullPolicy = ImagePullPolicy = {})); -/** - * A container that can be run with EKS orchestration on EC2 resources - */ -class EksContainerDefinition extends constructs_1.Construct { - constructor(scope, id, props) { - super(scope, id); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksContainerDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EksContainerDefinition); - } - throw error; - } - this.image = props.image; - this.args = props.args; - this.command = props.command; - this.env = props.env; - this.imagePullPolicy = props.imagePullPolicy; - this.name = props.name; - this.memoryLimit = props.memoryLimit; - this.memoryReservation = props.memoryReservation; - this.cpuLimit = props.cpuLimit; - this.cpuReservation = props.cpuReservation; - this.gpuLimit = props.gpuLimit; - this.gpuReservation = props.gpuReservation; - this.privileged = props.privileged; - this.readonlyRootFilesystem = props.readonlyRootFilesystem; - this.runAsGroup = props.runAsGroup; - this.runAsRoot = props.runAsRoot; - this.runAsUser = props.runAsUser; - this.volumes = props.volumes ?? []; - this.imageConfig = props.image.bind(this, this); - } - addVolume(volume) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksVolume(volume); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addVolume); - } - throw error; - } - this.volumes.push(volume); - } - /** - * - * @internal - */ - _renderContainerDefinition() { - return { - image: this.imageConfig.imageName, - command: this.command, - args: this.args, - env: Object.keys(this.env ?? {}).map((key) => { - return { - name: key, - value: this.env[key], - }; - }), - name: this.name, - imagePullPolicy: this.imagePullPolicy, - resources: { - limits: { - 'cpu': this.cpuLimit, - 'memory': this.memoryLimit ? this.memoryLimit.toMebibytes() + 'Mi' : undefined, - 'nvidia.com/gpu': this.gpuLimit, - }, - requests: { - 'cpu': this.cpuReservation, - 'memory': this.memoryReservation ? this.memoryReservation.toMebibytes() + 'Mi' : undefined, - 'nvidia.com/gpu': this.gpuReservation, - }, - }, - securityContext: { - privileged: this.privileged, - readOnlyRootFilesystem: this.readonlyRootFilesystem, - runAsGroup: this.runAsGroup, - runAsNonRoot: !this.runAsRoot, - runAsUser: this.runAsUser, - }, - volumeMounts: core_1.Lazy.any({ - produce: () => { - if (this.volumes.length === 0) { - return undefined; - } - return this.volumes.map((volume) => { - return { - name: volume.name, - mountPath: volume.containerPath, - readOnly: volume.readonly, - }; - }); - }, - }), - }; - } - ; -} -exports.EksContainerDefinition = EksContainerDefinition; -_a = JSII_RTTI_SYMBOL_1; -EksContainerDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.EksContainerDefinition", version: "0.0.0" }; -/** - * A Volume that can be mounted to a container supported by EKS - */ -class EksVolume { - /** - * Creates a Kubernetes EmptyDir volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir - */ - static emptyDir(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.emptyDir); - } - throw error; - } - return new EmptyDirVolume(options); - } - /** - * Creates a Kubernetes HostPath volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ - static hostPath(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostPathVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.hostPath); - } - throw error; - } - return new HostPathVolume(options); - } - /** - * Creates a Kubernetes Secret volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret - */ - static secret(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.secret); - } - throw error; - } - return new SecretPathVolume(options); - } - constructor(options) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EksVolume); - } - throw error; - } - this.name = options.name; - this.containerPath = options.mountPath; - this.readonly = options.readonly; - } -} -exports.EksVolume = EksVolume; -_b = JSII_RTTI_SYMBOL_1; -EksVolume[_b] = { fqn: "@aws-cdk/aws-batch-alpha.EksVolume", version: "0.0.0" }; -/** - * What medium the volume will live in - */ -var EmptyDirMediumType; -(function (EmptyDirMediumType) { - /** - * Use the disk storage of the node. - * Items written here will survive node reboots. - */ - EmptyDirMediumType["DISK"] = ""; - /** - * Use the `tmpfs` volume that is backed by RAM of the node. - * Items written here will *not* survive node reboots. - */ - EmptyDirMediumType["MEMORY"] = "Memory"; -})(EmptyDirMediumType || (exports.EmptyDirMediumType = EmptyDirMediumType = {})); -/** - * A Kubernetes EmptyDir volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#emptydir - */ -class EmptyDirVolume extends EksVolume { - /** - * Returns `true` if `x` is an EmptyDirVolume, `false` otherwise - */ - static isEmptyDirVolume(x) { - return x !== null && typeof (x) === 'object' && EMPTY_DIR_VOLUME_SYMBOL in x; - } - constructor(options) { - super(options); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EmptyDirVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EmptyDirVolume); - } - throw error; - } - this.medium = options.medium; - this.sizeLimit = options.sizeLimit; - } -} -exports.EmptyDirVolume = EmptyDirVolume; -_c = JSII_RTTI_SYMBOL_1; -EmptyDirVolume[_c] = { fqn: "@aws-cdk/aws-batch-alpha.EmptyDirVolume", version: "0.0.0" }; -Object.defineProperty(EmptyDirVolume.prototype, EMPTY_DIR_VOLUME_SYMBOL, { - value: true, - enumerable: false, - writable: false, -}); -/** - * A Kubernetes HostPath volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#hostpath - */ -class HostPathVolume extends EksVolume { - /** - * returns `true` if `x` is a HostPathVolume, `false` otherwise - */ - static isHostPathVolume(x) { - return x !== null && typeof (x) === 'object' && HOST_PATH_VOLUME_SYMBOL in x; - } - constructor(options) { - super(options); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_HostPathVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, HostPathVolume); - } - throw error; - } - this.path = options.hostPath; - } -} -exports.HostPathVolume = HostPathVolume; -_d = JSII_RTTI_SYMBOL_1; -HostPathVolume[_d] = { fqn: "@aws-cdk/aws-batch-alpha.HostPathVolume", version: "0.0.0" }; -Object.defineProperty(HostPathVolume.prototype, HOST_PATH_VOLUME_SYMBOL, { - value: true, - enumerable: false, - writable: false, -}); -/** - * Specifies the configuration of a Kubernetes secret volume - * - * @see https://kubernetes.io/docs/concepts/storage/volumes/#secret - */ -class SecretPathVolume extends EksVolume { - /** - * returns `true` if `x` is a `SecretPathVolume` and `false` otherwise - */ - static isSecretPathVolume(x) { - return x !== null && typeof (x) === 'object' && SECRET_PATH_VOLUME_SYMBOL in x; - } - constructor(options) { - super(options); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_SecretPathVolumeOptions(options); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, SecretPathVolume); - } - throw error; - } - this.secretName = options.secretName; - this.optional = options.optional ?? true; - } -} -exports.SecretPathVolume = SecretPathVolume; -_e = JSII_RTTI_SYMBOL_1; -SecretPathVolume[_e] = { fqn: "@aws-cdk/aws-batch-alpha.SecretPathVolume", version: "0.0.0" }; -Object.defineProperty(SecretPathVolume.prototype, SECRET_PATH_VOLUME_SYMBOL, { - value: true, - enumerable: false, - writable: false, -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUNBLDJDQUE4QztBQUM5QywyQ0FBbUQ7QUFHbkQsTUFBTSx1QkFBdUIsR0FBRyxNQUFNLENBQUMsR0FBRyxD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nVlO1xuICB9XG59XG5cbk9iamVjdC5kZWZpbmVQcm9wZXJ0eShTZWNyZXRQYXRoVm9sdW1lLnByb3RvdHlwZSwgU0VDUkVUX1BBVEhfVk9MVU1FX1NZTUJPTCwge1xuICB2YWx1ZTogdHJ1ZSxcbiAgZW51bWVyYWJsZTogZmFsc2UsXG4gIHdyaXRhYmxlOiBmYWxzZSxcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts deleted file mode 100644 index 02e0bf442017d..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.d.ts +++ /dev/null @@ -1,123 +0,0 @@ -import { Construct } from 'constructs'; -import { EksContainerDefinition } from './eks-container-definition'; -import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; -/** - * A JobDefinition that uses Eks orchestration - */ -export interface IEksJobDefinition extends IJobDefinition { - /** - * The container this Job Definition will run - */ - readonly container: EksContainerDefinition; - /** - * The DNS Policy of the pod used by this Job Definition - * - * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy - * - * @default `DnsPolicy.CLUSTER_FIRST` - */ - readonly dnsPolicy?: DnsPolicy; - /** - * If specified, the Pod used by this Job Definition will use the host's network IP address. - * Otherwise, the Kubernetes pod networking model is enabled. - * Most AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections. - * - * @default true - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#host-namespaces - * @see https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking - */ - readonly useHostNetwork?: boolean; - /** - * The name of the service account that's used to run the container. - * service accounts are Kubernetes method of identification and authentication, - * roughly analogous to IAM users. - * - * @see https://docs.aws.amazon.com/eks/latest/userguide/service-accounts.html - * @see https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - * @see https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html - * - * @default - the default service account of the container - */ - readonly serviceAccount?: string; -} -/** - * Props for EksJobDefinition - */ -export interface EksJobDefinitionProps extends JobDefinitionProps { - /** - * The container this Job Definition will run - */ - readonly container: EksContainerDefinition; - /** - * The DNS Policy of the pod used by this Job Definition - * - * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy - * - * @default `DnsPolicy.CLUSTER_FIRST` - */ - readonly dnsPolicy?: DnsPolicy; - /** - * If specified, the Pod used by this Job Definition will use the host's network IP address. - * Otherwise, the Kubernetes pod networking model is enabled. - * Most AWS Batch workloads are egress-only and don't require the overhead of IP allocation for each pod for incoming connections. - * - * @default true - * - * @see https://kubernetes.io/docs/concepts/security/pod-security-policy/#host-namespaces - * @see https://kubernetes.io/docs/concepts/workloads/pods/#pod-networking - */ - readonly useHostNetwork?: boolean; - /** - * The name of the service account that's used to run the container. - * service accounts are Kubernetes method of identification and authentication, - * roughly analogous to IAM users. - * - * @see https://docs.aws.amazon.com/eks/latest/userguide/service-accounts.html - * @see https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ - * @see https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html - * - * @default - the default service account of the container - */ - readonly serviceAccount?: string; -} -/** - * The DNS Policy for the pod used by the Job Definition - * - * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy - */ -export declare enum DnsPolicy { - /** - * The Pod inherits the name resolution configuration from the node that the Pods run on - */ - DEFAULT = "Default", - /** - * Any DNS query that does not match the configured cluster domain suffix, such as `"www.kubernetes.io"`, - * is forwarded to an upstream nameserver by the DNS server. - * Cluster administrators may have extra stub-domain and upstream DNS servers configured. - */ - CLUSTER_FIRST = "ClusterFirst", - /** - * For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`. - * Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy. - */ - CLUSTER_FIRST_WITH_HOST_NET = "ClusterFirstWithHostNet" -} -/** - * A JobDefinition that uses Eks orchestration - * - * @resource AWS::Batch::JobDefinition - */ -export declare class EksJobDefinition extends JobDefinitionBase implements IEksJobDefinition { - /** - * Import an EksJobDefinition by its arn - */ - static fromEksJobDefinitionArn(scope: Construct, id: string, eksJobDefinitionArn: string): IEksJobDefinition; - readonly container: EksContainerDefinition; - readonly dnsPolicy?: DnsPolicy; - readonly useHostNetwork?: boolean; - readonly serviceAccount?: string; - readonly jobDefinitionArn: string; - readonly jobDefinitionName: string; - constructor(scope: Construct, id: string, props: EksJobDefinitionProps); -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js deleted file mode 100644 index cb23b62ee18c9..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/eks-job-definition.js +++ /dev/null @@ -1,134 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.EksJobDefinition = exports.DnsPolicy = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -const eks_container_definition_1 = require("./eks-container-definition"); -const job_definition_base_1 = require("./job-definition-base"); -/** - * The DNS Policy for the pod used by the Job Definition - * - * @see https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy - */ -var DnsPolicy; -(function (DnsPolicy) { - /** - * The Pod inherits the name resolution configuration from the node that the Pods run on - */ - DnsPolicy["DEFAULT"] = "Default"; - /** - * Any DNS query that does not match the configured cluster domain suffix, such as `"www.kubernetes.io"`, - * is forwarded to an upstream nameserver by the DNS server. - * Cluster administrators may have extra stub-domain and upstream DNS servers configured. - */ - DnsPolicy["CLUSTER_FIRST"] = "ClusterFirst"; - /** - * For Pods running with `hostNetwork`, you should explicitly set its DNS policy to `CLUSTER_FIRST_WITH_HOST_NET`. - * Otherwise, Pods running with `hostNetwork` and `CLUSTER_FIRST` will fallback to the behavior of the `DEFAULT` policy. - */ - DnsPolicy["CLUSTER_FIRST_WITH_HOST_NET"] = "ClusterFirstWithHostNet"; -})(DnsPolicy || (exports.DnsPolicy = DnsPolicy = {})); -/** - * A JobDefinition that uses Eks orchestration - * - * @resource AWS::Batch::JobDefinition - */ -class EksJobDefinition extends job_definition_base_1.JobDefinitionBase { - /** - * Import an EksJobDefinition by its arn - */ - static fromEksJobDefinitionArn(scope, id, eksJobDefinitionArn) { - const stack = core_1.Stack.of(scope); - const jobDefinitionName = stack.splitArn(eksJobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - class Import extends job_definition_base_1.JobDefinitionBase { - constructor() { - super(...arguments); - this.jobDefinitionArn = eksJobDefinitionArn; - this.jobDefinitionName = jobDefinitionName; - this.enabled = true; - this.container = {}; - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_EksJobDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, EksJobDefinition); - } - throw error; - } - this.container = props.container; - this.dnsPolicy = props.dnsPolicy; - this.useHostNetwork = props.useHostNetwork; - this.serviceAccount = props.serviceAccount; - const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { - ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), - type: 'container', - jobDefinitionName: props.jobDefinitionName, - eksProperties: { - podProperties: { - containers: [ - this.container._renderContainerDefinition(), - ], - dnsPolicy: this.dnsPolicy, - hostNetwork: this.useHostNetwork, - serviceAccountName: this.serviceAccount, - volumes: core_1.Lazy.any({ - produce: () => { - if (this.container.volumes.length === 0) { - return undefined; - } - return this.container.volumes.map((volume) => { - if (eks_container_definition_1.EmptyDirVolume.isEmptyDirVolume(volume)) { - return { - name: volume.name, - emptyDir: { - medium: volume.medium, - sizeLimit: volume.sizeLimit ? volume.sizeLimit.toMebibytes().toString() + 'Mi' : undefined, - }, - }; - } - if (eks_container_definition_1.HostPathVolume.isHostPathVolume(volume)) { - return { - name: volume.name, - hostPath: { - path: volume.path, - }, - }; - } - if (eks_container_definition_1.SecretPathVolume.isSecretPathVolume(volume)) { - return { - name: volume.name, - secret: { - optional: volume.optional, - secretName: volume.secretName, - }, - }; - } - throw new Error('unknown volume type'); - }); - }, - }), - }, - }, - }); - this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { - service: 'batch', - resource: 'job-definition', - resourceName: this.physicalName, - }); - this.jobDefinitionName = this.getResourceNameAttribute(resource.ref); - } -} -exports.EksJobDefinition = EksJobDefinition; -_a = JSII_RTTI_SYMBOL_1; -EksJobDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.EksJobDefinition", version: "0.0.0" }; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZWtzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUEwRDtBQUUxRCxxREFBeUQ7QUFDekQseUVBQXNIO0FBQ3RILCtEQUEySDtBQTBGM0g7Ozs7R0FJRztBQUNILElBQVksU0FrQlg7QUFsQkQsV0FBWSxTQUFTO0lBQ25COztPQUVHO0lBQ0gsZ0NBQW1CLENBQUE7SUFFbkI7Ozs7T0FJRztJQUNILDJDQUE4QixDQUFBO0lBRTlCOzs7T0FHRztJQUNILG9FQUF1RCxDQUFBO0FBQ3pELENBQUMsRUFsQlcsU0FBUyx5QkFBVCxTQUFTLFFBa0JwQjtBQUVEOzs7O0dBSUc7QUFDSCxNQUFhLGdCQUFpQixTQUFRLHVDQUFpQjtJQUNyRDs7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FxuICAgICAgICAgIHNlcnZpY2VBY2NvdW50TmFtZTogdGhpcy5zZXJ2aWNlQWNjb3VudCxcbiAgICAgICAgICB2b2x1bWVzOiBMYXp5LmFueSh7XG4gICAgICAgICAgICBwcm9kdWNlOiAoKSA9PiB7XG4gICAgICAgICAgICAgIGlmICh0aGlzLmNvbnRhaW5lci52b2x1bWVzLmxlbmd0aCA9PT0gMCkge1xuICAgICAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuY29udGFpbmVyLnZvbHVtZXMubWFwKCh2b2x1bWUpID0+IHtcbiAgICAgICAgICAgICAgICBpZiAoRW1wdHlEaXJWb2x1bWUuaXNFbXB0eURpclZvbHVtZSh2b2x1bWUpKSB7XG4gICAgICAgICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICAgICAgICBuYW1lOiB2b2x1bWUubmFtZSxcbiAgICAgICAgICAgICAgICAgICAgZW1wdHlEaXI6IHtcbiAgICAgICAgICAgICAgICAgICAgICBtZWRpdW06IHZvbHVtZS5tZWRpdW0sXG4gICAgICAgICAgICAgICAgICAgICAgc2l6ZUxpbWl0OiB2b2x1bWUuc2l6ZUxpbWl0ID8gdm9sdW1lLnNpemVMaW1pdC50b01lYmlieXRlcygpLnRvU3RyaW5nKCkgKyAnTWknIDogdW5kZWZpbmVkLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgICAgfTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgaWYgKEhvc3RQYXRoVm9sdW1lLmlzSG9zdFBhdGhWb2x1bWUodm9sdW1lKSkge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgbmFtZTogdm9sdW1lLm5hbWUsXG4gICAgICAgICAgICAgICAgICAgIGhvc3RQYXRoOiB7XG4gICAgICAgICAgICAgICAgICAgICAgcGF0aDogdm9sdW1lLnBhdGgsXG4gICAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICBpZiAoU2VjcmV0UGF0aFZvbHVtZS5pc1NlY3JldFBhdGhWb2x1bWUodm9sdW1lKSkge1xuICAgICAgICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgICAgICAgbmFtZTogdm9sdW1lLm5hbWUsXG4gICAgICAgICAgICAgICAgICAgIHNlY3JldDoge1xuICAgICAgICAgICAgICAgICAgICAgIG9wdGlvbmFsOiB2b2x1bWUub3B0aW9uYWwsXG4gICAgICAgICAgICAgICAgICAgICAgc2VjcmV0TmFtZTogdm9sdW1lLnNlY3JldE5hbWUsXG4gICAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICB9O1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHRocm93IG5ldyBFcnJvcigndW5rbm93biB2b2x1bWUgdHlwZScpO1xuICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSksXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICAgIHRoaXMuam9iRGVmaW5pdGlvbkFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UucmVmLCB7XG4gICAgICBzZXJ2aWNlOiAnYmF0Y2gnLFxuICAgICAgcmVzb3VyY2U6ICdqb2ItZGVmaW5pdGlvbicsXG4gICAgICByZXNvdXJjZU5hbWU6IHRoaXMucGh5c2ljYWxOYW1lLFxuICAgIH0pO1xuICAgIHRoaXMuam9iRGVmaW5pdGlvbk5hbWUgPSB0aGlzLmdldFJlc291cmNlTmFtZUF0dHJpYnV0ZShyZXNvdXJjZS5yZWYpO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts deleted file mode 100644 index ffad48bef4c02..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/index.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -export * from './ecs-job-definition'; -export { IComputeEnvironment, ComputeEnvironmentProps } from './compute-environment-base'; -export * from './eks-job-definition'; -export * from './ecs-container-definition'; -export * from './eks-container-definition'; -export * from './job-definition-base'; -export * from './job-queue'; -export * from './linux-parameters'; -export * from './managed-compute-environment'; -export * from './multinode-job-definition'; -export * from './scheduling-policy'; -export * from './unmanaged-compute-environment'; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/index.js b/packages/@aws-cdk/aws-batch-alpha/lib/index.js deleted file mode 100644 index 586a60b134365..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/index.js +++ /dev/null @@ -1,29 +0,0 @@ -"use strict"; -var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - var desc = Object.getOwnPropertyDescriptor(m, k); - if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) { - desc = { enumerable: true, get: function() { return m[k]; } }; - } - Object.defineProperty(o, k2, desc); -}) : (function(o, m, k, k2) { - if (k2 === undefined) k2 = k; - o[k2] = m[k]; -})); -var __exportStar = (this && this.__exportStar) || function(m, exports) { - for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p); -}; -Object.defineProperty(exports, "__esModule", { value: true }); -// AWS::Batch CloudFormation Resources: -__exportStar(require("./ecs-job-definition"), exports); -__exportStar(require("./eks-job-definition"), exports); -__exportStar(require("./ecs-container-definition"), exports); -__exportStar(require("./eks-container-definition"), exports); -__exportStar(require("./job-definition-base"), exports); -__exportStar(require("./job-queue"), exports); -__exportStar(require("./linux-parameters"), exports); -__exportStar(require("./managed-compute-environment"), exports); -__exportStar(require("./multinode-job-definition"), exports); -__exportStar(require("./scheduling-policy"), exports); -__exportStar(require("./unmanaged-compute-environment"), exports); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7Ozs7O0FBQUEsdUNBQXVDO0FBQ3ZDLHVEQUFxQztBQUVyQyx1REFBcUM7QUFDckMsNkRBQTJDO0FBQzNDLDZEQUEyQztBQUMzQyx3REFBc0M7QUFDdEMsOENBQTRCO0FBQzVCLHFEQUFtQztBQUNuQyxnRUFBOEM7QUFDOUMsNkRBQTJDO0FBQzNDLHNEQUFvQztBQUNwQyxrRUFBZ0QiLCJzb3VyY2VzQ29udGVudCI6WyIvLyBBV1M6OkJhdGNoIENsb3VkRm9ybWF0aW9uIFJlc291cmNlczpcbmV4cG9ydCAqIGZyb20gJy4vZWNzLWpvYi1kZWZpbml0aW9uJztcbmV4cG9ydCB7IElDb21wdXRlRW52aXJvbm1lbnQsIENvbXB1dGVFbnZpcm9ubWVudFByb3BzIH0gZnJvbSAnLi9jb21wdXRlLWVudmlyb25tZW50LWJhc2UnO1xuZXhwb3J0ICogZnJvbSAnLi9la3Mtam9iLWRlZmluaXRpb24nO1xuZXhwb3J0ICogZnJvbSAnLi9lY3MtY29udGFpbmVyLWRlZmluaXRpb24nO1xuZXhwb3J0ICogZnJvbSAnLi9la3MtY29udGFpbmVyLWRlZmluaXRpb24nO1xuZXhwb3J0ICogZnJvbSAnLi9qb2ItZGVmaW5pdGlvbi1iYXNlJztcbmV4cG9ydCAqIGZyb20gJy4vam9iLXF1ZXVlJztcbmV4cG9ydCAqIGZyb20gJy4vbGludXgtcGFyYW1ldGVycyc7XG5leHBvcnQgKiBmcm9tICcuL21hbmFnZWQtY29tcHV0ZS1lbnZpcm9ubWVudCc7XG5leHBvcnQgKiBmcm9tICcuL211bHRpbm9kZS1qb2ItZGVmaW5pdGlvbic7XG5leHBvcnQgKiBmcm9tICcuL3NjaGVkdWxpbmctcG9saWN5JztcbmV4cG9ydCAqIGZyb20gJy4vdW5tYW5hZ2VkLWNvbXB1dGUtZW52aXJvbm1lbnQnOyJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts deleted file mode 100644 index 27ab7a53f3600..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.d.ts +++ /dev/null @@ -1,217 +0,0 @@ -import { Duration, IResource, Resource } from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -import { CfnJobDefinitionProps } from 'aws-cdk-lib/aws-batch'; -/** - * Represents a JobDefinition - */ -export interface IJobDefinition extends IResource { - /** - * The ARN of this job definition - * - * @attribute - */ - readonly jobDefinitionArn: string; - /** - * The name of this job definition - * - * @attribute - */ - readonly jobDefinitionName: string; - /** - * The default parameters passed to the container - * These parameters can be referenced in the `command` that - * you give to the container - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters - * - * @default none - */ - readonly parameters?: { - [key: string]: any; - }; - /** - * The number of times to retry a job. - * The job is retried on failure the same number of attempts as the value. - * - * @default 1 - */ - readonly retryAttempts?: number; - /** - * Defines the retry behavior for this job - * - * @default - no `RetryStrategy` - */ - readonly retryStrategies: RetryStrategy[]; - /** - * The priority of this Job. Only used in Fairshare Scheduling - * to decide which job to run first when there are multiple jobs - * with the same share identifier. - * - * @default none - */ - readonly schedulingPriority?: number; - /** - * The timeout time for jobs that are submitted with this job definition. - * After the amount of time you specify passes, - * Batch terminates your jobs if they aren't finished. - * - * @default - no timeout - */ - readonly timeout?: Duration; - /** - * Add a RetryStrategy to this JobDefinition - */ - addRetryStrategy(strategy: RetryStrategy): void; -} -/** - * Props common to all JobDefinitions - */ -export interface JobDefinitionProps { - /** - * The name of this job definition - * - * @default - generated by CloudFormation - */ - readonly jobDefinitionName?: string; - /** - * The default parameters passed to the container - * These parameters can be referenced in the `command` that - * you give to the container - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/job_definition_parameters.html#parameters - * - * @default none - */ - readonly parameters?: { - [key: string]: any; - }; - /** - * The number of times to retry a job. - * The job is retried on failure the same number of attempts as the value. - * - * @default 1 - */ - readonly retryAttempts?: number; - /** - * Defines the retry behavior for this job - * - * @default - no `RetryStrategy` - */ - readonly retryStrategies?: RetryStrategy[]; - /** - * The priority of this Job. Only used in Fairshare Scheduling - * to decide which job to run first when there are multiple jobs - * with the same share identifier. - * - * @default none - */ - readonly schedulingPriority?: number; - /** - * The timeout time for jobs that are submitted with this job definition. - * After the amount of time you specify passes, - * Batch terminates your jobs if they aren't finished. - * - * @default - no timeout - */ - readonly timeout?: Duration; -} -/** - * Define how Jobs using this JobDefinition respond to different exit conditions - */ -export declare class RetryStrategy { - /** - * Create a new RetryStrategy - */ - static of(action: Action, on: Reason): RetryStrategy; - /** - * The action to take when the job exits with the Reason specified - */ - readonly action: Action; - /** - * If the job exits with this Reason it will trigger the specified Action - */ - readonly on: Reason; - constructor(action: Action, on: Reason); -} -/** - * The Action to take when all specified conditions in a RetryStrategy are met - */ -export declare enum Action { - /** - * The job will not retry - */ - EXIT = "EXIT", - /** - * The job will retry. It can be retried up to the number of times specified in `retryAttempts`. - */ - RETRY = "RETRY" -} -/** - * The corresponding Action will only be taken if *all* of the conditions specified here are met. - */ -export interface CustomReason { - /** - * A glob string that will match on the job exit code. For example, `'40*'` will match 400, 404, 40123456789012 - * - * @default - will not match on the exit code - */ - readonly onExitCode?: string; - /** - * A glob string that will match on the statusReason returned by the exiting job. - * For example, `'Host EC2*'` indicates that the spot instance has been reclaimed. - * - * @default - will not match on the status reason - */ - readonly onStatusReason?: string; - /** - * A glob string that will match on the reason returned by the exiting job - * For example, `'CannotPullContainerError*'` indicates that container needed to start the job could not be pulled. - * - * @default - will not match on the reason - */ - readonly onReason?: string; -} -/** - * Common job exit reasons - */ -export declare class Reason { - /** - * Will match any non-zero exit code - */ - static readonly NON_ZERO_EXIT_CODE: Reason; - /** - * Will only match if the Docker container could not be pulled - */ - static readonly CANNOT_PULL_CONTAINER: Reason; - /** - * Will only match if the Spot instance executing the job was reclaimed - */ - static readonly SPOT_INSTANCE_RECLAIMED: Reason; - /** - * A custom Reason that can match on multiple conditions. - * Note that all specified conditions must be met for this reason to match. - */ - static custom(customReasonProps: CustomReason): Reason; -} -/** - * Abstract base class for JobDefinitions - * - * @internal - */ -export declare abstract class JobDefinitionBase extends Resource implements IJobDefinition { - abstract readonly jobDefinitionArn: string; - abstract readonly jobDefinitionName: string; - readonly parameters?: { - [key: string]: any; - }; - readonly retryAttempts?: number; - readonly retryStrategies: RetryStrategy[]; - readonly schedulingPriority?: number; - readonly timeout?: Duration; - constructor(scope: Construct, id: string, props?: JobDefinitionProps); - addRetryStrategy(strategy: RetryStrategy): void; -} -/** - * @internal - */ -export declare function baseJobDefinitionProperties(baseJobDefinition: JobDefinitionBase): CfnJobDefinitionProps; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js b/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js deleted file mode 100644 index 14745de9bb71c..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/job-definition-base.js +++ /dev/null @@ -1,153 +0,0 @@ -"use strict"; -var _a, _b; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.baseJobDefinitionProperties = exports.JobDefinitionBase = exports.Reason = exports.Action = exports.RetryStrategy = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -/** - * Define how Jobs using this JobDefinition respond to different exit conditions - */ -class RetryStrategy { - /** - * Create a new RetryStrategy - */ - static of(action, on) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Action(action); - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Reason(on); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.of); - } - throw error; - } - return new RetryStrategy(action, on); - } - constructor(action, on) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Action(action); - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Reason(on); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, RetryStrategy); - } - throw error; - } - this.action = action; - this.on = on; - } -} -exports.RetryStrategy = RetryStrategy; -_a = JSII_RTTI_SYMBOL_1; -RetryStrategy[_a] = { fqn: "@aws-cdk/aws-batch-alpha.RetryStrategy", version: "0.0.0" }; -/** - * The Action to take when all specified conditions in a RetryStrategy are met - */ -var Action; -(function (Action) { - /** - * The job will not retry - */ - Action["EXIT"] = "EXIT"; - /** - * The job will retry. It can be retried up to the number of times specified in `retryAttempts`. - */ - Action["RETRY"] = "RETRY"; -})(Action || (exports.Action = Action = {})); -/** - * Common job exit reasons - */ -class Reason { - /** - * A custom Reason that can match on multiple conditions. - * Note that all specified conditions must be met for this reason to match. - */ - static custom(customReasonProps) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_CustomReason(customReasonProps); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.custom); - } - throw error; - } - return customReasonProps; - } -} -exports.Reason = Reason; -_b = JSII_RTTI_SYMBOL_1; -Reason[_b] = { fqn: "@aws-cdk/aws-batch-alpha.Reason", version: "0.0.0" }; -/** - * Will match any non-zero exit code - */ -Reason.NON_ZERO_EXIT_CODE = { - onExitCode: '*', -}; -/** - * Will only match if the Docker container could not be pulled - */ -Reason.CANNOT_PULL_CONTAINER = { - onReason: 'CannotPullContainerError:*', -}; -/** - * Will only match if the Spot instance executing the job was reclaimed - */ -Reason.SPOT_INSTANCE_RECLAIMED = { - onStatusReason: 'Host EC2*', -}; -/** - * Abstract base class for JobDefinitions - * - * @internal - */ -class JobDefinitionBase extends core_1.Resource { - constructor(scope, id, props) { - super(scope, id, { - physicalName: props?.jobDefinitionName, - }); - this.parameters = props?.parameters; - this.retryAttempts = props?.retryAttempts; - this.retryStrategies = props?.retryStrategies ?? []; - this.schedulingPriority = props?.schedulingPriority; - this.timeout = props?.timeout; - } - addRetryStrategy(strategy) { - this.retryStrategies.push(strategy); - } -} -exports.JobDefinitionBase = JobDefinitionBase; -/** - * @internal - */ -function baseJobDefinitionProperties(baseJobDefinition) { - return { - parameters: baseJobDefinition.parameters, - retryStrategy: { - attempts: baseJobDefinition.retryAttempts, - evaluateOnExit: core_1.Lazy.any({ - produce: () => { - if (baseJobDefinition.retryStrategies.length === 0) { - return undefined; - } - return baseJobDefinition.retryStrategies.map((strategy) => { - return { - action: strategy.action, - ...strategy.on, - }; - }); - }, - }), - }, - schedulingPriority: baseJobDefinition.schedulingPriority, - timeout: { - attemptDurationSeconds: baseJobDefinition.timeout?.toSeconds(), - }, - type: 'dummy', - }; -} -exports.baseJobDefinitionProperties = baseJobDefinitionProperties; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLWRlZmluaXRpb24tYmFzZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImpvYi1kZWZpbml0aW9uLWJhc2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsMkNBQXVFO0FBZ0l2RTs7R0FFRztBQUNILE1BQWEsYUFBYTtJQUN4Qjs7T0FFRztJQUNJLE1BQU0sQ0FBQyxFQUFFLENBQUMsTUFBYyxFQUFFLEVBQVU7Ozs7Ozs7Ozs7O1FBQ3pDLE9BQU8sSUFBSSxhQUFhLENBQUMsTUFBTSxFQUFFLEVBQUUsQ0FBQyxDQUFDO0tBQ3RDO0lBWUQsWUFBWSxNQUFjLEVBQUUsRUFBVTs7Ozs7OzsrQ0FsQjNCLGFBQWE7Ozs7UUF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Jhc2VKb2JEZWZpbml0aW9uLnBhcmFtZXRlcnMsXG4gICAgcmV0cnlTdHJhdGVneToge1xuICAgICAgYXR0ZW1wdHM6IGJhc2VKb2JEZWZpbml0aW9uLnJldHJ5QXR0ZW1wdHMsXG4gICAgICBldmFsdWF0ZU9uRXhpdDogTGF6eS5hbnkoe1xuICAgICAgICBwcm9kdWNlOiAoKSA9PiB7XG4gICAgICAgICAgaWYgKGJhc2VKb2JEZWZpbml0aW9uLnJldHJ5U3RyYXRlZ2llcy5sZW5ndGggPT09IDApIHtcbiAgICAgICAgICAgIHJldHVybiB1bmRlZmluZWQ7XG4gICAgICAgICAgfVxuICAgICAgICAgIHJldHVybiBiYXNlSm9iRGVmaW5pdGlvbi5yZXRyeVN0cmF0ZWdpZXMubWFwKChzdHJhdGVneSkgPT4ge1xuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgYWN0aW9uOiBzdHJhdGVneS5hY3Rpb24sXG4gICAgICAgICAgICAgIC4uLnN0cmF0ZWd5Lm9uLFxuICAgICAgICAgICAgfTtcbiAgICAgICAgICB9KTtcbiAgICAgICAgfSxcbiAgICAgIH0pLFxuICAgIH0sXG4gICAgc2NoZWR1bGluZ1ByaW9yaXR5OiBiYXNlSm9iRGVmaW5pdGlvbi5zY2hlZHVsaW5nUHJpb3JpdHksXG4gICAgdGltZW91dDoge1xuICAgICAgYXR0ZW1wdER1cmF0aW9uU2Vjb25kczogYmFzZUpvYkRlZmluaXRpb24udGltZW91dD8udG9TZWNvbmRzKCksXG4gICAgfSxcbiAgICB0eXBlOiAnZHVtbXknLFxuICB9O1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts deleted file mode 100644 index d72695ba8bdbb..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.d.ts +++ /dev/null @@ -1,140 +0,0 @@ -import { IResource, Resource } from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -import { IComputeEnvironment } from './compute-environment-base'; -import { ISchedulingPolicy } from './scheduling-policy'; -/** - * Represents a JobQueue - */ -export interface IJobQueue extends IResource { - /** - * The name of the job queue. It can be up to 128 letters long. - * It can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_) - * - * @attribute - */ - readonly jobQueueName: string; - /** - * The ARN of this job queue - * - * @attribute - */ - readonly jobQueueArn: string; - /** - * The set of compute environments mapped to a job queue and their order relative to each other. - * The job scheduler uses this parameter to determine which compute environment runs a specific job. - * Compute environments must be in the VALID state before you can associate them with a job queue. - * You can associate up to three compute environments with a job queue. - * All of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT); - * EC2 and Fargate compute environments can't be mixed. - * - * *Note*: All compute environments that are associated with a job queue must share the same architecture. - * AWS Batch doesn't support mixing compute environment architecture types in a single job queue. - */ - readonly computeEnvironments: OrderedComputeEnvironment[]; - /** - * The priority of the job queue. - * Job queues with a higher priority are evaluated first when associated with the same compute environment. - * Priority is determined in descending order. - * For example, a job queue with a priority value of 10 is given scheduling preference over a job queue with a priority value of 1. - */ - readonly priority: number; - /** - * If the job queue is enabled, it is able to accept jobs. - * Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish. - * - * @default true - */ - readonly enabled?: boolean; - /** - * The SchedulingPolicy for this JobQueue. Instructs the Scheduler how to schedule different jobs. - * - * @default - no scheduling policy - */ - readonly schedulingPolicy?: ISchedulingPolicy; - /** - * Add a `ComputeEnvironment` to this Queue. - * The Queue will prefer lower-order `ComputeEnvironment`s. - */ - addComputeEnvironment(computeEnvironment: IComputeEnvironment, order: number): void; -} -/** - * Props to configure a JobQueue - */ -export interface JobQueueProps { - /** - * The set of compute environments mapped to a job queue and their order relative to each other. - * The job scheduler uses this parameter to determine which compute environment runs a specific job. - * Compute environments must be in the VALID state before you can associate them with a job queue. - * You can associate up to three compute environments with a job queue. - * All of the compute environments must be either EC2 (EC2 or SPOT) or Fargate (FARGATE or FARGATE_SPOT); - * EC2 and Fargate compute environments can't be mixed. - * - * *Note*: All compute environments that are associated with a job queue must share the same architecture. - * AWS Batch doesn't support mixing compute environment architecture types in a single job queue. - * - * @default none - */ - readonly computeEnvironments?: OrderedComputeEnvironment[]; - /** - * The priority of the job queue. - * Job queues with a higher priority are evaluated first when associated with the same compute environment. - * Priority is determined in descending order. - * For example, a job queue with a priority of 10 is given scheduling preference over a job queue with a priority of 1. - * - * @default 1 - */ - readonly priority?: number; - /** - * The name of the job queue. It can be up to 128 letters long. - * It can contain uppercase and lowercase letters, numbers, hyphens (-), and underscores (_) - * - * @default - no name - */ - readonly jobQueueName?: string; - /** - * If the job queue is enabled, it is able to accept jobs. - * Otherwise, new jobs can't be added to the queue, but jobs already in the queue can finish. - * - * @default true - */ - readonly enabled?: boolean; - /** - * The SchedulingPolicy for this JobQueue. Instructs the Scheduler how to schedule different jobs. - * - * @default - no scheduling policy - */ - readonly schedulingPolicy?: ISchedulingPolicy; -} -/** - * Assigns an order to a ComputeEnvironment. - * The JobQueue will prioritize the lowest-order ComputeEnvironment. - */ -export interface OrderedComputeEnvironment { - /** - * The ComputeEnvironment to link to this JobQueue - */ - readonly computeEnvironment: IComputeEnvironment; - /** - * The order associated with `computeEnvironment` - */ - readonly order: number; -} -/** - * JobQueues can receive Jobs, which are removed from the queue when - * sent to the linked ComputeEnvironment(s) to be executed. - * Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked. - */ -export declare class JobQueue extends Resource implements IJobQueue { - /** - * refer to an existing JobQueue by its arn - */ - static fromJobQueueArn(scope: Construct, id: string, jobQueueArn: string): IJobQueue; - readonly computeEnvironments: OrderedComputeEnvironment[]; - readonly priority: number; - readonly enabled?: boolean; - readonly schedulingPolicy?: ISchedulingPolicy; - readonly jobQueueArn: string; - readonly jobQueueName: string; - constructor(scope: Construct, id: string, props?: JobQueueProps); - addComputeEnvironment(computeEnvironment: IComputeEnvironment, order: number): void; -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js b/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js deleted file mode 100644 index a769e9e07cb5e..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/job-queue.js +++ /dev/null @@ -1,102 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.JobQueue = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -/** - * JobQueues can receive Jobs, which are removed from the queue when - * sent to the linked ComputeEnvironment(s) to be executed. - * Jobs exit the queue in FIFO order unless a `SchedulingPolicy` is linked. - */ -class JobQueue extends core_1.Resource { - /** - * refer to an existing JobQueue by its arn - */ - static fromJobQueueArn(scope, id, jobQueueArn) { - const stack = core_1.Stack.of(scope); - class Import extends core_1.Resource { - constructor() { - super(...arguments); - this.computeEnvironments = []; - this.priority = 1; - this.jobQueueArn = jobQueueArn; - this.jobQueueName = stack.splitArn(jobQueueArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - } - addComputeEnvironment(_computeEnvironment, _order) { - throw new Error(`cannot add ComputeEnvironments to imported JobQueue '${id}'`); - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, { - physicalName: props?.jobQueueName, - }); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_JobQueueProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, JobQueue); - } - throw error; - } - this.computeEnvironments = props?.computeEnvironments ?? []; - this.priority = props?.priority ?? 1; - this.enabled = props?.enabled; - this.schedulingPolicy = props?.schedulingPolicy; - const resource = new aws_batch_1.CfnJobQueue(this, 'Resource', { - computeEnvironmentOrder: core_1.Lazy.any({ - produce: () => this.computeEnvironments.map((ce) => { - return { - computeEnvironment: ce.computeEnvironment.computeEnvironmentArn, - order: ce.order, - }; - }), - }), - priority: this.priority, - jobQueueName: props?.jobQueueName, - state: (this.enabled ?? true) ? 'ENABLED' : 'DISABLED', - schedulingPolicyArn: this.schedulingPolicy?.schedulingPolicyArn, - }); - this.jobQueueArn = this.getResourceArnAttribute(resource.attrJobQueueArn, { - service: 'batch', - resource: 'job-queue', - resourceName: this.physicalName, - }); - this.jobQueueName = core_1.Stack.of(this).splitArn(this.jobQueueArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - this.node.addValidation({ validate: () => validateOrderedComputeEnvironments(this.computeEnvironments) }); - } - addComputeEnvironment(computeEnvironment, order) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_IComputeEnvironment(computeEnvironment); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addComputeEnvironment); - } - throw error; - } - this.computeEnvironments.push({ - computeEnvironment, - order, - }); - } -} -exports.JobQueue = JobQueue; -_a = JSII_RTTI_SYMBOL_1; -JobQueue[_a] = { fqn: "@aws-cdk/aws-batch-alpha.JobQueue", version: "0.0.0" }; -function validateOrderedComputeEnvironments(computeEnvironments) { - const seenOrders = []; - for (const ce of computeEnvironments) { - if (seenOrders.includes(ce.order)) { - return ['assigns the same order to different ComputeEnvironments']; - } - seenOrders.push(ce.order); - } - return seenOrders.length === 0 ? ['This JobQueue does not link any ComputeEnvironments'] : []; -} -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLXF1ZXVlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiam9iLXF1ZXVlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUFBLDJDQUErRTtBQUUvRSxxREFBb0Q7QUF1SXBEOzs7O0dBSUc7QUFDSCxNQUFhLFFBQVMsU0FBUSxlQUFRO0lBQ3BDOztPQU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cmRlcnMucHVzaChjZS5vcmRlcik7XG4gIH1cblxuICByZXR1cm4gc2Vlbk9yZGVycy5sZW5ndGggPT09IDAgPyBbJ1RoaXMgSm9iUXVldWUgZG9lcyBub3QgbGluayBhbnkgQ29tcHV0ZUVudmlyb25tZW50cyddIDogW107XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts deleted file mode 100644 index e9336be95bd7a..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.d.ts +++ /dev/null @@ -1,196 +0,0 @@ -import * as cdk from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -import { CfnJobDefinition } from 'aws-cdk-lib/aws-batch'; -/** - * The properties for defining Linux-specific options that are applied to the container. - */ -export interface LinuxParametersProps { - /** - * Specifies whether to run an init process inside the container that forwards signals and reaps processes. - * - * @default false - */ - readonly initProcessEnabled?: boolean; - /** - * The value for the size of the /dev/shm volume. - * - * @default No shared memory. - */ - readonly sharedMemorySize?: cdk.Size; - /** - * The total amount of swap memory a container can use. This parameter - * will be translated to the --memory-swap option to docker run. - * - * This parameter is only supported when you are using the EC2 launch type. - * Accepted values are positive integers. - * - * @default No swap. - */ - readonly maxSwap?: cdk.Size; - /** - * This allows you to tune a container's memory swappiness behavior. This parameter - * maps to the --memory-swappiness option to docker run. The swappiness relates - * to the kernel's tendency to swap memory. A value of 0 will cause swapping to - * not happen unless absolutely necessary. A value of 100 will cause pages to - * be swapped very aggressively. - * - * This parameter is only supported when you are using the EC2 launch type. - * Accepted values are whole numbers between 0 and 100. If a value is not - * specified for maxSwap then this parameter is ignored. - * - * @default 60 - */ - readonly swappiness?: number; -} -/** - * Linux-specific options that are applied to the container. - */ -export declare class LinuxParameters extends Construct { - /** - * Whether the init process is enabled - */ - protected readonly initProcessEnabled?: boolean; - /** - * The shared memory size (in MiB). Not valid for Fargate launch type - */ - protected readonly sharedMemorySize?: cdk.Size; - /** - * The max swap memory - */ - protected readonly maxSwap?: cdk.Size; - /** - * The swappiness behavior - */ - protected readonly swappiness?: number; - /** - * Device mounts - */ - protected readonly devices: Device[]; - /** - * TmpFs mounts - */ - protected readonly tmpfs: Tmpfs[]; - /** - * Constructs a new instance of the LinuxParameters class. - */ - constructor(scope: Construct, id: string, props?: LinuxParametersProps); - private validateProps; - /** - * Adds one or more host devices to a container. - */ - addDevices(...device: Device[]): void; - /** - * Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container. - * - * Only works with EC2 launch type. - */ - addTmpfs(...tmpfs: Tmpfs[]): void; - /** - * Renders the Linux parameters to the Batch version of this resource, - * which does not have 'capabilities' and requires tmpfs.containerPath to be defined. - */ - renderLinuxParameters(): CfnJobDefinition.LinuxParametersProperty; -} -/** - * A container instance host device. - */ -export interface Device { - /** - * The path inside the container at which to expose the host device. - * - * @default Same path as the host - */ - readonly containerPath?: string; - /** - * The path for the device on the host container instance. - */ - readonly hostPath: string; - /** - * The explicit permissions to provide to the container for the device. - * By default, the container has permissions for read, write, and mknod for the device. - * - * @default Readonly - */ - readonly permissions?: DevicePermission[]; -} -/** - * The details of a tmpfs mount for a container. - */ -export interface Tmpfs { - /** - * The absolute file path where the tmpfs volume is to be mounted. - */ - readonly containerPath: string; - /** - * The size (in MiB) of the tmpfs volume. - */ - readonly size: cdk.Size; - /** - * The list of tmpfs volume mount options. For more information, see - * [TmpfsMountOptions](https://docs.aws.amazon.com/AmazonECS/latest/APIReference/API_Tmpfs.html). - * - * @default none - */ - readonly mountOptions?: TmpfsMountOption[]; -} -/** - * Permissions for device access - */ -export declare enum DevicePermission { - /** - * Read - */ - READ = "read", - /** - * Write - */ - WRITE = "write", - /** - * Make a node - */ - MKNOD = "mknod" -} -/** - * The supported options for a tmpfs mount for a container. - */ -export declare enum TmpfsMountOption { - DEFAULTS = "defaults", - RO = "ro", - RW = "rw", - SUID = "suid", - NOSUID = "nosuid", - DEV = "dev", - NODEV = "nodev", - EXEC = "exec", - NOEXEC = "noexec", - SYNC = "sync", - ASYNC = "async", - DIRSYNC = "dirsync", - REMOUNT = "remount", - MAND = "mand", - NOMAND = "nomand", - ATIME = "atime", - NOATIME = "noatime", - DIRATIME = "diratime", - NODIRATIME = "nodiratime", - BIND = "bind", - RBIND = "rbind", - UNBINDABLE = "unbindable", - RUNBINDABLE = "runbindable", - PRIVATE = "private", - RPRIVATE = "rprivate", - SHARED = "shared", - RSHARED = "rshared", - SLAVE = "slave", - RSLAVE = "rslave", - RELATIME = "relatime", - NORELATIME = "norelatime", - STRICTATIME = "strictatime", - NOSTRICTATIME = "nostrictatime", - MODE = "mode", - UID = "uid", - GID = "gid", - NR_INODES = "nr_inodes", - NR_BLOCKS = "nr_blocks", - MPOL = "mpol" -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js b/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js deleted file mode 100644 index 2a00173e4d6da..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/linux-parameters.js +++ /dev/null @@ -1,175 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.TmpfsMountOption = exports.DevicePermission = exports.LinuxParameters = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const cdk = require("aws-cdk-lib/core"); -const constructs_1 = require("constructs"); -/** - * Linux-specific options that are applied to the container. - */ -class LinuxParameters extends constructs_1.Construct { - /** - * Constructs a new instance of the LinuxParameters class. - */ - constructor(scope, id, props = {}) { - super(scope, id); - /** - * Device mounts - */ - this.devices = new Array(); - /** - * TmpFs mounts - */ - this.tmpfs = new Array(); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_LinuxParametersProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, LinuxParameters); - } - throw error; - } - this.validateProps(props); - this.sharedMemorySize = props.sharedMemorySize; - this.initProcessEnabled = props.initProcessEnabled; - this.maxSwap = props.maxSwap; - this.swappiness = props.maxSwap ? props.swappiness : undefined; - } - validateProps(props) { - if (!cdk.Token.isUnresolved(props.swappiness) && - props.swappiness !== undefined && - (!Number.isInteger(props.swappiness) || props.swappiness < 0 || props.swappiness > 100)) { - throw new Error(`swappiness: Must be an integer between 0 and 100; received ${props.swappiness}.`); - } - } - /** - * Adds one or more host devices to a container. - */ - addDevices(...device) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Device(device); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addDevices); - } - throw error; - } - this.devices.push(...device); - } - /** - * Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container. - * - * Only works with EC2 launch type. - */ - addTmpfs(...tmpfs) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Tmpfs(tmpfs); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addTmpfs); - } - throw error; - } - this.tmpfs.push(...tmpfs); - } - /** - * Renders the Linux parameters to the Batch version of this resource, - * which does not have 'capabilities' and requires tmpfs.containerPath to be defined. - */ - renderLinuxParameters() { - return { - initProcessEnabled: this.initProcessEnabled, - sharedMemorySize: this.sharedMemorySize?.toMebibytes(), - maxSwap: this.maxSwap?.toMebibytes(), - swappiness: this.swappiness, - devices: cdk.Lazy.any({ produce: () => this.devices.map(renderDevice) }, { omitEmptyArray: true }), - tmpfs: cdk.Lazy.any({ produce: () => this.tmpfs.map(renderTmpfs) }, { omitEmptyArray: true }), - }; - } -} -exports.LinuxParameters = LinuxParameters; -_a = JSII_RTTI_SYMBOL_1; -LinuxParameters[_a] = { fqn: "@aws-cdk/aws-batch-alpha.LinuxParameters", version: "0.0.0" }; -/** - * Permissions for device access - */ -var DevicePermission; -(function (DevicePermission) { - /** - * Read - */ - DevicePermission["READ"] = "read"; - /** - * Write - */ - DevicePermission["WRITE"] = "write"; - /** - * Make a node - */ - DevicePermission["MKNOD"] = "mknod"; -})(DevicePermission || (exports.DevicePermission = DevicePermission = {})); -/** - * The supported options for a tmpfs mount for a container. - */ -var TmpfsMountOption; -(function (TmpfsMountOption) { - TmpfsMountOption["DEFAULTS"] = "defaults"; - TmpfsMountOption["RO"] = "ro"; - TmpfsMountOption["RW"] = "rw"; - TmpfsMountOption["SUID"] = "suid"; - TmpfsMountOption["NOSUID"] = "nosuid"; - TmpfsMountOption["DEV"] = "dev"; - TmpfsMountOption["NODEV"] = "nodev"; - TmpfsMountOption["EXEC"] = "exec"; - TmpfsMountOption["NOEXEC"] = "noexec"; - TmpfsMountOption["SYNC"] = "sync"; - TmpfsMountOption["ASYNC"] = "async"; - TmpfsMountOption["DIRSYNC"] = "dirsync"; - TmpfsMountOption["REMOUNT"] = "remount"; - TmpfsMountOption["MAND"] = "mand"; - TmpfsMountOption["NOMAND"] = "nomand"; - TmpfsMountOption["ATIME"] = "atime"; - TmpfsMountOption["NOATIME"] = "noatime"; - TmpfsMountOption["DIRATIME"] = "diratime"; - TmpfsMountOption["NODIRATIME"] = "nodiratime"; - TmpfsMountOption["BIND"] = "bind"; - TmpfsMountOption["RBIND"] = "rbind"; - TmpfsMountOption["UNBINDABLE"] = "unbindable"; - TmpfsMountOption["RUNBINDABLE"] = "runbindable"; - TmpfsMountOption["PRIVATE"] = "private"; - TmpfsMountOption["RPRIVATE"] = "rprivate"; - TmpfsMountOption["SHARED"] = "shared"; - TmpfsMountOption["RSHARED"] = "rshared"; - TmpfsMountOption["SLAVE"] = "slave"; - TmpfsMountOption["RSLAVE"] = "rslave"; - TmpfsMountOption["RELATIME"] = "relatime"; - TmpfsMountOption["NORELATIME"] = "norelatime"; - TmpfsMountOption["STRICTATIME"] = "strictatime"; - TmpfsMountOption["NOSTRICTATIME"] = "nostrictatime"; - TmpfsMountOption["MODE"] = "mode"; - TmpfsMountOption["UID"] = "uid"; - TmpfsMountOption["GID"] = "gid"; - TmpfsMountOption["NR_INODES"] = "nr_inodes"; - TmpfsMountOption["NR_BLOCKS"] = "nr_blocks"; - TmpfsMountOption["MPOL"] = "mpol"; -})(TmpfsMountOption || (exports.TmpfsMountOption = TmpfsMountOption = {})); -function renderTmpfs(tmpfs) { - return { - containerPath: tmpfs.containerPath, - size: tmpfs.size.toMebibytes(), - mountOptions: tmpfs.mountOptions, - }; -} -function renderDevice(device) { - return { - containerPath: device.containerPath, - hostPath: device.hostPath, - permissions: device.permissions, - }; -} -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGludXgtcGFyYW1ldGVycy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImxpbnV4LXBhcmFtZXRlcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsd0NBQXdDO0FBQ3hDLDJDQUF1QztBQWdEdkM7O0dBRUc7QUFDSCxNQUFhLGVBQWdCLFNBQVEsc0JBQVM7SUErQjVDOztPQUVHO0lBQ0gsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxRQUE4QixFQUFFO1FBQ3hFLEtBQUssQ0FBQyxLQUFLLEVBQUUsRUFBRSxDQUFDLENBQUM7UUFkbkI7O1dBRUc7UUFDZ0IsWUFBTyxHQUFHLElBQUksS0FBSyxFQUFVLENBQUM7UUFFakQ7O1dBRUc7UUFDZ0IsVUFBSyxHQUFHLElBQUksS0FBSyxFQUFTLENBQUM7Ozs7OzsrQ0E3Qm5DLGVBQWU7Ozs7UUFxQ3hCLElBQUksQ0FBQyxhQUFhLENBQUMsS0FBSyxDQUFDLENBQUM7UUFFMUIsSUFBSSxDQUFDLGdCQUFnQixHQUFHLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQztRQUMvQyxJQUFJLENBQUMsa0JBQWtCLEdBQUcsS0FBSyxDQUFDLGtCQUFrQixDQUFD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U0hBUkVEID0gJ3JzaGFyZWQnLFxuICBTTEFWRSA9ICdzbGF2ZScsXG4gIFJTTEFWRSA9ICdyc2xhdmUnLFxuICBSRUxBVElNRSA9ICdyZWxhdGltZScsXG4gIE5PUkVMQVRJTUUgPSAnbm9yZWxhdGltZScsXG4gIFNUUklDVEFUSU1FID0gJ3N0cmljdGF0aW1lJyxcbiAgTk9TVFJJQ1RBVElNRSA9ICdub3N0cmljdGF0aW1lJyxcbiAgTU9ERSA9ICdtb2RlJyxcbiAgVUlEID0gJ3VpZCcsXG4gIEdJRCA9ICdnaWQnLFxuICBOUl9JTk9ERVMgPSAnbnJfaW5vZGVzJyxcbiAgTlJfQkxPQ0tTID0gJ25yX2Jsb2NrcycsXG4gIE1QT0wgPSAnbXBvbCdcbn1cblxuZnVuY3Rpb24gcmVuZGVyVG1wZnModG1wZnM6IFRtcGZzKTogQ2ZuSm9iRGVmaW5pdGlvbi5UbXBmc1Byb3BlcnR5IHtcbiAgcmV0dXJuIHtcbiAgICBjb250YWluZXJQYXRoOiB0bXBmcy5jb250YWluZXJQYXRoLFxuICAgIHNpemU6IHRtcGZzLnNpemUudG9NZWJpYnl0ZXMoKSxcbiAgICBtb3VudE9wdGlvbnM6IHRtcGZzLm1vdW50T3B0aW9ucyxcbiAgfTtcbn1cblxuZnVuY3Rpb24gcmVuZGVyRGV2aWNlKGRldmljZTogRGV2aWNlKTogQ2ZuSm9iRGVmaW5pdGlvbi5EZXZpY2VQcm9wZXJ0eSB7XG4gIHJldHVybiB7XG4gICAgY29udGFpbmVyUGF0aDogZGV2aWNlLmNvbnRhaW5lclBhdGgsXG4gICAgaG9zdFBhdGg6IGRldmljZS5ob3N0UGF0aCxcbiAgICBwZXJtaXNzaW9uczogZGV2aWNlLnBlcm1pc3Npb25zLFxuICB9O1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts deleted file mode 100644 index 6578bdcb3fd27..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.d.ts +++ /dev/null @@ -1,806 +0,0 @@ -import * as ec2 from 'aws-cdk-lib/aws-ec2'; -import * as eks from 'aws-cdk-lib/aws-eks'; -import * as iam from 'aws-cdk-lib/aws-iam'; -import { Duration, ITaggable, TagManager } from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -import { IComputeEnvironment, ComputeEnvironmentBase, ComputeEnvironmentProps } from './compute-environment-base'; -/** - * Represents a Managed ComputeEnvironment. Batch will provision EC2 Instances to - * meet the requirements of the jobs executing in this ComputeEnvironment. - */ -export interface IManagedComputeEnvironment extends IComputeEnvironment, ec2.IConnectable, ITaggable { - /** - * The maximum vCpus this `ManagedComputeEnvironment` can scale up to. - * - * *Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or - * `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances, - * The scheduler may exceed this number by at most one of the instances specified in `instanceTypes` - * or `instanceClasses`. - */ - readonly maxvCpus: number; - /** - * Specifies whether this Compute Environment is replaced if an update is made that requires - * replacing its instances. To enable more properties to be updated, - * set this property to `false`. When changing the value of this property to false, - * do not change any other properties at the same time. - * If other properties are changed at the same time, - * and the change needs to be rolled back but it can't, - * it's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state. - * You can't update a stack that is in the UPDATE_ROLLBACK_FAILED state. - * However, if you can continue to roll it back, - * you can return the stack to its original settings and then try to update it again. - * - * The properties which require a replacement of the Compute Environment are: - * - * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-replacecomputeenvironment - * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html - */ - readonly replaceComputeEnvironment?: boolean; - /** - * Whether or not to use spot instances. - * Spot instances are less expensive EC2 instances that can be - * reclaimed by EC2 at any time; your job will be given two minutes - * of notice before reclamation. - * - * @default false - */ - readonly spot?: boolean; - /** - * Only meaningful if `terminateOnUpdate` is `false`. If so, - * when an infrastructure update is triggered, any running jobs - * will be allowed to run until `updateTimeout` has expired. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html - * @default 30 minutes - */ - readonly updateTimeout?: Duration; - /** - * Whether or not any running jobs will be immediately terminated when an infrastructure update - * occurs. If this is enabled, any terminated jobs may be retried, depending on the job's - * retry policy. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html - * - * @default false - */ - readonly terminateOnUpdate?: boolean; - /** - * The security groups this Compute Environment will launch instances in. - */ - readonly securityGroups: ec2.ISecurityGroup[]; - /** - * The VPC Subnets this Compute Environment will launch instances in. - */ - readonly vpcSubnets?: ec2.SubnetSelection; - /** - * Whether or not the AMI is updated to the latest one supported by Batch - * when an infrastructure update occurs. - * - * If you specify a specific AMI, this property will be ignored. - * - * @default true - */ - readonly updateToLatestImageVersion?: boolean; -} -/** - * Props for a ManagedComputeEnvironment - */ -export interface ManagedComputeEnvironmentProps extends ComputeEnvironmentProps { - /** - * The maximum vCpus this `ManagedComputeEnvironment` can scale up to. - * Each vCPU is equivalent to 1024 CPU shares. - * - * *Note*: if this Compute Environment uses EC2 resources (not Fargate) with either `AllocationStrategy.BEST_FIT_PROGRESSIVE` or - * `AllocationStrategy.SPOT_CAPACITY_OPTIMIZED`, or `AllocationStrategy.BEST_FIT` with Spot instances, - * The scheduler may exceed this number by at most one of the instances specified in `instanceTypes` - * or `instanceClasses`. - * - * @default 256 - */ - readonly maxvCpus?: number; - /** - * Specifies whether this Compute Environment is replaced if an update is made that requires - * replacing its instances. To enable more properties to be updated, - * set this property to `false`. When changing the value of this property to false, - * do not change any other properties at the same time. - * If other properties are changed at the same time, - * and the change needs to be rolled back but it can't, - * it's possible for the stack to go into the UPDATE_ROLLBACK_FAILED state. - * You can't update a stack that is in the UPDATE_ROLLBACK_FAILED state. - * However, if you can continue to roll it back, - * you can return the stack to its original settings and then try to update it again. - * - * The properties which require a replacement of the Compute Environment are: - * - * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-replacecomputeenvironment - * @see https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html - * - * @default false - */ - readonly replaceComputeEnvironment?: boolean; - /** - * Whether or not to use spot instances. - * Spot instances are less expensive EC2 instances that can be - * reclaimed by EC2 at any time; your job will be given two minutes - * of notice before reclamation. - * - * @default false - */ - readonly spot?: boolean; - /** - * Only meaningful if `terminateOnUpdate` is `false`. If so, - * when an infrastructure update is triggered, any running jobs - * will be allowed to run until `updateTimeout` has expired. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html - * - * @default 30 minutes - */ - readonly updateTimeout?: Duration; - /** - * Whether or not any running jobs will be immediately terminated when an infrastructure update - * occurs. If this is enabled, any terminated jobs may be retried, depending on the job's - * retry policy. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/updating-compute-environments.html - * - * @default false - */ - readonly terminateOnUpdate?: boolean; - /** - * VPC in which this Compute Environment will launch Instances - */ - readonly vpc: ec2.IVpc; - /** - * The security groups this Compute Environment will launch instances in. - * - * @default new security groups will be created - */ - readonly securityGroups?: ec2.ISecurityGroup[]; - /** - * The VPC Subnets this Compute Environment will launch instances in. - * - * @default new subnets will be created - */ - readonly vpcSubnets?: ec2.SubnetSelection; - /** - * Whether or not the AMI is updated to the latest one supported by Batch - * when an infrastructure update occurs. - * - * If you specify a specific AMI, this property will be ignored. - * - * @default true - */ - readonly updateToLatestImageVersion?: boolean; -} -/** - * Abstract base class for ManagedComputeEnvironments - * @internal - */ -export declare abstract class ManagedComputeEnvironmentBase extends ComputeEnvironmentBase implements IManagedComputeEnvironment { - readonly maxvCpus: number; - readonly replaceComputeEnvironment?: boolean; - readonly spot?: boolean; - readonly updateTimeout?: Duration; - readonly terminateOnUpdate?: boolean; - readonly securityGroups: ec2.ISecurityGroup[]; - readonly updateToLatestImageVersion?: boolean; - readonly tags: TagManager; - readonly connections: ec2.Connections; - constructor(scope: Construct, id: string, props: ManagedComputeEnvironmentProps); -} -/** - * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. - */ -export interface IManagedEc2EcsComputeEnvironment extends IManagedComputeEnvironment { - /** - * Configure which AMIs this Compute Environment can launch. - * - * Leave this `undefined` to allow Batch to choose the latest AMIs it supports for each instance that it launches. - * - * @default - * - ECS_AL2 compatible AMI ids for non-GPU instances, ECS_AL2_NVIDIA compatible AMI ids for GPU instances - */ - readonly images?: EcsMachineImage[]; - /** - * The allocation strategy to use if not enough instances of - * the best fitting instance type can be allocated. - * - * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, - * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. - */ - readonly allocationStrategy?: AllocationStrategy; - /** - * The maximum percentage that a Spot Instance price can be when compared with the - * On-Demand price for that instance type before instances are launched. - * For example, if your maximum percentage is 20%, the Spot price must be - * less than 20% of the current On-Demand price for that Instance. - * You always pay the lowest market price and never more than your maximum percentage. - * For most use cases, Batch recommends leaving this field empty. - * - * @default - 100% - */ - readonly spotBidPercentage?: number; - /** - * The service-linked role that Spot Fleet needs to launch instances on your behalf. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html - * - * @default - a new Role will be created - */ - readonly spotFleetRole?: iam.IRole; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - */ - readonly instanceTypes: ec2.InstanceType[]; - /** - * The instance classes that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - * Batch will automatically choose the size. - */ - readonly instanceClasses: ec2.InstanceClass[]; - /** - * Whether or not to use batch's optimal instance type. - * The optimal instance type is equivalent to adding the - * C4, M4, and R4 instance classes. You can specify other instance classes - * (of the same architecture) in addition to the optimal instance classes. - * - * @default true - */ - readonly useOptimalInstanceClasses?: boolean; - /** - * The execution Role that instances launched by this Compute Environment will use. - * - * @default - a role will be created - */ - readonly instanceRole?: iam.IRole; - /** - * The Launch Template that this Compute Environment - * will use to provision EC2 Instances. - * - * *Note*: if `securityGroups` is specified on both your - * launch template and this Compute Environment, **the - * `securityGroup`s on the Compute Environment override the - * ones on the launch template. - * - * @default no launch template - */ - readonly launchTemplate?: ec2.ILaunchTemplate; - /** - * The minimum vCPUs that an environment should maintain, - * even if the compute environment is DISABLED. - * - * @default 0 - */ - readonly minvCpus?: number; - /** - * The EC2 placement group to associate with your compute resources. - * If you intend to submit multi-node parallel jobs to this Compute Environment, - * you should consider creating a cluster placement group and associate it with your compute resources. - * This keeps your multi-node parallel job on a logical grouping of instances - * within a single Availability Zone with high network flow potential. - * - * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html - * - * @default - no placement group - */ - readonly placementGroup?: ec2.IPlacementGroup; - /** - * Add an instance type to this compute environment - */ - addInstanceType(instanceType: ec2.InstanceType): void; - /** - * Add an instance class to this compute environment - */ - addInstanceClass(instanceClass: ec2.InstanceClass): void; -} -/** - * Base interface for containing all information needed to - * configure a MachineImage in Batch - */ -interface MachineImage { - /** - * The machine image to use - * - * @default - chosen by batch - */ - readonly image?: ec2.IMachineImage; -} -/** - * A Batch MachineImage that is compatible with ECS - */ -export interface EcsMachineImage extends MachineImage { - /** - * Tells Batch which instance type to launch this image on - * - * @default - 'ECS_AL2' for non-gpu instances, 'ECS_AL2_NVIDIA' for gpu instances - */ - readonly imageType?: EcsMachineImageType; -} -/** - * A Batch MachineImage that is compatible with EKS - */ -export interface EksMachineImage extends MachineImage { - /** - * Tells Batch which instance type to launch this image on - * - * @default - 'EKS_AL2' for non-gpu instances, 'EKS_AL2_NVIDIA' for gpu instances - */ - readonly imageType?: EksMachineImageType; -} -/** - * Maps the image to instance types - */ -export declare enum EcsMachineImageType { - /** - * Tells Batch that this machine image runs on non-GPU instances - */ - ECS_AL2 = "ECS_AL2", - /** - * Tells Batch that this machine image runs on GPU instances - */ - ECS_AL2_NVIDIA = "ECS_AL2_NVIDIA" -} -/** - * Maps the image to instance types - */ -export declare enum EksMachineImageType { - /** - * Tells Batch that this machine image runs on non-GPU instances - */ - EKS_AL2 = "EKS_AL2", - /** - * Tells Batch that this machine image runs on GPU instances - */ - EKS_AL2_NVIDIA = "EKS_AL2_NVIDIA" -} -/** - * Determines how this compute environment chooses instances to spawn - * - * @see https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/ - */ -export declare enum AllocationStrategy { - /** - * Batch chooses the lowest-cost instance type that fits all the jobs in the queue. - * If instances of that type are not available, the queue will not choose a new type; - * instead, it will wait for the instance to become available. - * This can stall your `Queue`, with your compute environment only using part of its max capacity - * (or none at all) until the `BEST_FIT` instance becomes available. - * This allocation strategy keeps costs lower but can limit scaling. - * `BEST_FIT` isn't supported when updating compute environments - */ - BEST_FIT = "BEST_FIT", - /** - * This is the default Allocation Strategy if `spot` is `false` or unspecified. - * This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements - * of the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`. - * However, if not all of the capacity can be filled with this instance type, - * it will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity. - * To make the most use of this allocation strategy, - * it is recommended to use as many instance classes as is feasible for your workload. - */ - BEST_FIT_PROGRESSIVE = "BEST_FIT_PROGRESSIVE", - /** - * If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` - * and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled). - * This will tell Batch to choose the instance types from the ones you’ve specified that have - * the most spot capacity available to minimize the chance of interruption. - * To get the most benefit from your spot instances, - * you should allow Batch to choose from as many different instance types as possible. - */ - SPOT_CAPACITY_OPTIMIZED = "SPOT_CAPACITY_OPTIMIZED", - /** - * The price and capacity optimized allocation strategy looks at both price and capacity - * to select the Spot Instance pools that are the least likely to be interrupted - * and have the lowest possible price. - * - * The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances. - */ - SPOT_PRICE_CAPACITY_OPTIMIZED = "SPOT_PRICE_CAPACITY_OPTIMIZED" -} -/** - * Props for a ManagedEc2EcsComputeEnvironment - */ -export interface ManagedEc2EcsComputeEnvironmentProps extends ManagedComputeEnvironmentProps { - /** - * Whether or not to use batch's optimal instance type. - * The optimal instance type is equivalent to adding the - * C4, M4, and R4 instance classes. You can specify other instance classes - * (of the same architecture) in addition to the optimal instance classes. - * - * @default true - */ - readonly useOptimalInstanceClasses?: boolean; - /** - * Configure which AMIs this Compute Environment can launch. - * If you specify this property with only `image` specified, then the - * `imageType` will default to `ECS_AL2`. *If your image needs GPU resources, - * specify `ECS_AL2_NVIDIA`; otherwise, the instances will not be able to properly - * join the ComputeEnvironment*. - * - * @default - * - ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances - */ - readonly images?: EcsMachineImage[]; - /** - * The allocation strategy to use if not enough instances of - * the best fitting instance type can be allocated. - * - * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, - * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. - */ - readonly allocationStrategy?: AllocationStrategy; - /** - * The maximum percentage that a Spot Instance price can be when compared with the - * On-Demand price for that instance type before instances are launched. - * For example, if your maximum percentage is 20%, the Spot price must be - * less than 20% of the current On-Demand price for that Instance. - * You always pay the lowest market price and never more than your maximum percentage. - * For most use cases, Batch recommends leaving this field empty. - * - * Implies `spot == true` if set - * - * @default 100% - */ - readonly spotBidPercentage?: number; - /** - * The service-linked role that Spot Fleet needs to launch instances on your behalf. - * - * @see https://docs.aws.amazon.com/batch/latest/userguide/spot_fleet_IAM_role.html - * - * @default - a new role will be created - */ - readonly spotFleetRole?: iam.IRole; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - * - * @default - the instances Batch considers will be used (currently C4, M4, and R4) - */ - readonly instanceTypes?: ec2.InstanceType[]; - /** - * The instance classes that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - * Batch will automatically choose the instance size. - * - * @default - the instances Batch considers will be used (currently C4, M4, and R4) - */ - readonly instanceClasses?: ec2.InstanceClass[]; - /** - * The execution Role that instances launched by this Compute Environment will use. - * - * @default - a role will be created - */ - readonly instanceRole?: iam.IRole; - /** - * The Launch Template that this Compute Environment - * will use to provision EC2 Instances. - * - * *Note*: if `securityGroups` is specified on both your - * launch template and this Compute Environment, **the - * `securityGroup`s on the Compute Environment override the - * ones on the launch template. - * - * @default no launch template - */ - readonly launchTemplate?: ec2.ILaunchTemplate; - /** - * The minimum vCPUs that an environment should maintain, - * even if the compute environment is DISABLED. - * - * @default 0 - */ - readonly minvCpus?: number; - /** - * The EC2 placement group to associate with your compute resources. - * If you intend to submit multi-node parallel jobs to this Compute Environment, - * you should consider creating a cluster placement group and associate it with your compute resources. - * This keeps your multi-node parallel job on a logical grouping of instances - * within a single Availability Zone with high network flow potential. - * - * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html - * - * @default - no placement group - */ - readonly placementGroup?: ec2.IPlacementGroup; -} -/** - * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -export declare class ManagedEc2EcsComputeEnvironment extends ManagedComputeEnvironmentBase implements IManagedEc2EcsComputeEnvironment { - /** - * refer to an existing ComputeEnvironment by its arn. - */ - static fromManagedEc2EcsComputeEnvironmentArn(scope: Construct, id: string, managedEc2EcsComputeEnvironmentArn: string): IManagedEc2EcsComputeEnvironment; - readonly computeEnvironmentArn: string; - readonly computeEnvironmentName: string; - readonly images?: EcsMachineImage[]; - readonly allocationStrategy?: AllocationStrategy; - readonly spotBidPercentage?: number; - readonly spotFleetRole?: iam.IRole; - readonly instanceTypes: ec2.InstanceType[]; - readonly instanceClasses: ec2.InstanceClass[]; - readonly instanceRole?: iam.IRole; - readonly launchTemplate?: ec2.ILaunchTemplate; - readonly minvCpus?: number; - readonly placementGroup?: ec2.IPlacementGroup; - private readonly instanceProfile; - constructor(scope: Construct, id: string, props: ManagedEc2EcsComputeEnvironmentProps); - addInstanceType(instanceType: ec2.InstanceType): void; - addInstanceClass(instanceClass: ec2.InstanceClass): void; -} -/** - * A ManagedComputeEnvironment that uses EKS orchestration on EC2 instances. - */ -interface IManagedEc2EksComputeEnvironment extends IManagedComputeEnvironment { - /** - * The namespace of the Cluster - * - * Cannot be 'default', start with 'kube-', or be longer than 64 characters. - * - * @see https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ - */ - readonly kubernetesNamespace?: string; - /** - * The cluster that backs this Compute Environment. Required - * for Compute Environments running Kubernetes jobs. - * - * Please ensure that you have followed the steps at - * - * https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html - * - * before attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster. - * If you do not follow the steps in the link, the deployment fail with a message that the - * compute environment did not stabilize. - */ - readonly eksCluster: eks.ICluster; - /** - * Configure which AMIs this Compute Environment can launch. - * - * @default - * EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances, - */ - readonly images?: EksMachineImage[]; - /** - * The allocation strategy to use if not enough instances of - * the best fitting instance type can be allocated. - * - * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, - * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. - */ - readonly allocationStrategy?: AllocationStrategy; - /** - * The maximum percentage that a Spot Instance price can be when compared with the - * On-Demand price for that instance type before instances are launched. - * For example, if your maximum percentage is 20%, the Spot price must be - * less than 20% of the current On-Demand price for that Instance. - * You always pay the lowest market price and never more than your maximum percentage. - * For most use cases, Batch recommends leaving this field empty. - * - * Implies `spot == true` if set - * - * @default - 100% - */ - readonly spotBidPercentage?: number; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - */ - readonly instanceTypes: ec2.InstanceType[]; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - */ - readonly instanceClasses: ec2.InstanceClass[]; - /** - * The execution Role that instances launched by this Compute Environment will use. - * - * @default - a role will be created - */ - readonly instanceRole?: iam.IRole; - /** - * The Launch Template that this Compute Environment - * will use to provision EC2 Instances. - * - * *Note*: if `securityGroups` is specified on both your - * launch template and this Compute Environment, **the - * `securityGroup`s on the Compute Environment override the - * ones on the launch template. - * - * @default - no launch template - */ - readonly launchTemplate?: ec2.ILaunchTemplate; - /** - * The minimum vCPUs that an environment should maintain, - * even if the compute environment is DISABLED. - * - * @default 0 - */ - readonly minvCpus?: number; - /** - * The EC2 placement group to associate with your compute resources. - * If you intend to submit multi-node parallel jobs to this Compute Environment, - * you should consider creating a cluster placement group and associate it with your compute resources. - * This keeps your multi-node parallel job on a logical grouping of instances - * within a single Availability Zone with high network flow potential. - * - * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html - * - * @default - no placement group - */ - readonly placementGroup?: ec2.IPlacementGroup; - /** - * Add an instance type to this compute environment - */ - addInstanceType(instanceType: ec2.InstanceType): void; - /** - * Add an instance class to this compute environment - */ - addInstanceClass(instanceClass: ec2.InstanceClass): void; -} -/** - * Props for a ManagedEc2EksComputeEnvironment - */ -export interface ManagedEc2EksComputeEnvironmentProps extends ManagedComputeEnvironmentProps { - /** - * The namespace of the Cluster - */ - readonly kubernetesNamespace: string; - /** - * The cluster that backs this Compute Environment. Required - * for Compute Environments running Kubernetes jobs. - * - * Please ensure that you have followed the steps at - * - * https://docs.aws.amazon.com/batch/latest/userguide/getting-started-eks.html - * - * before attempting to deploy a `ManagedEc2EksComputeEnvironment` that uses this cluster. - * If you do not follow the steps in the link, the deployment fail with a message that the - * compute environment did not stabilize. - */ - readonly eksCluster: eks.ICluster; - /** - * Whether or not to use batch's optimal instance type. - * The optimal instance type is equivalent to adding the - * C4, M4, and R4 instance classes. You can specify other instance classes - * (of the same architecture) in addition to the optimal instance classes. - * - * @default true - */ - readonly useOptimalInstanceClasses?: boolean; - /** - * Configure which AMIs this Compute Environment can launch. - * - * @default - * If `imageKubernetesVersion` is specified, - * - EKS_AL2 for non-GPU instances, EKS_AL2_NVIDIA for GPU instances, - * Otherwise, - * - ECS_AL2 for non-GPU instances, ECS_AL2_NVIDIA for GPU instances, - */ - readonly images?: EksMachineImage[]; - /** - * The allocation strategy to use if not enough instances of - * the best fitting instance type can be allocated. - * - * @default - `BEST_FIT_PROGRESSIVE` if not using Spot instances, - * `SPOT_CAPACITY_OPTIMIZED` if using Spot instances. - */ - readonly allocationStrategy?: AllocationStrategy; - /** - * The maximum percentage that a Spot Instance price can be when compared with the - * On-Demand price for that instance type before instances are launched. - * For example, if your maximum percentage is 20%, the Spot price must be - * less than 20% of the current On-Demand price for that Instance. - * You always pay the lowest market price and never more than your maximum percentage. - * For most use cases, Batch recommends leaving this field empty. - * - * Implies `spot == true` if set - * - * @default - 100% - */ - readonly spotBidPercentage?: number; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - * - * @default - the instances Batch considers will be used (currently C4, M4, and R4) - */ - readonly instanceTypes?: ec2.InstanceType[]; - /** - * The instance types that this Compute Environment can launch. - * Which one is chosen depends on the `AllocationStrategy` used. - * Batch will automatically choose the instance size. - * - * @default - the instances Batch considers will be used (currently C4, M4, and R4) - */ - readonly instanceClasses?: ec2.InstanceClass[]; - /** - * The execution Role that instances launched by this Compute Environment will use. - * - * @default - a role will be created - */ - readonly instanceRole?: iam.IRole; - /** - * The Launch Template that this Compute Environment - * will use to provision EC2 Instances. - * - * *Note*: if `securityGroups` is specified on both your - * launch template and this Compute Environment, **the - * `securityGroup`s on the Compute Environment override the - * ones on the launch template.** - * - * @default - no launch template - */ - readonly launchTemplate?: ec2.ILaunchTemplate; - /** - * The minimum vCPUs that an environment should maintain, - * even if the compute environment is DISABLED. - * - * @default 0 - */ - readonly minvCpus?: number; - /** - * The EC2 placement group to associate with your compute resources. - * If you intend to submit multi-node parallel jobs to this Compute Environment, - * you should consider creating a cluster placement group and associate it with your compute resources. - * This keeps your multi-node parallel job on a logical grouping of instances - * within a single Availability Zone with high network flow potential. - * - * @see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html - * - * @default - no placement group - */ - readonly placementGroup?: ec2.IPlacementGroup; -} -/** - * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -export declare class ManagedEc2EksComputeEnvironment extends ManagedComputeEnvironmentBase implements IManagedEc2EksComputeEnvironment { - readonly kubernetesNamespace?: string; - readonly eksCluster: eks.ICluster; - readonly computeEnvironmentName: string; - readonly computeEnvironmentArn: string; - readonly images?: EksMachineImage[]; - readonly allocationStrategy?: AllocationStrategy; - readonly spotBidPercentage?: number; - readonly instanceTypes: ec2.InstanceType[]; - readonly instanceClasses: ec2.InstanceClass[]; - readonly instanceRole?: iam.IRole; - readonly launchTemplate?: ec2.ILaunchTemplate; - readonly minvCpus?: number; - readonly placementGroup?: ec2.IPlacementGroup; - private readonly instanceProfile; - constructor(scope: Construct, id: string, props: ManagedEc2EksComputeEnvironmentProps); - addInstanceType(instanceType: ec2.InstanceType): void; - addInstanceClass(instanceClass: ec2.InstanceClass): void; -} -/** - * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. - */ -export interface IFargateComputeEnvironment extends IManagedComputeEnvironment { -} -/** - * Props for a FargateComputeEnvironment - */ -export interface FargateComputeEnvironmentProps extends ManagedComputeEnvironmentProps { -} -/** - * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -export declare class FargateComputeEnvironment extends ManagedComputeEnvironmentBase implements IFargateComputeEnvironment { - /** - * Reference an existing FargateComputeEnvironment by its arn - */ - static fromFargateComputeEnvironmentArn(scope: Construct, id: string, fargateComputeEnvironmentArn: string): IFargateComputeEnvironment; - readonly computeEnvironmentName: string; - readonly computeEnvironmentArn: string; - constructor(scope: Construct, id: string, props: FargateComputeEnvironmentProps); -} -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js deleted file mode 100644 index 378fcc005e21b..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/managed-compute-environment.js +++ /dev/null @@ -1,451 +0,0 @@ -"use strict"; -var _a, _b, _c; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.FargateComputeEnvironment = exports.ManagedEc2EksComputeEnvironment = exports.ManagedEc2EcsComputeEnvironment = exports.AllocationStrategy = exports.EksMachineImageType = exports.EcsMachineImageType = exports.ManagedComputeEnvironmentBase = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const iam = require("aws-cdk-lib/aws-iam"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -const compute_environment_base_1 = require("./compute-environment-base"); -/** - * Abstract base class for ManagedComputeEnvironments - * @internal - */ -class ManagedComputeEnvironmentBase extends compute_environment_base_1.ComputeEnvironmentBase { - constructor(scope, id, props) { - super(scope, id, props); - this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); - this.maxvCpus = props.maxvCpus ?? DEFAULT_MAX_VCPUS; - this.replaceComputeEnvironment = props.replaceComputeEnvironment ?? false; - this.spot = props.spot; - this.updateTimeout = props.updateTimeout; - this.terminateOnUpdate = props.terminateOnUpdate; - this.updateToLatestImageVersion = props.updateToLatestImageVersion ?? true; - this.securityGroups = props.securityGroups ?? [ - new ec2.SecurityGroup(this, 'SecurityGroup', { - vpc: props.vpc, - }), - ]; - this.connections = new ec2.Connections({ - securityGroups: this.securityGroups, - }); - } -} -exports.ManagedComputeEnvironmentBase = ManagedComputeEnvironmentBase; -/** - * Maps the image to instance types - */ -var EcsMachineImageType; -(function (EcsMachineImageType) { - /** - * Tells Batch that this machine image runs on non-GPU instances - */ - EcsMachineImageType["ECS_AL2"] = "ECS_AL2"; - /** - * Tells Batch that this machine image runs on GPU instances - */ - EcsMachineImageType["ECS_AL2_NVIDIA"] = "ECS_AL2_NVIDIA"; -})(EcsMachineImageType || (exports.EcsMachineImageType = EcsMachineImageType = {})); -/** - * Maps the image to instance types - */ -var EksMachineImageType; -(function (EksMachineImageType) { - /** - * Tells Batch that this machine image runs on non-GPU instances - */ - EksMachineImageType["EKS_AL2"] = "EKS_AL2"; - /** - * Tells Batch that this machine image runs on GPU instances - */ - EksMachineImageType["EKS_AL2_NVIDIA"] = "EKS_AL2_NVIDIA"; -})(EksMachineImageType || (exports.EksMachineImageType = EksMachineImageType = {})); -/** - * Determines how this compute environment chooses instances to spawn - * - * @see https://aws.amazon.com/blogs/compute/optimizing-for-cost-availability-and-throughput-by-selecting-your-aws-batch-allocation-strategy/ - */ -var AllocationStrategy; -(function (AllocationStrategy) { - /** - * Batch chooses the lowest-cost instance type that fits all the jobs in the queue. - * If instances of that type are not available, the queue will not choose a new type; - * instead, it will wait for the instance to become available. - * This can stall your `Queue`, with your compute environment only using part of its max capacity - * (or none at all) until the `BEST_FIT` instance becomes available. - * This allocation strategy keeps costs lower but can limit scaling. - * `BEST_FIT` isn't supported when updating compute environments - */ - AllocationStrategy["BEST_FIT"] = "BEST_FIT"; - /** - * This is the default Allocation Strategy if `spot` is `false` or unspecified. - * This strategy will examine the Jobs in the queue and choose whichever instance type meets the requirements - * of the jobs in the queue and with the lowest cost per vCPU, just as `BEST_FIT`. - * However, if not all of the capacity can be filled with this instance type, - * it will choose a new next-best instance type to run any jobs that couldn’t fit into the `BEST_FIT` capacity. - * To make the most use of this allocation strategy, - * it is recommended to use as many instance classes as is feasible for your workload. - */ - AllocationStrategy["BEST_FIT_PROGRESSIVE"] = "BEST_FIT_PROGRESSIVE"; - /** - * If your workflow tolerates interruptions, you should enable `spot` on your `ComputeEnvironment` - * and use `SPOT_CAPACITY_OPTIMIZED` (this is the default if `spot` is enabled). - * This will tell Batch to choose the instance types from the ones you’ve specified that have - * the most spot capacity available to minimize the chance of interruption. - * To get the most benefit from your spot instances, - * you should allow Batch to choose from as many different instance types as possible. - */ - AllocationStrategy["SPOT_CAPACITY_OPTIMIZED"] = "SPOT_CAPACITY_OPTIMIZED"; - /** - * The price and capacity optimized allocation strategy looks at both price and capacity - * to select the Spot Instance pools that are the least likely to be interrupted - * and have the lowest possible price. - * - * The Batch team recommends this over `SPOT_CAPACITY_OPTIMIZED` in most instances. - */ - AllocationStrategy["SPOT_PRICE_CAPACITY_OPTIMIZED"] = "SPOT_PRICE_CAPACITY_OPTIMIZED"; -})(AllocationStrategy || (exports.AllocationStrategy = AllocationStrategy = {})); -/** - * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -class ManagedEc2EcsComputeEnvironment extends ManagedComputeEnvironmentBase { - /** - * refer to an existing ComputeEnvironment by its arn. - */ - static fromManagedEc2EcsComputeEnvironmentArn(scope, id, managedEc2EcsComputeEnvironmentArn) { - const stack = core_1.Stack.of(scope); - const computeEnvironmentName = stack.splitArn(managedEc2EcsComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - class Import extends core_1.Resource { - constructor() { - super(...arguments); - this.computeEnvironmentArn = managedEc2EcsComputeEnvironmentArn; - this.computeEnvironmentName = computeEnvironmentName; - this.enabled = true; - this.instanceClasses = []; - this.instanceTypes = []; - this.maxvCpus = 1; - this.connections = {}; - this.securityGroups = []; - this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); - } - addInstanceClass(_instanceClass) { - throw new Error(`cannot add instance class to imported ComputeEnvironment '${id}'`); - } - addInstanceType(_instanceType) { - throw new Error(`cannot add instance type to imported ComputeEnvironment '${id}'`); - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_ManagedEc2EcsComputeEnvironmentProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, ManagedEc2EcsComputeEnvironment); - } - throw error; - } - this.images = props.images; - this.allocationStrategy = determineAllocationStrategy(id, props.allocationStrategy, this.spot); - this.spotBidPercentage = props.spotBidPercentage; - this.spotFleetRole = props.spotFleetRole ?? (this.spot && this.allocationStrategy === AllocationStrategy.BEST_FIT - ? createSpotFleetRole(this) - : undefined); - this.instanceTypes = props.instanceTypes ?? []; - this.instanceClasses = props.instanceClasses ?? []; - const { instanceRole, instanceProfile } = createInstanceRoleAndProfile(this, props.instanceRole); - this.instanceRole = instanceRole; - this.instanceProfile = instanceProfile; - this.launchTemplate = props.launchTemplate; - this.minvCpus = props.minvCpus ?? DEFAULT_MIN_VCPUS; - this.placementGroup = props.placementGroup; - validateVCpus(id, this.minvCpus, this.maxvCpus); - validateSpotConfig(id, this.spot, this.spotBidPercentage, this.spotFleetRole); - const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); - const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { - ...baseManagedResourceProperties(this, subnetIds), - computeEnvironmentName: props.computeEnvironmentName, - computeResources: { - ...baseManagedResourceProperties(this, subnetIds).computeResources, - minvCpus: this.minvCpus, - instanceRole: this.instanceProfile.attrArn, - instanceTypes: core_1.Lazy.list({ - produce: () => renderInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses), - }), - type: this.spot ? 'SPOT' : 'EC2', - spotIamFleetRole: this.spotFleetRole?.roleArn, - allocationStrategy: this.allocationStrategy, - bidPercentage: this.spotBidPercentage, - launchTemplate: this.launchTemplate ? { - launchTemplateId: this.launchTemplate?.launchTemplateId, - } : undefined, - ec2Configuration: this.images?.map((image) => { - return { - imageIdOverride: image.image?.getImage(this).imageId, - imageType: image.imageType ?? EcsMachineImageType.ECS_AL2, - }; - }), - placementGroup: this.placementGroup?.placementGroupName, - tags: this.tags.renderedTags, - }, - }); - this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); - this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { - service: 'batch', - resource: 'compute-environment', - resourceName: this.physicalName, - }); - this.node.addValidation({ validate: () => validateInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }); - } - addInstanceType(instanceType) { - this.instanceTypes.push(instanceType); - } - addInstanceClass(instanceClass) { - this.instanceClasses.push(instanceClass); - } -} -exports.ManagedEc2EcsComputeEnvironment = ManagedEc2EcsComputeEnvironment; -_a = JSII_RTTI_SYMBOL_1; -ManagedEc2EcsComputeEnvironment[_a] = { fqn: "@aws-cdk/aws-batch-alpha.ManagedEc2EcsComputeEnvironment", version: "0.0.0" }; -/** - * A ManagedComputeEnvironment that uses ECS orchestration on EC2 instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -class ManagedEc2EksComputeEnvironment extends ManagedComputeEnvironmentBase { - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_ManagedEc2EksComputeEnvironmentProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, ManagedEc2EksComputeEnvironment); - } - throw error; - } - this.kubernetesNamespace = props.kubernetesNamespace; - this.eksCluster = props.eksCluster; - this.images = props.images; - this.allocationStrategy = determineAllocationStrategy(id, props.allocationStrategy, this.spot); - if (this.allocationStrategy === AllocationStrategy.BEST_FIT) { - throw new Error(`ManagedEc2EksComputeEnvironment '${id}' uses invalid allocation strategy 'AllocationStrategy.BEST_FIT'`); - } - this.spotBidPercentage = props.spotBidPercentage; - this.instanceTypes = props.instanceTypes ?? []; - this.instanceClasses = props.instanceClasses ?? []; - const { instanceRole, instanceProfile } = createInstanceRoleAndProfile(this, props.instanceRole); - this.instanceRole = instanceRole; - this.instanceProfile = instanceProfile; - this.launchTemplate = props.launchTemplate; - this.minvCpus = props.minvCpus ?? DEFAULT_MIN_VCPUS; - this.placementGroup = props.placementGroup; - validateVCpus(id, this.minvCpus, this.maxvCpus); - validateSpotConfig(id, this.spot, this.spotBidPercentage); - const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); - const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { - ...baseManagedResourceProperties(this, subnetIds), - computeEnvironmentName: props.computeEnvironmentName, - eksConfiguration: { - eksClusterArn: this.eksCluster.clusterArn, - kubernetesNamespace: this.kubernetesNamespace, - }, - computeResources: { - ...baseManagedResourceProperties(this, subnetIds).computeResources, - minvCpus: this.minvCpus, - instanceRole: this.instanceProfile.attrArn, - instanceTypes: core_1.Lazy.list({ produce: () => renderInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }), - type: this.spot ? 'SPOT' : 'EC2', - allocationStrategy: this.allocationStrategy, - bidPercentage: this.spotBidPercentage, - launchTemplate: this.launchTemplate ? { - launchTemplateId: this.launchTemplate?.launchTemplateId, - } : undefined, - ec2Configuration: this.images?.map((image) => { - return { - imageIdOverride: image.image?.getImage(this).imageId, - imageType: image.imageType ?? EksMachineImageType.EKS_AL2, - }; - }), - placementGroup: this.placementGroup?.placementGroupName, - tags: this.tags.renderedTags, - }, - }); - this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); - this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { - service: 'batch', - resource: 'compute-environment', - resourceName: this.physicalName, - }); - this.node.addValidation({ validate: () => validateInstances(this.instanceTypes, this.instanceClasses, props.useOptimalInstanceClasses) }); - } - addInstanceType(instanceType) { - this.instanceTypes.push(instanceType); - } - addInstanceClass(instanceClass) { - this.instanceClasses.push(instanceClass); - } -} -exports.ManagedEc2EksComputeEnvironment = ManagedEc2EksComputeEnvironment; -_b = JSII_RTTI_SYMBOL_1; -ManagedEc2EksComputeEnvironment[_b] = { fqn: "@aws-cdk/aws-batch-alpha.ManagedEc2EksComputeEnvironment", version: "0.0.0" }; -/** - * A ManagedComputeEnvironment that uses ECS orchestration on Fargate instances. - * - * @resource AWS::Batch::ComputeEnvironment - */ -class FargateComputeEnvironment extends ManagedComputeEnvironmentBase { - /** - * Reference an existing FargateComputeEnvironment by its arn - */ - static fromFargateComputeEnvironmentArn(scope, id, fargateComputeEnvironmentArn) { - const stack = core_1.Stack.of(scope); - const computeEnvironmentName = stack.splitArn(fargateComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - class Import extends core_1.Resource { - constructor() { - super(...arguments); - this.computeEnvironmentArn = fargateComputeEnvironmentArn; - this.computeEnvironmentName = computeEnvironmentName; - this.enabled = true; - this.maxvCpus = 1; - this.connections = {}; - this.securityGroups = []; - this.tags = new core_1.TagManager(core_1.TagType.MAP, 'AWS::Batch::ComputeEnvironment'); - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_FargateComputeEnvironmentProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, FargateComputeEnvironment); - } - throw error; - } - const { subnetIds } = props.vpc.selectSubnets(props.vpcSubnets); - const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { - ...baseManagedResourceProperties(this, subnetIds), - computeEnvironmentName: props.computeEnvironmentName, - computeResources: { - ...baseManagedResourceProperties(this, subnetIds).computeResources, - type: this.spot ? 'FARGATE_SPOT' : 'FARGATE', - }, - }); - this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); - this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { - service: 'batch', - resource: 'compute-environment', - resourceName: this.physicalName, - }); - } -} -exports.FargateComputeEnvironment = FargateComputeEnvironment; -_c = JSII_RTTI_SYMBOL_1; -FargateComputeEnvironment[_c] = { fqn: "@aws-cdk/aws-batch-alpha.FargateComputeEnvironment", version: "0.0.0" }; -function renderInstances(types, classes, useOptimalInstanceClasses) { - const instances = []; - for (const instanceType of types ?? []) { - instances.push(instanceType.toString()); - } - for (const instanceClass of classes ?? []) { - instances.push(instanceClass); - } - if (useOptimalInstanceClasses || useOptimalInstanceClasses === undefined) { - instances.push('optimal'); - } - return instances; -} -function createInstanceRoleAndProfile(scope, instanceRole) { - const result = {}; - result.instanceRole = instanceRole ?? new iam.Role(scope, 'InstanceProfileRole', { - assumedBy: new iam.ServicePrincipal('ec2.amazonaws.com'), - managedPolicies: [iam.ManagedPolicy.fromAwsManagedPolicyName('service-role/AmazonEC2ContainerServiceforEC2Role')], - }); - result.instanceProfile = new iam.CfnInstanceProfile(scope, 'InstanceProfile', { - roles: [result.instanceRole.roleName], - }); - return result; -} -function createSpotFleetRole(scope) { - return new iam.Role(scope, 'SpotFleetRole', { - assumedBy: new iam.ServicePrincipal('spotfleet.amazonaws.com'), - }); -} -function determineAllocationStrategy(id, allocationStrategy, spot) { - let result = allocationStrategy; - if (!allocationStrategy) { - result = spot ? AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED : AllocationStrategy.BEST_FIT_PROGRESSIVE; - } - else if (allocationStrategy === AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED && !spot) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED' without using spot instances`); - } - else if (allocationStrategy === AllocationStrategy.SPOT_CAPACITY_OPTIMIZED && !spot) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'AllocationStrategy.SPOT_CAPACITY_OPTIMIZED' without using spot instances`); - } - return result; -} -function validateInstances(types, classes, useOptimalInstanceClasses) { - if (renderInstances(types, classes, useOptimalInstanceClasses).length === 0) { - return ["Specifies 'useOptimalInstanceClasses: false' without specifying any instance types or classes"]; - } - return []; -} -function validateSpotConfig(id, spot, spotBidPercentage, spotFleetRole) { - if (spotBidPercentage) { - if (!spot) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' without specifying 'spot'`); - } - else if (spotBidPercentage > 100) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' > 100`); - } - else if (spotBidPercentage < 0) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotBidPercentage' < 0`); - } - } - if (spotFleetRole) { - if (!spot) { - throw new Error(`Managed ComputeEnvironment '${id}' specifies 'spotFleetRole' without specifying 'spot'`); - } - } -} -function validateVCpus(id, minvCpus, maxvCpus) { - if (minvCpus < 0) { - throw new Error(`Managed ComputeEnvironment '${id}' has 'minvCpus' = ${minvCpus} < 0; 'minvCpus' cannot be less than zero`); - } - if (minvCpus > maxvCpus) { - throw new Error(`Managed ComputeEnvironment '${id}' has 'minvCpus' = ${minvCpus} > 'maxvCpus' = ${maxvCpus}; 'minvCpus' cannot be greater than 'maxvCpus'`); - } -} -function baseManagedResourceProperties(baseComputeEnvironment, subnetIds) { - return { - serviceRole: baseComputeEnvironment.serviceRole?.roleArn, - state: baseComputeEnvironment.enabled ? 'ENABLED' : 'DISABLED', - computeResources: { - maxvCpus: baseComputeEnvironment.maxvCpus, - type: 'managed', - updateToLatestImageVersion: baseComputeEnvironment.updateToLatestImageVersion, - securityGroupIds: baseComputeEnvironment.securityGroups.map((securityGroup) => securityGroup.securityGroupId), - subnets: subnetIds, - }, - updatePolicy: { - terminateJobsOnUpdate: baseComputeEnvironment.terminateOnUpdate, - jobExecutionTimeoutMinutes: baseComputeEnvironment.updateTimeout?.toMinutes(), - }, - replaceComputeEnvironment: baseComputeEnvironment.replaceComputeEnvironment, - type: 'managed', - }; -} -const DEFAULT_MIN_VCPUS = 0; -const DEFAULT_MAX_VCPUS = 256; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LmpzIiwic291cmNlUm9vdCI6IiIsIn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TID0gMjU2O1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts deleted file mode 100644 index 460a7d679e9eb..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.d.ts +++ /dev/null @@ -1,107 +0,0 @@ -import * as ec2 from 'aws-cdk-lib/aws-ec2'; -import { Construct } from 'constructs'; -import { IEcsContainerDefinition } from './ecs-container-definition'; -import { IJobDefinition, JobDefinitionBase, JobDefinitionProps } from './job-definition-base'; -interface IMultiNodeJobDefinition extends IJobDefinition { - /** - * The containers that this multinode job will run. - * - * @see https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/ - */ - readonly containers: MultiNodeContainer[]; - /** - * The instance type that this job definition will run - */ - readonly instanceType: ec2.InstanceType; - /** - * The index of the main node in this job. - * The main node is responsible for orchestration. - * - * @default 0 - */ - readonly mainNode?: number; - /** - * Whether to propogate tags from the JobDefinition - * to the ECS task that Batch spawns - * - * @default false - */ - readonly propagateTags?: boolean; - /** - * Add a container to this multinode job - */ - addContainer(container: MultiNodeContainer): void; -} -/** - * Runs the container on nodes [startNode, endNode] - */ -export interface MultiNodeContainer { - /** - * The index of the first node to run this container - * - * The container is run on all nodes in the range [startNode, endNode] (inclusive) - */ - readonly startNode: number; - /** - * The index of the last node to run this container. - * - * The container is run on all nodes in the range [startNode, endNode] (inclusive) - */ - readonly endNode: number; - /** - * The container that this node range will run - */ - readonly container: IEcsContainerDefinition; -} -/** - * Props to configure a MultiNodeJobDefinition - */ -export interface MultiNodeJobDefinitionProps extends JobDefinitionProps { - /** - * The instance type that this job definition - * will run. - */ - readonly instanceType: ec2.InstanceType; - /** - * The containers that this multinode job will run. - * - * @see https://aws.amazon.com/blogs/compute/building-a-tightly-coupled-molecular-dynamics-workflow-with-multi-node-parallel-jobs-in-aws-batch/ - * - * @default none - */ - readonly containers?: MultiNodeContainer[]; - /** - * The index of the main node in this job. - * The main node is responsible for orchestration. - * - * @default 0 - */ - readonly mainNode?: number; - /** - * Whether to propogate tags from the JobDefinition - * to the ECS task that Batch spawns - * - * @default false - */ - readonly propagateTags?: boolean; -} -/** - * A JobDefinition that uses Ecs orchestration to run multiple containers - * - * @resource AWS::Batch::JobDefinition - */ -export declare class MultiNodeJobDefinition extends JobDefinitionBase implements IMultiNodeJobDefinition { - /** - * refer to an existing JobDefinition by its arn - */ - static fromJobDefinitionArn(scope: Construct, id: string, jobDefinitionArn: string): IJobDefinition; - readonly containers: MultiNodeContainer[]; - readonly instanceType: ec2.InstanceType; - readonly mainNode?: number; - readonly propagateTags?: boolean; - readonly jobDefinitionArn: string; - readonly jobDefinitionName: string; - constructor(scope: Construct, id: string, props: MultiNodeJobDefinitionProps); - addContainer(container: MultiNodeContainer): void; -} -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js deleted file mode 100644 index dac94633d7c25..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/multinode-job-definition.js +++ /dev/null @@ -1,104 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.MultiNodeJobDefinition = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -const ecs_job_definition_1 = require("./ecs-job-definition"); -const job_definition_base_1 = require("./job-definition-base"); -/** - * A JobDefinition that uses Ecs orchestration to run multiple containers - * - * @resource AWS::Batch::JobDefinition - */ -class MultiNodeJobDefinition extends job_definition_base_1.JobDefinitionBase { - /** - * refer to an existing JobDefinition by its arn - */ - static fromJobDefinitionArn(scope, id, jobDefinitionArn) { - const stack = core_1.Stack.of(scope); - const jobDefinitionName = stack.splitArn(jobDefinitionArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - class Import extends job_definition_base_1.JobDefinitionBase { - constructor() { - super(...arguments); - this.jobDefinitionArn = jobDefinitionArn; - this.jobDefinitionName = jobDefinitionName; - this.enabled = true; - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_MultiNodeJobDefinitionProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, MultiNodeJobDefinition); - } - throw error; - } - this.containers = props.containers ?? []; - this.mainNode = props.mainNode; - this.instanceType = props.instanceType; - this.propagateTags = props?.propagateTags; - const resource = new aws_batch_1.CfnJobDefinition(this, 'Resource', { - ...(0, job_definition_base_1.baseJobDefinitionProperties)(this), - type: 'multinode', - jobDefinitionName: props.jobDefinitionName, - propagateTags: this.propagateTags, - nodeProperties: { - mainNode: this.mainNode ?? 0, - nodeRangeProperties: core_1.Lazy.any({ - produce: () => this.containers.map((container) => ({ - targetNodes: container.startNode + ':' + container.endNode, - container: { - ...container.container._renderContainerDefinition(), - instanceType: this.instanceType.toString(), - }, - })), - }), - numNodes: core_1.Lazy.number({ - produce: () => computeNumNodes(this.containers), - }), - }, - platformCapabilities: [ecs_job_definition_1.Compatibility.EC2], - }); - this.jobDefinitionArn = this.getResourceArnAttribute(resource.ref, { - service: 'batch', - resource: 'job-definition', - resourceName: this.physicalName, - }); - this.jobDefinitionName = this.getResourceNameAttribute(resource.ref); - this.node.addValidation({ validate: () => validateContainers(this.containers) }); - } - addContainer(container) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_MultiNodeContainer(container); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addContainer); - } - throw error; - } - this.containers.push(container); - } -} -exports.MultiNodeJobDefinition = MultiNodeJobDefinition; -_a = JSII_RTTI_SYMBOL_1; -MultiNodeJobDefinition[_a] = { fqn: "@aws-cdk/aws-batch-alpha.MultiNodeJobDefinition", version: "0.0.0" }; -function computeNumNodes(containers) { - let result = 0; - for (const container of containers) { - result += container.endNode - container.startNode + 1; - } - return result; -} -function validateContainers(containers) { - return containers.length === 0 ? ['multinode job has no containers!'] : []; -} -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7OztBQUNBLDJDQUEwRDtBQUUxRCxxREFBeUQ7QUFFekQsNkRBQXFEO0FBQ3JELCtEQUEySDtBQWlHM0g7Ozs7R0FJRztBQUNILE1BQWEsc0JBQXVCLFNBQVEsdUNBQWlCO0lBQzNEOztPQUVHO0lBQ0ksTUFBTSxDQUFDLG9CQUFvQixDQUFDLEtBQWdCLEVBQUUsRUFBVSxFQUFFLGdCQUF3QjtRQUN2RixNQUFNLEtBQUssR0FBRyxZQUFLLENBQUMsRUFBRSxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQzlCLE1BQU0saUJBQWlCLEdBQUcsS0FBSyxDQUFDLFFBQVEsQ0FBQyxnQkFBZ0IsRUFBRSxnQkFBUyxDQUFDLG1CQUFtQixDQUFDLENBQUMsWUFBYSxDQUFDO1FBRXhHLE1BQU0sTUFBTyxTQUFRLHVDQUFpQjtZQUF0Qzs7Z0JBQ2tCLHFCQUFnQixHQUFHLGdCQUFnQixDQUFDO2dCQUNwQyxzQkFBaUIsR0FBRyxpQkFBaUIsQ0FBQztnQkFDdEMsWUFBTyxHQUFHLElBQUksQ0FBQztZQUNqQyxDQUFDO1NBQUE7UUFFRCxPQUFPLElBQUksTUFBTSxDQUFDLEtBQUssRUFBRSxFQUFFLENB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9PiB2YWxpZGF0ZUNvbnRhaW5lcnModGhpcy5jb250YWluZXJzKSB9KTtcbiAgfVxuXG4gIHB1YmxpYyBhZGRDb250YWluZXIoY29udGFpbmVyOiBNdWx0aU5vZGVDb250YWluZXIpIHtcbiAgICB0aGlzLmNvbnRhaW5lcnMucHVzaChjb250YWluZXIpO1xuICB9XG59XG5cbmZ1bmN0aW9uIGNvbXB1dGVOdW1Ob2Rlcyhjb250YWluZXJzOiBNdWx0aU5vZGVDb250YWluZXJbXSkge1xuICBsZXQgcmVzdWx0ID0gMDtcblxuICBmb3IgKGNvbnN0IGNvbnRhaW5lciBvZiBjb250YWluZXJzKSB7XG4gICAgcmVzdWx0ICs9IGNvbnRhaW5lci5lbmROb2RlIC0gY29udGFpbmVyLnN0YXJ0Tm9kZSArIDE7XG4gIH1cblxuICByZXR1cm4gcmVzdWx0O1xufVxuXG5mdW5jdGlvbiB2YWxpZGF0ZUNvbnRhaW5lcnMoY29udGFpbmVyczogTXVsdGlOb2RlQ29udGFpbmVyW10pOiBzdHJpbmdbXSB7XG4gIHJldHVybiBjb250YWluZXJzLmxlbmd0aCA9PT0gMCA/IFsnbXVsdGlub2RlIGpvYiBoYXMgbm8gY29udGFpbmVycyEnXSA6IFtdO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts deleted file mode 100644 index 1359eddcba414..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.d.ts +++ /dev/null @@ -1,188 +0,0 @@ -import { Duration, IResource, Resource } from 'aws-cdk-lib/core'; -import { Construct } from 'constructs'; -/** - * Represents a Scheduling Policy. Scheduling Policies tell the Batch - * Job Scheduler how to schedule incoming jobs. - */ -export interface ISchedulingPolicy extends IResource { - /** - * The name of this scheduling policy - * - * @attribute - */ - readonly schedulingPolicyName: string; - /** - * The arn of this scheduling policy - * - * @attribute - */ - readonly schedulingPolicyArn: string; -} -/** - * Props to configure a SchedulingPolicy - */ -interface SchedulingPolicyProps { - /** - * The name of this SchedulingPolicy - * - * @default - generated by CloudFormation - */ - readonly schedulingPolicyName?: string; -} -/** - * @internal - */ -export declare abstract class SchedulingPolicyBase extends Resource implements ISchedulingPolicy { - abstract readonly schedulingPolicyName: string; - abstract readonly schedulingPolicyArn: string; - constructor(scope: Construct, id: string, props?: SchedulingPolicyProps); -} -/** - * Represents a group of Job Definitions. All Job Definitions that - * declare a share identifier will be considered members of the Share - * defined by that share identifier. - * - * The Scheduler divides the maximum available vCPUs of the ComputeEnvironment - * among Jobs in the Queue based on their shareIdentifier and the weightFactor - * associated with that shareIdentifier. - */ -export interface Share { - /** - * The identifier of this Share. All jobs that specify this share identifier - * when submitted to the queue will be considered as part of this Share. - */ - readonly shareIdentifier: string; - /** - * The weight factor given to this Share. The Scheduler decides which jobs to put in the Compute Environment - * such that the following ratio is equal for each job: - * - * `sharevCpu / weightFactor`, - * - * where `sharevCpu` is the total amount of vCPU given to that particular share; that is, - * the sum of the vCPU of each job currently in the Compute Environment for that share. - * - * See the readme of this module for a detailed example that shows how these are used, - * how it relates to `computeReservation`, and how `shareDecay` affects these calculations. - */ - readonly weightFactor: number; -} -/** - * Represents a Fairshare Scheduling Policy. Instructs the scheduler - * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. - * - * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. - * It does this by deciding how many Jobs of each share to schedule *relative to how many jobs of - * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with - * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of - * fairshare policies. - */ -export interface IFairshareSchedulingPolicy extends ISchedulingPolicy { - /** - * Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue. - * - * The percentage reserved is defined by the Scheduler as: - * `(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers. - * - * For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the - * maximum available vCPU if there's only one fair share identifier. - * It reserves 25% if there are two fair share identifiers. - * It reserves 12.5% if there are three fair share identifiers. - * - * A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the - * maximum available vCPU if there's only one fair share identifier, - * 6.25% if there are two fair share identifiers, - * and 1.56% if there are three fair share identifiers. - * - * @default - no vCPU is reserved - */ - readonly computeReservation?: number; - /** - * The amount of time to use to measure the usage of each job. - * The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue. - * A value of zero (0) indicates that only current usage is measured. - * The decay is linear and gives preference to newer jobs. - * - * The maximum supported value is 604800 seconds (1 week). - * - * @default - 0: only the current job usage is considered - */ - readonly shareDecay?: Duration; - /** - * The shares that this Scheduling Policy applies to. - * *Note*: It is possible to submit Jobs to the queue with Share Identifiers that - * are not recognized by the Scheduling Policy. - */ - readonly shares: Share[]; -} -/** - * Fairshare SchedulingPolicy configuration - */ -export interface FairshareSchedulingPolicyProps extends SchedulingPolicyProps { - /** - * Used to calculate the percentage of the maximum available vCPU to reserve for share identifiers not present in the Queue. - * - * The percentage reserved is defined by the Scheduler as: - * `(computeReservation/100)^ActiveFairShares` where `ActiveFairShares` is the number of active fair share identifiers. - * - * For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the - * maximum available vCPU if there's only one fair share identifier. - * It reserves 25% if there are two fair share identifiers. - * It reserves 12.5% if there are three fair share identifiers. - * - * A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the - * maximum available vCPU if there's only one fair share identifier, - * 6.25% if there are two fair share identifiers, - * and 1.56% if there are three fair share identifiers. - * - * @default - no vCPU is reserved - */ - readonly computeReservation?: number; - /** - * The amount of time to use to measure the usage of each job. - * The usage is used to calculate a fair share percentage for each fair share identifier currently in the Queue. - * A value of zero (0) indicates that only current usage is measured. - * The decay is linear and gives preference to newer jobs. - * - * The maximum supported value is 604800 seconds (1 week). - * - * @default - 0: only the current job usage is considered - */ - readonly shareDecay?: Duration; - /** - * The shares that this Scheduling Policy applies to. - * *Note*: It is possible to submit Jobs to the queue with Share Identifiers that - * are not recognized by the Scheduling Policy. - * - * @default - no shares - */ - readonly shares?: Share[]; -} -/** - * Represents a Fairshare Scheduling Policy. Instructs the scheduler - * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. - * - * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. - * The scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of - * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with - * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of - * fairshare policies. - * - * @resource AWS::Batch::SchedulingPolicy - */ -export declare class FairshareSchedulingPolicy extends SchedulingPolicyBase implements IFairshareSchedulingPolicy { - /** - * Reference an exisiting Scheduling Policy by its ARN - */ - static fromFairshareSchedulingPolicyArn(scope: Construct, id: string, fairshareSchedulingPolicyArn: string): IFairshareSchedulingPolicy; - readonly computeReservation?: number; - readonly shareDecay?: Duration; - readonly shares: Share[]; - readonly schedulingPolicyArn: string; - readonly schedulingPolicyName: string; - constructor(scope: Construct, id: string, props?: FairshareSchedulingPolicyProps); - /** - * Add a share this to this Fairshare SchedulingPolicy - */ - addShare(share: Share): void; -} -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js b/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js deleted file mode 100644 index 927263fa715f3..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/scheduling-policy.js +++ /dev/null @@ -1,101 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.FairshareSchedulingPolicy = exports.SchedulingPolicyBase = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -/** - * @internal - */ -class SchedulingPolicyBase extends core_1.Resource { - constructor(scope, id, props) { - super(scope, id, { - physicalName: props?.schedulingPolicyName, - }); - } -} -exports.SchedulingPolicyBase = SchedulingPolicyBase; -/** - * Represents a Fairshare Scheduling Policy. Instructs the scheduler - * to allocate ComputeEnvironment vCPUs based on Job shareIdentifiers. - * - * The Faireshare Scheduling Policy ensures that each share gets a certain amount of vCPUs. - * The scheduler does this by deciding how many Jobs of each share to schedule *relative to how many jobs of - * each share are currently being executed by the ComputeEnvironment*. The weight factors associated with - * each share determine the ratio of vCPUs allocated; see the readme for a more in-depth discussion of - * fairshare policies. - * - * @resource AWS::Batch::SchedulingPolicy - */ -class FairshareSchedulingPolicy extends SchedulingPolicyBase { - /** - * Reference an exisiting Scheduling Policy by its ARN - */ - static fromFairshareSchedulingPolicyArn(scope, id, fairshareSchedulingPolicyArn) { - const stack = core_1.Stack.of(scope); - class Import extends SchedulingPolicyBase { - constructor() { - super(...arguments); - this.schedulingPolicyArn = fairshareSchedulingPolicyArn; - this.schedulingPolicyName = stack.splitArn(fairshareSchedulingPolicyArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - this.shares = []; - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_FairshareSchedulingPolicyProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, FairshareSchedulingPolicy); - } - throw error; - } - this.computeReservation = props?.computeReservation; - this.shareDecay = props?.shareDecay; - this.shares = props?.shares ?? []; - const resource = new aws_batch_1.CfnSchedulingPolicy(this, 'Resource', { - fairsharePolicy: { - computeReservation: this.computeReservation, - shareDecaySeconds: this.shareDecay?.toSeconds(), - shareDistribution: core_1.Lazy.any({ - produce: () => this.shares?.map((share) => ({ - shareIdentifier: share.shareIdentifier, - weightFactor: share.weightFactor, - })), - }), - }, - name: props?.schedulingPolicyName, - }); - this.schedulingPolicyArn = this.getResourceArnAttribute(resource.attrArn, { - service: 'batch', - resource: 'scheduling-policy', - resourceName: this.physicalName, - }); - this.schedulingPolicyName = this.getResourceNameAttribute(resource.ref); - } - /** - * Add a share this to this Fairshare SchedulingPolicy - */ - addShare(share) { - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_Share(share); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, this.addShare); - } - throw error; - } - this.shares.push(share); - } -} -exports.FairshareSchedulingPolicy = FairshareSchedulingPolicy; -_a = JSII_RTTI_SYMBOL_1; -FairshareSchedulingPolicy[_a] = { fqn: "@aws-cdk/aws-batch-alpha.FairshareSchedulingPolicy", version: "0.0.0" }; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NoZWR1bGluZy1wb2xpY3kuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJzY2hlZHVsaW5nLXBvbGljeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSwyQ0FBeUY7QUFFekYscURBQTREO0FBa0M1RDs7R0FFRztBQUNILE1BQXNCLG9CQUFxQixTQUFRLGVBQVE7SUFJekQsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxLQUE2QjtRQUNyRSxLQUFLLENBQUMsS0FBSyxFQUFFLEVBQUUsRUFBRTtZQUNmLFlBQVksRUFBRSxLQUFLLEVBQUUsb0JBQW9CO1NBQzFDLENBQUMsQ0FBQztLQUNKO0NBQ0Y7QUFURCxvREFTQztBQWtJRDs7Ozs7Ozs7Ozs7R0FXRztBQUNILE1BQWEseUJBQTBCLFNBQVEsb0JBQW9CO0lBQ2pFOztPQUVHO0lBQ0ksTUFBTSxDQUFDLGdDQUFnQyxDQUFDLEtBQWdCLEVBQUUsRUFBVSxFQUFFLDRCQUFvQztRQUMvRyxNQUFNLEtBQUssR0FBRyxZQUFLLENBQUMsRUFBRSxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQzl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FyZUlkZW50aWZpZXIsXG4gICAgICAgICAgICB3ZWlnaHRGYWN0b3I6IHNoYXJlLndlaWdodEZhY3RvcixcbiAgICAgICAgICB9KSksXG4gICAgICAgIH0pLFxuICAgICAgfSxcbiAgICAgIG5hbWU6IHByb3BzPy5zY2hlZHVsaW5nUG9saWN5TmFtZSxcbiAgICB9KTtcblxuICAgIHRoaXMuc2NoZWR1bGluZ1BvbGljeUFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UuYXR0ckFybiwge1xuICAgICAgc2VydmljZTogJ2JhdGNoJyxcbiAgICAgIHJlc291cmNlOiAnc2NoZWR1bGluZy1wb2xpY3knLFxuICAgICAgcmVzb3VyY2VOYW1lOiB0aGlzLnBoeXNpY2FsTmFtZSxcbiAgICB9KTtcbiAgICB0aGlzLnNjaGVkdWxpbmdQb2xpY3lOYW1lID0gdGhpcy5nZXRSZXNvdXJjZU5hbWVBdHRyaWJ1dGUocmVzb3VyY2UucmVmKTtcbiAgfVxuXG4gIC8qKlxuICAgKiBBZGQgYSBzaGFyZSB0aGlzIHRvIHRoaXMgRmFpcnNoYXJlIFNjaGVkdWxpbmdQb2xpY3lcbiAgICovXG4gIHB1YmxpYyBhZGRTaGFyZShzaGFyZTogU2hhcmUpIHtcbiAgICB0aGlzLnNoYXJlcy5wdXNoKHNoYXJlKTtcbiAgfVxufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts deleted file mode 100644 index 80c8be1714cae..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.d.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { Construct } from 'constructs'; -import { IComputeEnvironment, ComputeEnvironmentBase, ComputeEnvironmentProps } from './compute-environment-base'; -/** - * Represents an UnmanagedComputeEnvironment. Batch will not provision instances on your behalf - * in this ComputeEvironment. - */ -export interface IUnmanagedComputeEnvironment extends IComputeEnvironment { - /** - * The vCPUs this Compute Environment provides. Used only by the - * scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s. - * - * **If this parameter is not provided on a fairshare queue, no capacity is reserved**; - * that is, the `FairshareSchedulingPolicy` is ignored. - */ - readonly unmanagedvCPUs?: number; -} -/** - * Represents an UnmanagedComputeEnvironment. Batch will not provision instances on your behalf - * in this ComputeEvironment. - */ -export interface UnmanagedComputeEnvironmentProps extends ComputeEnvironmentProps { - /** - * The vCPUs this Compute Environment provides. Used only by the - * scheduler to schedule jobs in `Queue`s that use `FairshareSchedulingPolicy`s. - * - * **If this parameter is not provided on a fairshare queue, no capacity is reserved**; - * that is, the `FairshareSchedulingPolicy` is ignored. - * - * @default 0 - */ - readonly unmanagedvCpus?: number; -} -/** - * Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf. - * - * @resource AWS::Batch::ComputeEnvironment - */ -export declare class UnmanagedComputeEnvironment extends ComputeEnvironmentBase implements IUnmanagedComputeEnvironment { - /** - * Import an UnmanagedComputeEnvironment by its arn - */ - static fromUnmanagedComputeEnvironmentArn(scope: Construct, id: string, unmanagedComputeEnvironmentArn: string): IUnmanagedComputeEnvironment; - readonly unmanagedvCPUs?: number | undefined; - readonly computeEnvironmentArn: string; - readonly computeEnvironmentName: string; - constructor(scope: Construct, id: string, props?: UnmanagedComputeEnvironmentProps); -} diff --git a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js deleted file mode 100644 index 3a7d3f74798bd..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/lib/unmanaged-compute-environment.js +++ /dev/null @@ -1,70 +0,0 @@ -"use strict"; -var _a; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.UnmanagedComputeEnvironment = void 0; -const jsiiDeprecationWarnings = require("../.warnings.jsii.js"); -const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const core_1 = require("aws-cdk-lib/core"); -const aws_batch_1 = require("aws-cdk-lib/aws-batch"); -const compute_environment_base_1 = require("./compute-environment-base"); -/** - * Unmanaged ComputeEnvironments do not provision or manage EC2 instances on your behalf. - * - * @resource AWS::Batch::ComputeEnvironment - */ -class UnmanagedComputeEnvironment extends compute_environment_base_1.ComputeEnvironmentBase { - /** - * Import an UnmanagedComputeEnvironment by its arn - */ - static fromUnmanagedComputeEnvironmentArn(scope, id, unmanagedComputeEnvironmentArn) { - const stack = core_1.Stack.of(scope); - const computeEnvironmentName = stack.splitArn(unmanagedComputeEnvironmentArn, core_1.ArnFormat.SLASH_RESOURCE_NAME).resourceName; - class Import extends compute_environment_base_1.ComputeEnvironmentBase { - constructor() { - super(...arguments); - this.computeEnvironmentArn = unmanagedComputeEnvironmentArn; - this.computeEnvironmentName = computeEnvironmentName; - this.enabled = true; - this.containerDefinition = {}; - } - } - return new Import(scope, id); - } - constructor(scope, id, props) { - super(scope, id, props); - try { - jsiiDeprecationWarnings._aws_cdk_aws_batch_alpha_UnmanagedComputeEnvironmentProps(props); - } - catch (error) { - if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") { - Error.captureStackTrace(error, UnmanagedComputeEnvironment); - } - throw error; - } - this.unmanagedvCPUs = props?.unmanagedvCpus; - const resource = new aws_batch_1.CfnComputeEnvironment(this, 'Resource', { - type: 'unmanaged', - state: this.enabled ? 'ENABLED' : 'DISABLED', - computeEnvironmentName: props?.computeEnvironmentName, - unmanagedvCpus: this.unmanagedvCPUs, - serviceRole: props?.serviceRole?.roleArn - ?? new aws_iam_1.Role(this, 'BatchServiceRole', { - managedPolicies: [ - aws_iam_1.ManagedPolicy.fromAwsManagedPolicyName('service-role/AWSBatchServiceRole'), - ], - assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), - }).roleArn, - }); - this.computeEnvironmentName = this.getResourceNameAttribute(resource.ref); - this.computeEnvironmentArn = this.getResourceArnAttribute(resource.attrComputeEnvironmentArn, { - service: 'batch', - resource: 'compute-environment', - resourceName: this.physicalName, - }); - } -} -exports.UnmanagedComputeEnvironment = UnmanagedComputeEnvironment; -_a = JSII_RTTI_SYMBOL_1; -UnmanagedComputeEnvironment[_a] = { fqn: "@aws-cdk/aws-batch-alpha.UnmanagedComputeEnvironment", version: "0.0.0" }; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidW5tYW5hZ2VkLWNvbXB1dGUtZW52aXJvbm1lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJ1bm1hbmFnZWQtY29tcHV0ZS1lbnZpcm9ubWVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSxpREFBNEU7QUFDNUUsMkNBQW9EO0FBRXBELHFEQUE4RDtBQUM5RCx5RUFBa0g7QUFrQ2xIOzs7O0dBSUc7QUFDSCxNQUFhLDJCQUE0QixTQUFRLGlEQUFzQjtJQUNyRTs7T0FFRztJQUNJLE1BQU0sQ0FBQyxrQ0FBa0MsQ0FDOUMsS0FBZ0IsRUFBRSxFQUFVLEVBQUUsOEJBQXNDO1FBRXBFLE1BQU0sS0FBSyxHQUFHLFlBQUssQ0FBQyxFQUFFLENBQUMsS0FBSyxDQUFDLENBQUM7UUFDOUIsTUFBTSxzQkFBc0IsR0FBRyxLQUFLLENBQUMsUUFBUSxDQUFDLDhCQUE4QixFQUFFLGdCQUFTLENBQUMsbUJBQW1CLENBQUMsQ0FBQyxZQUFhLENBQUM7UUFFM0gsTUFBTSxNQUFPLFNBQVEsaURBQXNCO1lBQTNDOztnQkFDa0IsMEJBQXFCLEdBQUcsOEJBQThCLENBQUM7Z0JBQ3ZELDJCQUFzQixHQUFHLHNCQUFzQixDQUFDO2dCQUNoRCxZQUFPLEdBQUcsSUFBSSxDQUFDO2dCQUNmLHdCQUFtQix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DogJ0RJU0FCTEVEJyxcbiAgICAgIGNvbXB1dGVFbnZpcm9ubWVudE5hbWU6IHByb3BzPy5jb21wdXRlRW52aXJvbm1lbnROYW1lLFxuICAgICAgdW5tYW5hZ2VkdkNwdXM6IHRoaXMudW5tYW5hZ2VkdkNQVXMsXG4gICAgICBzZXJ2aWNlUm9sZTogcHJvcHM/LnNlcnZpY2VSb2xlPy5yb2xlQXJuXG4gICAgICA/PyBuZXcgUm9sZSh0aGlzLCAnQmF0Y2hTZXJ2aWNlUm9sZScsIHtcbiAgICAgICAgbWFuYWdlZFBvbGljaWVzOiBbXG4gICAgICAgICAgTWFuYWdlZFBvbGljeS5mcm9tQXdzTWFuYWdlZFBvbGljeU5hbWUoJ3NlcnZpY2Utcm9sZS9BV1NCYXRjaFNlcnZpY2VSb2xlJyksXG4gICAgICAgIF0sXG4gICAgICAgIGFzc3VtZWRCeTogbmV3IFNlcnZpY2VQcmluY2lwYWwoJ2JhdGNoLmFtYXpvbmF3cy5jb20nKSxcbiAgICAgIH0pLnJvbGVBcm4sXG4gICAgfSk7XG4gICAgdGhpcy5jb21wdXRlRW52aXJvbm1lbnROYW1lID0gdGhpcy5nZXRSZXNvdXJjZU5hbWVBdHRyaWJ1dGUocmVzb3VyY2UucmVmKTtcbiAgICB0aGlzLmNvbXB1dGVFbnZpcm9ubWVudEFybiA9IHRoaXMuZ2V0UmVzb3VyY2VBcm5BdHRyaWJ1dGUocmVzb3VyY2UuYXR0ckNvbXB1dGVFbnZpcm9ubWVudEFybiwge1xuICAgICAgc2VydmljZTogJ2JhdGNoJyxcbiAgICAgIHJlc291cmNlOiAnY29tcHV0ZS1lbnZpcm9ubWVudCcsXG4gICAgICByZXNvdXJjZU5hbWU6IHRoaXMucGh5c2ljYWxOYW1lLFxuICAgIH0pO1xuICB9XG59XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js deleted file mode 100644 index 26f4d2b7fface..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-events-targets/batch.test.js +++ /dev/null @@ -1,294 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const batch = require("../../lib"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const assertions_1 = require("aws-cdk-lib/assertions"); -const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); -const events = require("aws-cdk-lib/aws-events"); -const targets = require("aws-cdk-lib/aws-events-targets"); -const sqs = require("aws-cdk-lib/aws-sqs"); -describe('Batch job event target', () => { - let stack; - let jobQueue; - let jobDefinition; - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - jobQueue = new batch.JobQueue(stack, 'MyQueue', { - computeEnvironments: [ - { - computeEnvironment: new batch.UnmanagedComputeEnvironment(stack, 'ComputeEnvironment'), - order: 1, - }, - ], - }); - jobDefinition = new batch.EcsJobDefinition(stack, 'MyJob', { - container: new batch.EcsEc2ContainerDefinition(stack, 'container', { - image: aws_ecs_1.ContainerImage.fromRegistry('test-repo'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - }); - test('use aws batch job as an event rule target', () => { - // GIVEN - const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 min)'), - }); - // WHEN - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition)); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { - ScheduleExpression: 'rate(1 min)', - State: 'ENABLED', - Targets: [ - { - Arn: { - 'Fn::GetAtt': [ - 'MyQueueE6CA6235', - 'JobQueueArn', - ], - }, - Id: 'Target0', - RoleArn: { - 'Fn::GetAtt': [ - 'MyJobEventsRoleCF43C336', - 'Arn', - ], - }, - BatchParameters: { - JobDefinition: { - Ref: 'MyJob8719E923', - }, - JobName: 'Rule', - }, - }, - ], - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [ - { - Action: 'batch:SubmitJob', - Effect: 'Allow', - Resource: [ - { Ref: 'MyJob8719E923' }, - { - 'Fn::GetAtt': [ - 'MyQueueE6CA6235', - 'JobQueueArn', - ], - }, - ], - }, - ], - Version: '2012-10-17', - }, - Roles: [ - { Ref: 'MyJobEventsRoleCF43C336' }, - ], - }); - }); - test('use a Dead Letter Queue for the rule target', () => { - // GIVEN - const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 hour)'), - }); - const queue = new sqs.Queue(stack, 'Queue'); - // WHEN - const eventInput = { - buildspecOverride: 'buildspecs/hourly.yml', - }; - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { - deadLetterQueue: queue, - event: events.RuleTargetInput.fromObject(eventInput), - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { - Targets: [ - { - Arn: { - 'Fn::GetAtt': [ - 'MyQueueE6CA6235', - 'JobQueueArn', - ], - }, - Id: 'Target0', - DeadLetterConfig: { - Arn: { - 'Fn::GetAtt': [ - 'Queue4A7E3555', - 'Arn', - ], - }, - }, - Input: JSON.stringify(eventInput), - RoleArn: { - 'Fn::GetAtt': ['MyJobEventsRoleCF43C336', 'Arn'], - }, - BatchParameters: { - JobDefinition: { - Ref: 'MyJob8719E923', - }, - JobName: 'Rule', - }, - }, - ], - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::SQS::QueuePolicy', { - PolicyDocument: { - Statement: [ - { - Action: 'sqs:SendMessage', - Condition: { - ArnEquals: { - 'aws:SourceArn': { - 'Fn::GetAtt': [ - 'Rule4C995B7F', - 'Arn', - ], - }, - }, - }, - Effect: 'Allow', - Principal: { - Service: 'events.amazonaws.com', - }, - Resource: { - 'Fn::GetAtt': [ - 'Queue4A7E3555', - 'Arn', - ], - }, - Sid: 'AllowEventRuleRule', - }, - ], - Version: '2012-10-17', - }, - Queues: [ - { - Ref: 'Queue4A7E3555', - }, - ], - }); - }); - test('specifying retry policy', () => { - // GIVEN - const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 hour)'), - }); - const queue = new sqs.Queue(stack, 'Queue'); - // WHEN - const eventInput = { - buildspecOverride: 'buildspecs/hourly.yml', - }; - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { - deadLetterQueue: queue, - event: events.RuleTargetInput.fromObject(eventInput), - retryAttempts: 2, - maxEventAge: aws_cdk_lib_1.Duration.hours(2), - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { - ScheduleExpression: 'rate(1 hour)', - State: 'ENABLED', - Targets: [ - { - Arn: { - 'Fn::GetAtt': [ - 'MyQueueE6CA6235', - 'JobQueueArn', - ], - }, - BatchParameters: { - JobDefinition: { - Ref: 'MyJob8719E923', - }, - JobName: 'Rule', - }, - DeadLetterConfig: { - Arn: { - 'Fn::GetAtt': [ - 'Queue4A7E3555', - 'Arn', - ], - }, - }, - Id: 'Target0', - Input: JSON.stringify(eventInput), - RetryPolicy: { - MaximumEventAgeInSeconds: 7200, - MaximumRetryAttempts: 2, - }, - RoleArn: { - 'Fn::GetAtt': [ - 'MyJobEventsRoleCF43C336', - 'Arn', - ], - }, - }, - ], - }); - }); - test('specifying retry policy with 0 retryAttempts', () => { - // GIVEN - const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 hour)'), - }); - // WHEN - const eventInput = { - buildspecOverride: 'buildspecs/hourly.yml', - }; - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { - event: events.RuleTargetInput.fromObject(eventInput), - retryAttempts: 0, - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Events::Rule', { - ScheduleExpression: 'rate(1 hour)', - State: 'ENABLED', - Targets: [ - { - Arn: { - 'Fn::GetAtt': [ - 'MyQueueE6CA6235', - 'JobQueueArn', - ], - }, - BatchParameters: { - JobDefinition: { - Ref: 'MyJob8719E923', - }, - JobName: 'Rule', - }, - Id: 'Target0', - Input: JSON.stringify(eventInput), - RetryPolicy: { - MaximumRetryAttempts: 0, - }, - RoleArn: { - 'Fn::GetAtt': [ - 'MyJobEventsRoleCF43C336', - 'Arn', - ], - }, - }, - ], - }); - }); - test('should validate jobName minimum and maximum length', () => { - const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 min)'), - }); - expect(() => { - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { - jobName: '', - })); - }).toThrowError(/must have length between 1 and 128/); - expect(() => { - rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition, { - jobName: 'a'.repeat(200), - })); - }).toThrowError(/must have length between 1 and 128/); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmF0Y2gudGVzdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImJhdGNoLnRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxtQ0FBbUM7QUFDbkMsNkNBQW9EO0FBQ3BELHVEQUFrRDtBQUNsRCxpREFBcUQ7QUFDckQsaURBQWlEO0FBQ2pELDBEQUEwRDtBQUMxRCwyQ0FBMkM7QUFFM0MsUUFBUSx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hdGUoMSBtaW4pJyxcbiAgICAgIFN0YXRlOiAnRU5BQkxFRCcsXG4gICAgICBUYXJnZXRzOiBbXG4gICAgICAgIHtcbiAgICAgICAgICBBcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlRdWV1ZUU2Q0E2MjM1JyxcbiAgICAgICAgICAgICAgJ0pvYlF1ZXVlQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJZDogJ1RhcmdldDAnLFxuICAgICAgICAgIFJvbGVBcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlKb2JFdmVudHNSb2xlQ0Y0M0MzMzYnLFxuICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBCYXRjaFBhcmFtZXRlcnM6IHtcbiAgICAgICAgICAgIEpvYkRlZmluaXRpb246IHtcbiAgICAgICAgICAgICAgUmVmOiAnTXlKb2I4NzE5RTkyMycsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgSm9iTmFtZTogJ1J1bGUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIH0sXG4gICAgICBdLFxuICAgIH0pO1xuXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6SUFNOjpQb2xpY3knLCB7XG4gICAgICBQb2xpY3lEb2N1bWVudDoge1xuICAgICAgICBTdGF0ZW1lbnQ6IFtcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdiYXRjaDpTdWJtaXRKb2InLFxuICAgICAgICAgICAgRWZmZWN0OiAnQWxsb3cnLFxuICAgICAgICAgICAgUmVzb3VyY2U6IFtcbiAgICAgICAgICAgICAgeyBSZWY6ICdNeUpvYjg3MTlFOTIzJyB9LFxuICAgICAgICAgICAgICB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XR0ZXJRdWV1ZTogcXVldWUsXG4gICAgICAgIGV2ZW50OiBldmVudHMuUnVsZVRhcmdldElucHV0LmZyb21PYmplY3QoZXZlbnRJbnB1dCksXG4gICAgICB9LFxuICAgICkpO1xuXG4gICAgLy8gVEhFTlxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkV2ZW50czo6UnVsZScsIHtcbiAgICAgIFRhcmdldHM6IFtcbiAgICAgICAge1xuICAgICAgICAgIEFybjoge1xuICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICdNeVF1ZXVlRTZDQTYyMzUnLFxuICAgICAgICAgICAgICAnSm9iUXVldWVBcm4nLFxuICAgICAgICAgICAgXSxcbiAgICAgICAgICB9LFxuICAgICAgICAgIElkOiAnVGFyZ2V0MCcsXG4gICAgICAgICAgRGVhZExldHRlckNvbmZpZzoge1xuICAgICAgICAgICAgQXJuOiB7XG4gICAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAgICdRdWV1ZTRBN0UzNTU1JyxcbiAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJbnB1dDogSlNPTi5zdHJpbmdpZnkoZXZlbnRJbnB1dCksXG4gICAgICAgICAgUm9sZUFybjoge1xuICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbJ015Sm9iRXZlbnRzUm9sZUNGNDNDMzM2JywgJ0FybiddLFxuICAgICAgICAgIH0sXG4gICAgICAgICAgQmF0Y2hQYXJhbWV0ZXJzOiB7XG4gICAgICAgICAgICBKb2JEZWZpbml0aW9uOiB7XG4gICAgICAgICAgICAgIFJlZjogJ015Sm9iODcxOUU5MjMnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIEpvYk5hbWU6ICdSdWxlJyxcbiAgICAgICAgICB9LFxuICAgICAgICB9LFxuICAgICAgXSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OlNRUzo6UXVldWVQb2xpY3knLCB7XG4gICAgICBQb2xpY3lEb2N1bWVudDoge1xuICAgICAgICBTdGF0ZW1lbnQ6IFtcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdzcXM6U2VuZE1lc3NhZ2UnLFxuICAgICAgICAgICAgQ29uZGl0aW9uOiB7XG4gICAgICAgICAgICAgIEFybkVxdWFsczoge1xuICAgICAgICAgICAgICAgICdhd3M6U291cmNlQXJuJzoge1xuICAgICAgICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICAgICAgICdSdWxlNEM5OTVCN0YnLFxuICAgICAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBQcmluY2lwYWw6IHtcbiAgICAgICAgICAgICAgU2VydmljZTogJ2V2ZW50cy5hbWF6b25hd3MuY29tJyxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICAgICAnUXVldWU0QTdFMzU1NScsXG4gICAgICAgICAgICAgICAgJ0FybicsXG4gICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgU2lkOiAnQWxsb3dFdmVudFJ1bGVSdWxlJyxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgICB9LFxuICAgICAgUXVldWVzO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XUzo6RXZlbnRzOjpSdWxlJywge1xuICAgICAgU2NoZWR1bGVFeHByZXNzaW9uOiAncmF0ZSgxIGhvdXIpJyxcbiAgICAgIFN0YXRlOiAnRU5BQkxFRCcsXG4gICAgICBUYXJnZXRzOiBbXG4gICAgICAgIHtcbiAgICAgICAgICBBcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlRdWV1ZUU2Q0E2MjM1JyxcbiAgICAgICAgICAgICAgJ0pvYlF1ZXVlQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBCYXRjaFBhcmFtZXRlcnM6IHtcbiAgICAgICAgICAgIEpvYkRlZmluaXRpb246IHtcbiAgICAgICAgICAgICAgUmVmOiAnTXlKb2I4NzE5RTkyMycsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgSm9iTmFtZTogJ1J1bGUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAgRGVhZExldHRlckNvbmZpZzoge1xuICAgICAgICAgICAgQXJuOiB7XG4gICAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAgICdRdWV1ZTRBN0UzNTU1JyxcbiAgICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICBJZDogJ1RhcmdldDAnLFxuICAgICAgICAgIElucHV0OiBKU09OLnN0cmluZ2lmeShldmVudElucHV0KSxcbiAgICAgICAgICBSZXRyeVBvbGljeToge1xuICAgICAgICAgICAgTWF4aW11bUV2ZW50QWdlSW5TZWNvbmRzOiA3MjAwLFxuICAgICAgICAgICAgTWF4aW11bVJldHJ5QXR0ZW1wdHM6IDIsXG4gICAgICAgICAgfSxcbiAgICAgICAgICBSb2xlQXJuOiB7XG4gICAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICAgJ015Sm9iR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xuICAgICAgVGFyZ2V0czogW1xuICAgICAgICB7XG4gICAgICAgICAgQXJuOiB7XG4gICAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICAgJ015UXVldWVFNkNBNjIzNScsXG4gICAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIH0sXG4gICAgICAgICAgQmF0Y2hQYXJhbWV0ZXJzOiB7XG4gICAgICAgICAgICBKb2JEZWZpbml0aW9uOiB7XG4gICAgICAgICAgICAgIFJlZjogJ015Sm9iODcxOUU5MjMnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIEpvYk5hbWU6ICdSdWxlJyxcbiAgICAgICAgICB9LFxuICAgICAgICAgIElkOiAnVGFyZ2V0MCcsXG4gICAgICAgICAgSW5wdXQ6IEpTT04uc3RyaW5naWZ5KGV2ZW50SW5wdXQpLFxuICAgICAgICAgIFJldHJ5UG9saWN5OiB7XG4gICAgICAgICAgICBNYXhpbXVtUmV0cnlBdHRlbXB0czogMCxcbiAgICAgICAgICB9LFxuICAgICAgICAgIFJvbGVBcm46IHtcbiAgICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgICAnTXlKb2JFdmVudHNSb2xlQ0Y0M0MzMzYnLFxuICAgICAgICAgICAgICAnQXJuJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgfSxcbiAgICAgIF0sXG4gICAgfSk7XG4gIH0pO1xuXG4gIHRlc3QoJ3Nob3VsZCB2YWxpZGF0ZSBqb2JOYW1lIG1pbmltdW0gYW5kIG1heGltdW0gbGVuZ3RoJywgKCkgPT4ge1xuICAgIGNvbnN0IHJ1bGUgPSBuZXcgZXZlbnRzLlJ1bGUoc3RhY2ssICdSdWxlJywge1xuICAgICAgc2NoZWR1bGU6IGV2ZW50cy5TY2hlZHVsZS5leHByZXNzaW9uKCdyYXRlKDEgbWluKScpLFxuICAgIH0pO1xuXG4gICAgZXhwZWN0KCgpID0+IHtcbiAgICAgIHJ1bGUuYWRkVGFyZ2V0KFxuICAgICAgICBuZXcgdGFyZ2V0cy5CYXRjaEpvYihcbiAgICAgICAgICBqb2JRdWV1ZS5qb2JRdWV1ZUFybixcbiAgICAgICAgICBqb2JRdWV1ZSxcbiAgICAgICAgICBqb2JEZWZpbml0aW9uLmpvYkRlZmluaXRpb25Bcm4sXG4gICAgICAgICAgam9iRGVmaW5pdGlvbixcbiAgICAgICAgICB7XG4gICAgICAgICAgICBqb2JOYW1lOiAnJyxcbiAgICAgICAgICB9LFxuICAgICAgICApLFxuICAgICAgKTtcbiAgICB9KS50b1Rocm93RXJyb3IoL211c3QgaGF2ZSBsZW5ndGggYmV0d2VlbiAxIGFuZCAxMjgvKTtcbiAgICBleHBlY3QoKCkgPT4ge1xuICAgICAgcnVsZS5hZGRUYXJnZXQoXG4gICAgICAgIG5ldyB0YXJnZXRzLkJhdGNoSm9iKFxuICAgICAgICAgIGpvYlF1ZXVlLmpvYlF1ZXVlQXJuLFxuICAgICAgICAgIGpvYlF1ZXVlLFxuICAgICAgICAgIGpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgICAgICAgICBqb2JEZWZpbml0aW9uLFxuICAgICAgICAgIHtcbiAgICAgICAgICAgIGpvYk5hbWU6ICdhJy5yZXBlYXQoMjAwKSxcbiAgICAgICAgICB9LFxuICAgICAgICApLFxuICAgICAgKTtcbiAgICB9KS50b1Rocm93RXJyb3IoL211c3QgaGF2ZSBsZW5ndGggYmV0d2VlbiAxIGFuZCAxMjgvKTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js deleted file mode 100644 index 0ed0f7a77b1ed..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/run-batch-job.test.js +++ /dev/null @@ -1,286 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const path = require("path"); -const batch = require("../../lib"); -const cdk_build_tools_1 = require("@aws-cdk/cdk-build-tools"); -const cdk = require("aws-cdk-lib"); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const sfn = require("aws-cdk-lib/aws-stepfunctions"); -const tasks = require("aws-cdk-lib/aws-stepfunctions-tasks"); -let stack; -let batchJobDefinition; -let batchJobQueue; -beforeEach(() => { - // GIVEN - stack = new cdk.Stack(); - batchJobDefinition = new batch.EcsJobDefinition(stack, 'JobDefinition', { - container: new batch.EcsEc2ContainerDefinition(stack, 'Container', { - image: ecs.ContainerImage.fromAsset(path.join(__dirname, '../batchjob-image')), - cpu: 256, - memory: cdk.Size.mebibytes(2048), - }), - }); - batchJobQueue = new batch.JobQueue(stack, 'JobQueue', { - computeEnvironments: [ - { - order: 1, - computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(stack, 'ComputeEnv', { - vpc: new ec2.Vpc(stack, 'vpc'), - }), - }, - ], - }); -}); -(0, cdk_build_tools_1.describeDeprecated)('RunBatchJob', () => { - test('Task with only the required parameters', () => { - // WHEN - const task = new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - }), - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, - JobName: 'JobName', - JobQueue: { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - }, - }); - }); - test('Task with all the parameters', () => { - // WHEN - const task = new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 15, - containerOverrides: { - command: ['sudo', 'rm'], - environment: { key: 'value' }, - instanceType: new ec2.InstanceType('MULTI'), - memory: 1024, - gpuCount: 1, - vcpus: 10, - }, - dependsOn: [{ jobId: '1234', type: 'some_type' }], - payload: { - foo: sfn.JsonPath.stringAt('$.bar'), - }, - attempts: 3, - timeout: cdk.Duration.seconds(60), - integrationPattern: sfn.ServiceIntegrationPattern.FIRE_AND_FORGET, - }), - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob', - ], - ], - }, - End: true, - Parameters: { - JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, - JobName: 'JobName', - JobQueue: { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - ArrayProperties: { Size: 15 }, - ContainerOverrides: { - Command: ['sudo', 'rm'], - Environment: [{ Name: 'key', Value: 'value' }], - InstanceType: 'MULTI', - Memory: 1024, - ResourceRequirements: [{ Type: 'GPU', Value: '1' }], - Vcpus: 10, - }, - DependsOn: [{ JobId: '1234', Type: 'some_type' }], - Parameters: { 'foo.$': '$.bar' }, - RetryStrategy: { Attempts: 3 }, - Timeout: { AttemptDurationSeconds: 60 }, - }, - }); - }); - test('supports tokens', () => { - // WHEN - const task = new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobQueueArn: batchJobQueue.jobQueueArn, - jobName: sfn.JsonPath.stringAt('$.jobName'), - arraySize: sfn.JsonPath.numberAt('$.arraySize'), - timeout: cdk.Duration.seconds(sfn.JsonPath.numberAt('$.timeout')), - attempts: sfn.JsonPath.numberAt('$.attempts'), - }), - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, - 'JobName.$': '$.jobName', - 'JobQueue': { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - 'ArrayProperties': { - 'Size.$': '$.arraySize', - }, - 'RetryStrategy': { - 'Attempts.$': '$.attempts', - }, - 'Timeout': { - 'AttemptDurationSeconds.$': '$.timeout', - }, - }, - }); - }); - test('Task throws if WAIT_FOR_TASK_TOKEN is supplied as service integration pattern', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - integrationPattern: sfn.ServiceIntegrationPattern.WAIT_FOR_TASK_TOKEN, - }), - }); - }).toThrow(/Invalid Service Integration Pattern: WAIT_FOR_TASK_TOKEN is not supported to call RunBatchJob./i); - }); - test('Task throws if environment in containerOverrides contain env with name starting with AWS_BATCH', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - containerOverrides: { - environment: { AWS_BATCH_MY_NAME: 'MY_VALUE' }, - }, - }), - }); - }).toThrow(/Invalid environment variable name: AWS_BATCH_MY_NAME. Environment variable names starting with 'AWS_BATCH' are reserved./i); - }); - test('Task throws if arraySize is out of limits 2-10000', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 1, - }), - }); - }).toThrow(/arraySize must be between 2 and 10,000/); - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 10001, - }), - }); - }).toThrow(/arraySize must be between 2 and 10,000/); - }); - test('Task throws if dependencies exceeds 20', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - dependsOn: [...Array(21).keys()].map(i => ({ - jobId: `${i}`, - type: `some_type-${i}`, - })), - }), - }); - }).toThrow(/dependencies must be 20 or less/); - }); - test('Task throws if attempts is out of limits 1-10', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - attempts: 0, - }), - }); - }).toThrow(/attempts must be between 1 and 10/); - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - attempts: 11, - }), - }); - }).toThrow(/attempts must be between 1 and 10/); - }); - test('Task throws if timeout is less than 60 sec', () => { - expect(() => { - new sfn.Task(stack, 'Task', { - task: new tasks.RunBatchJob({ - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - timeout: cdk.Duration.seconds(59), - }), - }); - }).toThrow(/timeout must be greater than 60 seconds/); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicnVuLWJhdGNoLWpvYi50ZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsicnVuLWJhdGNoLWpvYi50ZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsNkJBQTZCO0FBQzdCLG1DQUFtQztBQUNuQyw4REFBOEQ7QUFDOUQsbUNBQW1DO0FBQ25DLDJDQUEyQztBQUMzQywyQ0FBMkM7QUFDM0MscURBQXFEO0FBQ3JELDZEQUE2RDtBQUU3RCxJQUFJLEtBQWdCLENBQUM7QUFDckIsSUFBSSxrQkFBd0MsQ0FBQztBQUM3QyxJQUFJLGFBQThCLENBQUM7QUFFbkMsVUFBVSxDQUFDLEdBQUcsRUFBRTtJQUNkLFFBQVE7SUFDUixLQUFLLEdBQUcsSUFBSSxHQUFHLENBQUMsS0FBSyxFQUFFLENBQUM7SUFFeEIsa0JBQWtCLEdBQUcsSUFBSSxLQUFLLENBQUMsZ0JBQWdCLENBQUMsS0FBSyxFQUFFLGVBQWUsRUFBRTtRQUN0RSxTQUFTLEVBQUUsSUFBSSxLQUFLLENBQUMseUJBQXlCLENBQUMsS0FBSyxFQUFFLFdBQVcsRUFBRTtZQUNqRSxLQUFLLEVBQUUsR0FBRyxDQUFDLGNBQWMsQ0FBQyxTQUFTLENBQ2pDLElBQUksQ0FBQyxJQUFJLENBQUMsU0FBUyxFQUFFLG1CQUFtQixDQUFDLENBQzFDO1lBQ0QsR0FBRyxFQUFFLEdBQUc7WUFDUixNQUFNLEVBQUUsR0FBRyxDQUFDLElBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDO1NBQ2pDLENBQUM7S0FDSCxDQUFDLENBQUM7SUFFSCxhQUFhLEdBQU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uICAgICAgVHlwZTogJ1Rhc2snLFxuICAgICAgUmVzb3VyY2U6IHtcbiAgICAgICAgJ0ZuOjpKb2luJzogW1xuICAgICAgICAgICcnLFxuICAgICAgICAgIFtcbiAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgUmVmOiAnQVdTOjpQYXJ0aXRpb24nLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICc6c3RhdGVzOjo6YmF0Y2g6c3VibWl0Sm9iLnN5bmMnLFxuICAgICAgICAgIF0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgICAgRW5kOiB0cnVlLFxuICAgICAgUGFyYW1ldGVyczoge1xuICAgICAgICBKb2JEZWZpbml0aW9uOiB7IFJlZjogJ0pvYkRlZmluaXRpb24yNEZGRTNFRCcgfSxcbiAgICAgICAgSm9iTmFtZTogJ0pvYk5hbWUnLFxuICAgICAgICBKb2JRdWV1ZToge1xuICAgICAgICAgICdGbjo6R2V0QXR0JzogW1xuICAgICAgICAgICAgJ0pvYlF1ZXVlRUUzQUQ0OTknLFxuICAgICAgICAgICAgJ0pvYlF1ZXVlQXJuJyxcbiAgICAgICAgICBdLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgnVGFzayB3aXRoIGFsbCB0aGUgcGFyYW1ldGVycycsICgpID0+IHtcbiAgLy8gV0hFTlxuICAgIGNvbnN0IHRhc2sgPSBuZXcgc2ZuLlRhc2soc3RhY2ssICdUYXNrJywge1xuICAgICAgdGFzazogbmV3IHRhc2tzLlJ1bkJhdGNoSm9iKHtcbiAgICAgICAgam9iRGVmaW5pdGlvbkFybjogYmF0Y2hKb2JEZWZpbml0aW9uLmpvYkRlZmluaXRpb25Bcm4sXG4gICAgICAgIGpvYk5hbWU6ICdKb2JOYW1lJyxcbiAgICAgICAgam9iUXVldWVBcm46IGJhdGNoSm9iUXVldWUuam9iUXVldWVBcm4sXG4gICAgICAgIGFycmF5U2l6ZTogMTUsXG4gICAgICAgIGNvbnRhaW5lck92ZXJyaWRlczoge1xuICAgICAgICAgIGNvbW1hbmQ6IFsnc3VkbycsICdybSddLFxuICAgICAgICAgIGVudmlyb25tZW50OiB7IGtleTogJ3ZhbHVlJyB9LFxuICAgICAgICAgIGluc3RhbmNlVHlwZTogbmV3IGVjMi5JbnN0YW5jZVR5cGUoJ01VTFRJJyksXG4gICAgICAgICAgbWVtb3J5OiAxMDI0LFxuICAgICAgICAgIGdwdUNvdW50OiAxLFxuICAgICAgICAgIHZjcHVzOiAxMCxcbiAgICAgICAgfSxcbiAgICAgICAgZGVwZW5kc09uOiBbeyBqb2JJZDogJzEyMzQnLCB0eXBlOiAnc29tZV90eXBlJyB9XSxcbiAgICAgICAgcGF5bG9hZDoge1xuICAgICAgICAgIGZvbzogc2ZuLkpzb25QYXRoLnN0cmluZ0F0KCckLmJhcicpLFxuICAgICAgICB9LFxuICAgICAgICBhdHRlbXB0czogMyxcbiAgICAgICAgdGltZW91dDogY2RrLkR1cmF0aW9uLnNlY29uZHMoNjApLFxuICAgICAgICBpbnRlZ3JhdGlvblBhdHRlcm46IHNmbi5TZXJ2aWNlSW50ZWdyYXRpb25QYXR0ZXJuLkZJUkVfQU5EX0ZPUkdFVCxcbiAgICAgIH0pLFxuICAgIH0pO1xuXG4gICAgLy8gVEhFTlxuICAgIGV4cGVjdChzdGFjay5yZXNvbHZlKHRhc2sudG9TdGF0ZUpzb24oKSkpLnRvRXF1YWwoe1xuICAgICAgVHlwZTogJ1Rhc2snLFxuICAgICAgUmVzb3VyY2U6IHtcbiAgICAgICAgJ0ZuOjpKb2luJzogW1xuICAgICAgICAgICcnLFxuICAgICAgICAgIFtcbiAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgUmVmOiAnQVdTOjpQYXJ0aXRpb24nLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICc6c3RhdGVzOjo6YmF0Y2g6c3VibWl0Sm9iJyxcbiAgICAgICAgICBdLFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICAgIEVuZDogdHJ1ZSxcbiAgICAgIFBhcmFtZXRlcnM6IHtcbiAgICAgICAgSm9iRGVmaW5pdGlvbjogeyBSZWY6ICdKb2JEZWZpbml0aW9uMjRGRkUzRUQnIH0sXG4gICAgICAgIEpvYk5hbWU6ICdKb2JOYW1lJyxcbiAgICAgICAgSm9iUXVldWU6IHtcbiAgICAgICAgICAnRm46OkdldEF0dCc6IFtcbiAgICAgICAgICAgICdKb2JRdWV1ZUVFM0FENDk5JyxcbiAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgXSxcbiAgICAgICAgfSxcbiAgICAgICAgQXJyYXlQcm9wZXJ0aWVzOiB7IFNpemU6IDE1IH0sXG4gICAgICAgIENvbnRhaW5lck92ZXJyaWRlczoge1xuICAgICAgICAgIENvbW1hbmQ6IFsnc3VkbycsICdybSddLFxuICAgICAgICAgIEVudmlyb25tZW50OiBbeyBOYW1lOiAna2V5JywgVmFsdWU6ICd2YWx1ZScgfV0sXG4gICAgICAgICAgSW5zdGFuY2VUeXBlOiAnTVVMVEknLFxuICAgICAgICAgIE1lbW9yeTogMTAyNCxcbiAgICAgICAgICBSZXNvdXJjZVJlcXVpcmVtZW50czogW3sgVHlwZTogJ0dQVScsIFZhbHVlOiAnMScgfV0sXG4gICAgICAgICAgVmNwdXM6IDEwLFxuICAgICAgICB9LFxuICAgICAgICBEZXBlbmRzT246IFt7IEpvYklkOiAnMTIzNCcsIFR5cGU6ICdzb21lX3R5cGUnIH1dLFxuICAgICAgICBQYXJhbWV0ZXJzOiB7ICdmb28uJCc6ICckLmJhcicgfSxcbiAgICAgICAgUmV0cnlTdHJhdGVneTogeyBBdHRlbXB0czogMyB9LFxuICAgICAgICBUaW1lb3V0OiB7IEF0dGVtcHREdXJhdGlvblNlY29uZHM6IDYwIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9K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m4sXG4gICAgICAgICAgam9iTmFtZTogJ0pvYk5hbWUnLFxuICAgICAgICAgIGpvYlF1ZXVlQXJuOiBiYXRjaEpvYlF1ZXVlLmpvYlF1ZXVlQXJuLFxuICAgICAgICAgIHRpbWVvdXQ6IGNkay5EdXJhdGlvbi5zZWNvbmRzKDU5KSxcbiAgICAgICAgfSksXG4gICAgICB9KTtcbiAgICB9KS50b1Rocm93KFxuICAgICAgL3RpbWVvdXQgbXVzdCBiZSBncmVhdGVyIHRoYW4gNjAgc2Vjb25kcy8sXG4gICAgKTtcbiAgfSk7XG59KTsiXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js b/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js deleted file mode 100644 index 8387351204073..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/aws-stepfunctions-tasks/submit-job.test.js +++ /dev/null @@ -1,401 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const path = require("path"); -const batch = require("../../lib"); -const cdk = require("aws-cdk-lib"); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const sfn = require("aws-cdk-lib/aws-stepfunctions"); -const aws_stepfunctions_tasks_1 = require("aws-cdk-lib/aws-stepfunctions-tasks"); -let stack; -let batchJobDefinition; -let batchJobQueue; -beforeEach(() => { - // GIVEN - stack = new cdk.Stack(); - batchJobDefinition = new batch.EcsJobDefinition(stack, 'JobDefinition', { - container: new batch.EcsEc2ContainerDefinition(stack, 'Container', { - image: ecs.ContainerImage.fromAsset(path.join(__dirname, '../batchjob-image')), - cpu: 256, - memory: cdk.Size.mebibytes(2048), - }), - }); - batchJobQueue = new batch.JobQueue(stack, 'JobQueue', { - computeEnvironments: [ - { - order: 1, - computeEnvironment: new batch.ManagedEc2EcsComputeEnvironment(stack, 'ComputeEnv', { - vpc: new ec2.Vpc(stack, 'vpc'), - }), - }, - ], - }); -}); -test('Task with only the required parameters', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, - JobName: 'JobName', - JobQueue: { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - }, - }); -}); -test('Task with all the parameters', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 15, - containerOverrides: { - command: ['sudo', 'rm'], - environment: { key: 'value' }, - instanceType: new ec2.InstanceType('MULTI'), - memory: cdk.Size.mebibytes(1024), - gpuCount: 1, - vcpus: 10, - }, - dependsOn: [{ jobId: '1234', type: 'some_type' }], - payload: sfn.TaskInput.fromObject({ - foo: sfn.JsonPath.stringAt('$.bar'), - }), - attempts: 3, - taskTimeout: sfn.Timeout.duration(cdk.Duration.seconds(60)), - integrationPattern: sfn.IntegrationPattern.REQUEST_RESPONSE, - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob', - ], - ], - }, - End: true, - Parameters: { - JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, - JobName: 'JobName', - JobQueue: { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - ArrayProperties: { Size: 15 }, - ContainerOverrides: { - Command: ['sudo', 'rm'], - Environment: [{ Name: 'key', Value: 'value' }], - InstanceType: 'MULTI', - ResourceRequirements: [{ Type: 'GPU', Value: '1' }, { Type: 'MEMORY', Value: '1024' }, { Type: 'VCPU', Value: '10' }], - }, - DependsOn: [{ JobId: '1234', Type: 'some_type' }], - Parameters: { 'foo.$': '$.bar' }, - RetryStrategy: { Attempts: 3 }, - Timeout: { AttemptDurationSeconds: 60 }, - }, - }); -}); -test('supports tokens', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobName: sfn.JsonPath.stringAt('$.jobName'), - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: sfn.JsonPath.numberAt('$.arraySize'), - taskTimeout: sfn.Timeout.at('$.timeout'), - attempts: sfn.JsonPath.numberAt('$.attempts'), - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, - 'JobName.$': '$.jobName', - 'JobQueue': { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - 'ArrayProperties': { - 'Size.$': '$.arraySize', - }, - 'RetryStrategy': { - 'Attempts.$': '$.attempts', - }, - 'Timeout': { - 'AttemptDurationSeconds.$': '$.timeout', - }, - }, - }); -}); -test('container overrides are tokens', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - containerOverrides: { - memory: cdk.Size.mebibytes(sfn.JsonPath.numberAt('$.asdf')), - }, - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { 'Fn::Join': ['', ['arn:', { Ref: 'AWS::Partition' }, ':states:::batch:submitJob.sync']] }, - End: true, - Parameters: { - JobDefinition: { Ref: 'JobDefinition24FFE3ED' }, - JobName: 'JobName', - JobQueue: { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - ContainerOverrides: { - ResourceRequirements: [{ 'Type': 'MEMORY', 'Value.$': '$.asdf' }], - }, - }, - }); -}); -test('supports passing task input into payload', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobQueueArn: batchJobQueue.jobQueueArn, - jobName: sfn.JsonPath.stringAt('$.jobName'), - payload: sfn.TaskInput.fromJsonPathAt('$.foo'), - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, - 'JobName.$': '$.jobName', - 'JobQueue': { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - 'Parameters.$': '$.foo', - }, - }); -}); -test('Task throws if WAIT_FOR_TASK_TOKEN is supplied as service integration pattern', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - integrationPattern: sfn.IntegrationPattern.WAIT_FOR_TASK_TOKEN, - }); - }).toThrow(/Unsupported service integration pattern. Supported Patterns: REQUEST_RESPONSE,RUN_JOB. Received: WAIT_FOR_TASK_TOKEN/); -}); -test('Task throws if environment in containerOverrides contain env with name starting with AWS_BATCH', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - containerOverrides: { - environment: { AWS_BATCH_MY_NAME: 'MY_VALUE' }, - }, - }); - }).toThrow(/Invalid environment variable name: AWS_BATCH_MY_NAME. Environment variable names starting with 'AWS_BATCH' are reserved./); -}); -test('Task throws if arraySize is out of limits 2-10000', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 1, - }); - }).toThrow(/arraySize must be between 2 and 10,000/); - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - arraySize: 10001, - }); - }).toThrow(/arraySize must be between 2 and 10,000/); -}); -test('Task throws if dependencies exceeds 20', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - dependsOn: [...Array(21).keys()].map(i => ({ - jobId: `${i}`, - type: `some_type-${i}`, - })), - }); - }).toThrow(/dependencies must be 20 or less/); -}); -test('Task throws if attempts is out of limits 1-10', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - attempts: 0, - }); - }).toThrow(/attempts must be between 1 and 10/); - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - attempts: 11, - }); - }).toThrow(/attempts must be between 1 and 10/); -}); -test('Task throws if attempt duration is less than 60 sec', () => { - expect(() => { - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - taskTimeout: sfn.Timeout.duration(cdk.Duration.seconds(59)), - }); - }).toThrow(/attempt duration must be greater than 60 seconds./); -}); -test('supports passing tags', () => { - // WHEN - const task = new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobQueueArn: batchJobQueue.jobQueueArn, - jobName: sfn.JsonPath.stringAt('$.jobName'), - tags: { - test: 'this is a tag', - }, - }); - // THEN - expect(stack.resolve(task.toStateJson())).toEqual({ - Type: 'Task', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':states:::batch:submitJob.sync', - ], - ], - }, - End: true, - Parameters: { - 'JobDefinition': { Ref: 'JobDefinition24FFE3ED' }, - 'JobName.$': '$.jobName', - 'JobQueue': { - 'Fn::GetAtt': [ - 'JobQueueEE3AD499', - 'JobQueueArn', - ], - }, - 'Tags': { - test: 'this is a tag', - }, - }, - }); -}); -test('throws if tags has invalid value', () => { - expect(() => { - const tags = {}; - for (let i = 0; i < 100; i++) { - tags[i] = 'tag'; - } - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task1', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - tags, - }); - }).toThrow(/Maximum tag number of entries is 50./); - expect(() => { - const keyTooLong = 'k'.repeat(150); - const tags = {}; - tags[keyTooLong] = 'tag'; - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task2', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - tags, - }); - }).toThrow(/Tag key size must be between 1 and 128/); - expect(() => { - const tags = { key: 'k'.repeat(300) }; - new aws_stepfunctions_tasks_1.BatchSubmitJob(stack, 'Task3', { - jobDefinitionArn: batchJobDefinition.jobDefinitionArn, - jobName: 'JobName', - jobQueueArn: batchJobQueue.jobQueueArn, - tags, - }); - }).toThrow(/Tag value maximum size is 256/); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3VibWl0LWpvYi50ZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsic3VibWl0LWpvYi50ZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsNkJBQTZCO0FBQzdCLG1DQUFtQztBQUNuQyxtQ0FBbUM7QUFDbkMsMkNBQTJDO0FBQzNDLDJDQUEyQztBQUMzQyxxREFBcUQ7QUFDckQsaUZBQXFFO0FBRXJFLElBQUksS0FBZ0IsQ0FBQztBQUNyQixJQUFJLGtCQUF3QyxDQUFDO0FBQzdDLElBQUksYUFBOEIsQ0FBQztBQUVuQyxVQUFVLENBQUMsR0FBRyxFQUFFO0lBQ2QsUUFBUTtJQUNSLEtBQUssR0FBRyxJQUFJLEdBQUcsQ0FBQyxLQUFLLEVBQUUsQ0FBQztJQUV4QixrQkFBa0IsR0FBRyxJQUFJLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQyxLQUFLLEVBQUUsZUFBZSxFQUFFO1FBQ3RFLFNBQVMsRUFBRSxJQUFJLEtBQUssQ0FBQyx5QkFBeUIsQ0FBQyxLQUFLLEVBQUUs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pLnRvVGhyb3coXG4gICAgL01heGltdW0gdGFnIG51bWJlciBvZiBlbnRyaWVzIGlzIDUwLi8sXG4gICk7XG5cbiAgZXhwZWN0KCgpID0+IHtcbiAgICBjb25zdCBrZXlUb29Mb25nID0gJ2snLnJlcGVhdCgxNTApO1xuICAgIGNvbnN0IHRhZ3M6IHsgW2tleTogc3RyaW5nXTogc3RyaW5nIH0gPSB7fTtcbiAgICB0YWdzW2tleVRvb0xvbmddID0gJ3RhZyc7XG4gICAgbmV3IEJhdGNoU3VibWl0Sm9iKHN0YWNrLCAnVGFzazInLCB7XG4gICAgICBqb2JEZWZpbml0aW9uQXJuOiBiYXRjaEpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgICAgIGpvYk5hbWU6ICdKb2JOYW1lJyxcbiAgICAgIGpvYlF1ZXVlQXJuOiBiYXRjaEpvYlF1ZXVlLmpvYlF1ZXVlQXJuLFxuICAgICAgdGFncyxcbiAgICB9KTtcbiAgfSkudG9UaHJvdyhcbiAgICAvVGFnIGtleSBzaXplIG11c3QgYmUgYmV0d2VlbiAxIGFuZCAxMjgvLFxuICApO1xuXG4gIGV4cGVjdCgoKSA9PiB7XG4gICAgY29uc3QgdGFncyA9IHsga2V5OiAnaycucmVwZWF0KDMwMCkgfTtcbiAgICBuZXcgQmF0Y2hTdWJtaXRKb2Ioc3RhY2ssICdUYXNrMycsIHtcbiAgICAgIGpvYkRlZmluaXRpb25Bcm46IGJhdGNoSm9iRGVmaW5pdGlvbi5qb2JEZWZpbml0aW9uQXJuLFxuICAgICAgam9iTmFtZTogJ0pvYk5hbWUnLFxuICAgICAgam9iUXVldWVBcm46IGJhdGNoSm9iUXVldWUuam9iUXVldWVBcm4sXG4gICAgICB0YWdzLFxuICAgIH0pO1xuICB9KS50b1Rocm93KFxuICAgIC9UYWcgdmFsdWUgbWF4aW11bSBzaXplIGlzIDI1Ni8sXG4gICk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js deleted file mode 100644 index d49b37fb9a85a..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/ecs-container-definition.test.js +++ /dev/null @@ -1,998 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const path = require("path"); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const ecr = require("aws-cdk-lib/aws-ecr"); -const efs = require("aws-cdk-lib/aws-efs"); -const ssm = require("aws-cdk-lib/aws-ssm"); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const logs = require("aws-cdk-lib/aws-logs"); -const secretsmanager = require("aws-cdk-lib/aws-secretsmanager"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const cdk = require("aws-cdk-lib"); -const lib_1 = require("../lib"); -const utils_1 = require("./utils"); -const aws_ecr_assets_1 = require("aws-cdk-lib/aws-ecr-assets"); -// GIVEN -const defaultContainerProps = { - cpu: 256, - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - memory: aws_cdk_lib_1.Size.mebibytes(2048), -}; -const defaultExpectedProps = { - type: 'container', - containerProperties: { - image: 'amazon/amazon-ecs-sample', - resourceRequirements: [ - { - type: 'MEMORY', - value: '2048', - }, - { - type: 'VCPU', - value: '256', - }, - ], - }, -}; -let stack; -let pascalCaseExpectedProps; -describe.each([lib_1.EcsEc2ContainerDefinition, lib_1.EcsFargateContainerDefinition])('%p', (ContainerDefinition) => { - // GIVEN - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { - ...defaultExpectedProps, - containerProperties: { - ...defaultExpectedProps.containerProperties, - executionRoleArn: { - 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], - }, - }, - }); - }); - test('ecs container defaults', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ExecutionRoleArn: { - 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], - }, - ...pascalCaseExpectedProps.ContainerProperties, - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - AssumeRolePolicyDocument: { - Statement: [ - { - Action: 'sts:AssumeRole', - Effect: 'Allow', - Principal: { Service: 'ecs-tasks.amazonaws.com' }, - }, - ], - Version: '2012-10-17', - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [ - { - Action: [ - 'logs:CreateLogStream', - 'logs:PutLogEvents', - ], - Effect: 'Allow', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { Ref: 'AWS::Partition' }, - ':logs:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':log-group:/aws/batch/job:*', - ], - ], - }, - }, - ], - Version: '2012-10-17', - }, - PolicyName: 'EcsContainerExecutionRoleDefaultPolicy6F59CD37', - Roles: [{ - Ref: 'EcsContainerExecutionRole3B199293', - }], - }); - }); - test('respects command', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - command: ['echo', 'foo'], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Command: ['echo', 'foo'], - }, - }); - }); - test('respects environment', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - privileged: true, - environment: { - foo: 'bar', - }, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Environment: [{ - Name: 'foo', - Value: 'bar', - }], - }, - }); - }); - test('respects executionRole', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - privileged: true, - executionRole: new aws_iam_1.Role(stack, 'execRole', { - assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:user/user-name'), - }), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ExecutionRoleArn: { - 'Fn::GetAtt': ['execRole623CB63A', 'Arn'], - }, - }, - }); - }); - test('respects jobRole', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - privileged: true, - jobRole: new aws_iam_1.Role(stack, 'jobRole', { - assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:user/user-name'), - }), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - JobRoleArn: { - 'Fn::GetAtt': ['jobRoleA2173686', 'Arn'], - }, - }, - }); - }); - test('respects linuxParameters', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - privileged: true, - linuxParameters: new lib_1.LinuxParameters(stack, 'linuxParameters', { - initProcessEnabled: true, - maxSwap: aws_cdk_lib_1.Size.kibibytes(4096), - sharedMemorySize: aws_cdk_lib_1.Size.mebibytes(256), - swappiness: 30, - }), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - LinuxParameters: { - InitProcessEnabled: true, - MaxSwap: 4, - SharedMemorySize: 256, - Swappiness: 30, - }, - }, - }); - }); - test('respects logging', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - logging: ecs.LogDriver.awsLogs({ - datetimeFormat: 'format', - logRetention: logs.RetentionDays.ONE_MONTH, - multilinePattern: 'pattern', - streamPrefix: 'hello', - }), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ExecutionRoleArn: { - 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], - }, - ...pascalCaseExpectedProps.ContainerProperties, - LogConfiguration: { - Options: { - 'awslogs-datetime-format': 'format', - 'awslogs-group': { Ref: 'EcsContainerLogGroup6C5D5962' }, - 'awslogs-multiline-pattern': 'pattern', - 'awslogs-region': { Ref: 'AWS::Region' }, - 'awslogs-stream-prefix': 'hello', - }, - }, - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - AssumeRolePolicyDocument: { - Statement: [ - { - Action: 'sts:AssumeRole', - Effect: 'Allow', - Principal: { Service: 'ecs-tasks.amazonaws.com' }, - }, - ], - Version: '2012-10-17', - }, - }); - }); - test('respects readonlyRootFilesystem', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - readonlyRootFilesystem: true, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ReadonlyRootFilesystem: true, - }, - }); - }); - test('respects secrets from secrestsmanager', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - secrets: { - envName: lib_1.Secret.fromSecretsManager(new secretsmanager.Secret(stack, 'testSecret')), - }, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Secrets: [ - { - Name: 'envName', - ValueFrom: { Ref: 'testSecretB96AD12C' }, - }, - ], - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [ - { - Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], - Effect: 'Allow', - Resource: { - 'Fn::Join': [ - '', [ - 'arn:', - { Ref: 'AWS::Partition' }, - ':logs:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':log-group:/aws/batch/job:*', - ], - ], - }, - }, - { - Action: ['secretsmanager:GetSecretValue', 'secretsmanager:DescribeSecret'], - Effect: 'Allow', - Resource: { Ref: 'testSecretB96AD12C' }, - }, - ], - }, - }); - }); - test('respects versioned secrets from secrestsmanager', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - secrets: { - envName: lib_1.Secret.fromSecretsManagerVersion(new secretsmanager.Secret(stack, 'testSecret'), { - versionId: 'versionID', - versionStage: 'stage', - }), - }, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Secrets: [ - { - Name: 'envName', - ValueFrom: { - 'Fn::Join': [ - '', [ - { Ref: 'testSecretB96AD12C' }, - '::stage:versionID', - ], - ], - }, - }, - ], - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [ - { - Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], - Effect: 'Allow', - Resource: { - 'Fn::Join': [ - '', [ - 'arn:', - { Ref: 'AWS::Partition' }, - ':logs:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':log-group:/aws/batch/job:*', - ], - ], - }, - }, - { - Action: ['secretsmanager:GetSecretValue', 'secretsmanager:DescribeSecret'], - Effect: 'Allow', - Resource: { Ref: 'testSecretB96AD12C' }, - }, - ], - }, - }); - }); - test('respects secrets from ssm', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - secrets: { - envName: lib_1.Secret.fromSsmParameter(new ssm.StringParameter(stack, 'myParam', { stringValue: 'super secret' })), - }, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Secrets: [ - { - Name: 'envName', - ValueFrom: { - 'Fn::Join': [ - '', [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':ssm:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':parameter/', - { Ref: 'myParam03610B68' }, - ], - ], - }, - }, - ], - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [ - { - Action: ['logs:CreateLogStream', 'logs:PutLogEvents'], - Effect: 'Allow', - Resource: { - 'Fn::Join': [ - '', [ - 'arn:', - { Ref: 'AWS::Partition' }, - ':logs:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':log-group:/aws/batch/job:*', - ], - ], - }, - }, - { - Action: ['ssm:DescribeParameters', 'ssm:GetParameters', 'ssm:GetParameter', 'ssm:GetParameterHistory'], - Effect: 'Allow', - Resource: { - 'Fn::Join': [ - '', - [ - 'arn:', - { Ref: 'AWS::Partition' }, - ':ssm:', - { Ref: 'AWS::Region' }, - ':', - { Ref: 'AWS::AccountId' }, - ':parameter/', - { Ref: 'myParam03610B68' }, - ], - ], - }, - }, - ], - }, - }); - }); - test('respects user', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - user: 'foo', - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - User: 'foo', - }, - }); - }); - test('respects efs volumes', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - volumes: [ - lib_1.EcsVolume.efs({ - containerPath: '/first/path', - fileSystem: new efs.FileSystem(stack, 'efs', { - vpc: new aws_ec2_1.Vpc(stack, 'vpc'), - }), - name: 'firstEfsVolume', - accessPointId: 'EfsVolumeAccessPointId', - readonly: true, - rootDirectory: 'efsRootDir', - enableTransitEncryption: true, - transitEncryptionPort: 20181, - useJobRole: true, - }), - lib_1.EcsVolume.efs({ - containerPath: '/second/path', - fileSystem: new efs.FileSystem(stack, 'efs2', { - vpc: new aws_ec2_1.Vpc(stack, 'vpc2'), - }), - name: 'secondEfsVolume', - }), - ], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Volumes: [ - { - EfsVolumeConfiguration: { - FileSystemId: { - Ref: 'efs6C17982A', - }, - RootDirectory: 'efsRootDir', - TransitEncryptionPort: 20181, - AuthorizationConfig: { - AccessPointId: 'EfsVolumeAccessPointId', - Iam: 'ENABLED', - }, - }, - Name: 'firstEfsVolume', - }, - { - EfsVolumeConfiguration: { - FileSystemId: { - Ref: 'efs2CB3916C1', - }, - }, - Name: 'secondEfsVolume', - }, - ], - MountPoints: [ - { - ContainerPath: '/first/path', - ReadOnly: true, - SourceVolume: 'firstEfsVolume', - }, - { - ContainerPath: '/second/path', - SourceVolume: 'secondEfsVolume', - }, - ], - }, - }); - }); - test('respects host volumes', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - volumes: [ - lib_1.EcsVolume.host({ - containerPath: '/container/path', - name: 'EcsHostPathVolume', - hostPath: '/host/path', - }), - ], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Volumes: [ - { - Name: 'EcsHostPathVolume', - Host: { - SourcePath: '/host/path', - }, - }, - ], - MountPoints: [ - { - ContainerPath: '/container/path', - SourceVolume: 'EcsHostPathVolume', - }, - ], - }, - }); - }); - test('respects addVolume() with an EfsVolume', () => { - // GIVEN - const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addVolume(lib_1.EcsVolume.efs({ - containerPath: '/container/path', - fileSystem: new efs.FileSystem(stack, 'efs', { - vpc: new aws_ec2_1.Vpc(stack, 'vpc'), - }), - name: 'AddedEfsVolume', - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Volumes: [{ - Name: 'AddedEfsVolume', - EfsVolumeConfiguration: { - FileSystemId: { - Ref: 'efs6C17982A', - }, - }, - }], - MountPoints: [{ - ContainerPath: '/container/path', - SourceVolume: 'AddedEfsVolume', - }], - }, - }); - }); - test('respects addVolume() with a host volume', () => { - // GIVEN - const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addVolume(lib_1.EcsVolume.host({ - containerPath: '/container/path/new', - name: 'hostName', - hostPath: '/host/path', - readonly: false, - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Volumes: [{ - Name: 'hostName', - Host: { - SourcePath: '/host/path', - }, - }], - MountPoints: [{ - ContainerPath: '/container/path/new', - SourceVolume: 'hostName', - }], - }, - }); - }); - test('correctly renders docker images', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - image: ecs.ContainerImage.fromDockerImageAsset(new aws_ecr_assets_1.DockerImageAsset(stack, 'dockerImageAsset', { - directory: path.join(__dirname, 'batchjob-image'), - })), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Image: { - 'Fn::Sub': '${AWS::AccountId}.dkr.ecr.${AWS::Region}.${AWS::URLSuffix}/cdk-hnb659fds-container-assets-${AWS::AccountId}-${AWS::Region}:8b518243ecbfcfd08b4734069e7e74ff97b7889dfde0a60d16e7bdc96e6c593b', - }, - }, - }); - }); - test('correctly renders images from repositories', () => { - // GIVEN - const repo = new ecr.Repository(stack, 'Repo'); - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new ContainerDefinition(stack, 'EcsContainer', { - ...defaultContainerProps, - image: ecs.ContainerImage.fromEcrRepository(repo, 'my-tag'), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Image: { - 'Fn::Join': [ - '', - [ - { - 'Fn::Select': [ - 4, - { - 'Fn::Split': [ - ':', - { 'Fn::GetAtt': ['Repo02AC86CF', 'Arn'] }, - ], - }, - ], - }, - '.dkr.ecr.', - { - 'Fn::Select': [ - 3, - { - 'Fn::Split': [ - ':', - { 'Fn::GetAtt': ['Repo02AC86CF', 'Arn'] }, - ], - }, - ], - }, - '.', - { Ref: 'AWS::URLSuffix' }, - '/', - { Ref: 'Repo02AC86CF' }, - ':my-tag', - ], - ], - }, - }, - }); - }); -}); -describe('EC2 containers', () => { - // GIVEN - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { - ...defaultExpectedProps, - containerProperties: { - ...defaultExpectedProps.containerProperties, - executionRoleArn: { - 'Fn::GetAtt': ['EcsEc2ContainerExecutionRole90E18680', 'Arn'], - }, - }, - }); - }); - test('respects addUlimit()', () => { - // GIVEN - const jobDefn = new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addUlimit({ - hardLimit: 10, - name: lib_1.UlimitName.SIGPENDING, - softLimit: 1, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Ulimits: [{ - HardLimit: 10, - SoftLimit: 1, - Name: 'sigpending', - }], - }, - }); - }); - test('respects ulimits', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - ulimits: [ - { - hardLimit: 100, - name: lib_1.UlimitName.CORE, - softLimit: 10, - }, - ], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Ulimits: [ - { - HardLimit: 100, - Name: 'core', - SoftLimit: 10, - }, - ], - }, - }); - }); - test('respects privileged', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - privileged: true, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Privileged: true, - }, - }); - }); - test('respects gpu', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - privileged: true, - gpu: 12, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ResourceRequirements: [ - { - Type: 'MEMORY', - Value: '2048', - }, - { - Type: 'VCPU', - Value: '256', - }, - { - Type: 'GPU', - Value: '12', - }, - ], - }, - }); - }); - test('can use an assset as a container', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - image: ecs.ContainerImage.fromAsset(path.join(__dirname, 'batchjob-image')), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - Image: { - 'Fn::Sub': '${AWS::AccountId}.dkr.ecr.${AWS::Region}.${AWS::URLSuffix}/cdk-hnb659fds-container-assets-${AWS::AccountId}-${AWS::Region}:8b518243ecbfcfd08b4734069e7e74ff97b7889dfde0a60d16e7bdc96e6c593b', - }, - ExecutionRoleArn: { 'Fn::GetAtt': ['EcsEc2ContainerExecutionRole90E18680', 'Arn'] }, - }, - }); - }); -}); -describe('Fargate containers', () => { - // GIVEN - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, { - ...defaultExpectedProps, - containerProperties: { - ...defaultExpectedProps.containerProperties, - executionRoleArn: { - 'Fn::GetAtt': ['EcsContainerExecutionRole3B199293', 'Arn'], - }, - }, - }); - }); - test('create executionRole by default', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { - ...defaultContainerProps, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ExecutionRoleArn: { - 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], - }, - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - AssumeRolePolicyDocument: { - Statement: [{ - Action: 'sts:AssumeRole', - Effect: 'Allow', - Principal: { Service: 'ecs-tasks.amazonaws.com' }, - }], - Version: '2012-10-17', - }, - }); - }); - test('can set ephemeralStorageSize', () => { - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { - ...defaultContainerProps, - fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, - ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(100), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ExecutionRoleArn: { - 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], - }, - EphemeralStorage: { - SizeInGiB: aws_cdk_lib_1.Size.gibibytes(100).toGibibytes(), - }, - }, - }); - }); - test('can set ephemeralStorageSize as token', () => { - const ephemeralStorageValue = cdk.Token.asNumber(150); - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { - ...defaultContainerProps, - fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, - ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(ephemeralStorageValue), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - ContainerProperties: { - ...pascalCaseExpectedProps.ContainerProperties, - ExecutionRoleArn: { - 'Fn::GetAtt': ['EcsFargateContainerExecutionRole3286EAFE', 'Arn'], - }, - EphemeralStorage: { - SizeInGiB: aws_cdk_lib_1.Size.gibibytes(150).toGibibytes(), - }, - }, - }); - }); - test('ephemeralStorageSize throws error when out of range', () => { - expect(() => new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer', { - ...defaultContainerProps, - fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, - ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(19), - }), - })).toThrow("ECS Fargate container 'EcsFargateContainer' specifies 'ephemeralStorageSize' at 19 < 21 GB"); - expect(() => new lib_1.EcsJobDefinition(stack, 'ECSJobDefn2', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsFargateContainer2', { - ...defaultContainerProps, - fargatePlatformVersion: ecs.FargatePlatformVersion.LATEST, - ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(201), - }), - })).toThrow("ECS Fargate container 'EcsFargateContainer2' specifies 'ephemeralStorageSize' at 201 > 200 GB"); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJlY3MtY29udGFpbmVyLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCw2QkFBNkI7QUFDN0IsaURBQTBDO0FBQzFDLDJDQUEyQztBQUMzQywyQ0FBMkM7QUFDM0MsMkNBQTJDO0FBQzNDLDJDQUEyQztBQUMzQyxpREFBeUQ7QUFDekQsNkNBQTZDO0FBQzdDLGlFQUFpRTtBQUNqRSw2Q0FBMEM7QUFDMUMsbUNBQW1DO0FBQ25DLGdDQUE2TTtBQUU3TSxtQ0FBa0Q7QUFDbEQsK0RBQThEO0FBRTlELFFBQVE7QUFDUixNQUFNLHFCQUFxQixHQUFnQztJQUN6RCxHQUFHLEVBQUUsR0FBRztJQUNSLEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFlBQVksQ0FBQywwQkFBMEIsQ0FBQztJQUNsRSxNQUFNLEVBQUUsa0JBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDO0NBQzdCLENBQUM7QUFFRixNQUFNLG9CQUFvQixHQUEwQjtJQUNsRCxJQUFJLEVBQUUsV0FBVztJQUNqQixtQkFBbUIsRUFBRTtRQUNuQixLQUFLLEVBQUUsMEJBQTBCO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Y3Rpb246IFtcbiAgICAgICAgICAgICAgJ2xvZ3M6Q3JlYXRlTG9nU3RyZWFtJyxcbiAgICAgICAgICAgICAgJ2xvZ3M6UHV0TG9nRXZlbnRzJyxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsXG4gICAgICAgICAgICAgICAgW1xuICAgICAgICAgICAgICAgICAgJ2FybjonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlBhcnRpdGlvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6bG9nczonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlJlZ2lvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpBY2NvdW50SWQnIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZy1ncm91cDovYXdzL2JhdGNoL2pvYjoqJyxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgICB9LFxuICAgICAgUG9saWN5TmFtZTogJ0Vjc0NvbnRhaW5lckV4ZWN1dGlvblJvbGVEZWZhdWx0UG9saWN5NkY1OUNEMzcnLFxuICAgICAgUm9sZXM6IFt7XG4gICAgICAgIFJlZjogJ0Vjc0NvbnRhaW5lckV4ZWN1dGlvblJvbGUzQjE5OTI5MycsXG4gICAgICB9XSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgY29tbWFuZCcsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NK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ICAgICB7IFJlZjogJ0FXUzo6UGFydGl0aW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2dzOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OkFjY291bnRJZCcgfSxcbiAgICAgICAgICAgICAgICAgICc6bG9nLWdyb3VwOi9hd3MvYmF0Y2gvam9iOionLFxuICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiBbJ3NlY3JldHNtYW5hZ2VyOkdldFNlY3JldFZhbHVlJywgJ3NlY3JldHNtYW5hZ2VyOkRlc2NyaWJlU2VjcmV0J10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZTogeyBSZWY6ICd0ZXN0U2VjcmV0Qjk2QUQxMkMnIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgXSxcbiAgICAgIH0sXG4gICAgfSk7XG4gIH0pO1xuXG4gIHRlc3QoJ3Jlc3BlY3RzIHZlcnNpb25lZCBzZWNyZXRzIGZyb20gc2VjcmVzdHNtYW5hZ2VyJywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWNzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0VDU0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIHNlY3JldHM6IHtcbiAgICAgICAgICBlbnZOYW1lOiBTZWNyZXQuZnJvbVNlY3JldHNNYW5hZ2VyVmVyc2lvbihuZXcgc2VjcmV0c21hbmFnZXIuU2VjcmV0KHN0YWNrLCAndGVzdFNlY3JldCcpLCB7XG4gICAgICAgICAgICB2ZXJzaW9uSWQ6ICd2ZXJzaW9uSUQnLFxuICAgICAgICAgICAgdmVyc2lvblN0YWdlOiAnc3RhZ2UnLFxuICAgICAgICAgIH0pLFxuICAgICAgICB9LFxuICAgICAgfSksXG4gICAgfSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgU2VjcmV0czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIE5hbWU6ICdlbnZOYW1lJyxcbiAgICAgICAgICAgIFZhbHVlRnJvbToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAndGVzdFNlY3JldEI5NkFEMTJDJyB9LFxuICAgICAgICAgICAgICAgICAgJzo6c3RhZ2U6dmVyc2lvbklEJyxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgICAgUG9saWN5RG9jdW1lbnQ6IHtcbiAgICAgICAgU3RhdGVtZW50OiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiBbJ2xvZ3M6Q3JlYXRlTG9nU3RyZWFtJywgJ2xvZ3M6UHV0TG9nRXZlbnRzJ10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpQYXJ0aXRpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZ3M6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpSZWdpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6QWNjb3VudElkJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2ctZ3JvdXA6L2F3cy9iYXRjaC9qb2I6KicsXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246IFsnc2VjcmV0c21hbmFnZXI6R2V0U2VjcmV0VmFsdWUnLCAnc2VjcmV0c21hbmFnZXI6RGVzY3JpYmVTZWNyZXQnXSxcbiAgICAgICAgICAgIEVmZmVjdDogJ0FsbG93JyxcbiAgICAgICAgICAgIFJlc291cmNlOiB7IFJlZjogJ3Rlc3RTZWNyZXRCOTZBRDEyQycgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgc2VjcmV0cyBmcm9tIHNzbScsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICBzZWNyZXRzOiB7XG4gICAgICAgICAgZW52TmFtZTogU2VjcmV0LmZyb21Tc21QYXJhbWV0ZXIobmV3IHNzbS5TdHJpbmdQYXJhbWV0ZXIoc3RhY2ssICdteVBhcmFtJywgeyBzdHJpbmdWYWx1ZTogJ3N1cGVyIHNlY3JldCcgfSkpLFxuICAgICAgICB9LFxuICAgICAgfSksXG4gICAgfSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgU2VjcmV0czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIE5hbWU6ICdlbnZOYW1lJyxcbiAgICAgICAgICAgIFZhbHVlRnJvbToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgUmVmOiAnQVdTOjpQYXJ0aXRpb24nLFxuICAgICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICAgICc6c3NtOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OkFjY291bnRJZCcgfSxcbiAgICAgICAgICAgICAgICAgICc6cGFyYW1ldGVyLycsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ215UGFyYW0wMzYxMEI2OCcgfSxcbiAgICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgICBdLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcblxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgICAgUG9saWN5RG9jdW1lbnQ6IHtcbiAgICAgICAgU3RhdGVtZW50OiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiBbJ2xvZ3M6Q3JlYXRlTG9nU3RyZWFtJywgJ2xvZ3M6UHV0TG9nRXZlbnRzJ10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsIFtcbiAgICAgICAgICAgICAgICAgICdhcm46JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpQYXJ0aXRpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOmxvZ3M6JyxcbiAgICAgICAgICAgICAgICAgIHsgUmVmOiAnQVdTOjpSZWdpb24nIH0sXG4gICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6QWNjb3VudElkJyB9LFxuICAgICAgICAgICAgICAgICAgJzpsb2ctZ3JvdXA6L2F3cy9iYXRjaC9qb2I6KicsXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfSxcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246IFsnc3NtOkRlc2NyaWJlUGFyYW1ldGVycycsICdzc206R2V0UGFyYW1ldGVycycsICdzc206R2V0UGFyYW1ldGVyJywgJ3NzbTpHZXRQYXJhbWV0ZXJIaXN0b3J5J10sXG4gICAgICAgICAgICBFZmZlY3Q6ICdBbGxvdycsXG4gICAgICAgICAgICBSZXNvdXJjZToge1xuICAgICAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAgICAgJycsXG4gICAgICAgICAgICAgICAgW1xuICAgICAgICAgICAgICAgICAgJ2FybjonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OlBhcnRpdGlvbicgfSxcbiAgICAgICAgICAgICAgICAgICc6c3NtOicsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6UmVnaW9uJyB9LFxuICAgICAgICAgICAgICAgICAgJzonLFxuICAgICAgICAgICAgICAgICAgeyBSZWY6ICdBV1M6OkFjY291bnRJZCcgfSxcbiAgICAgICAgICAgICAgICAgICc6cGFyYW1ldGVyLycsXG4gICAgICAgICAgICAgICAgICB7IFJlZjogJ215UGFyYW0wMzYxMEI2OCcgfSxcbiAgICAgICAgICAgICAgICBdLFxuXG4gICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyB1c2VyJywgKCkgPT4ge1xuICAvLyBXSEVOXG4gICAgbmV3IEVjc0pvYkRlZmluaXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICB1c2VyOiAnZm9vJyxcbiAgICAgIH0pLFxuICAgIH0p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lZnNSb290RGlyJyxcbiAgICAgICAgICAgIGVuYWJsZVRyYW5zaXRFbmNyeXB0aW9uOiB0cnVlLFxuICAgICAgICAgICAgdHJhbnNpdEVuY3J5cHRpb25Qb3J0OiAyMDE4MSxcbiAgICAgICAgICAgIHVzZUpvYlJvbGU6IHRydWUsXG4gICAgICAgICAgfSksXG4gICAgICAgICAgRWNzVm9sdW1lLmVmcyh7XG4gICAgICAgICAgICBjb250YWluZXJQYXRoOiAnL3NlY29uZC9wYXRoJyxcbiAgICAgICAgICAgIGZpbGVTeXN0ZW06IG5ldyBlZnMuRmlsZVN5c3RlbShzdGFjaywgJ2VmczInLCB7XG4gICAgICAgICAgICAgIHZwYzogbmV3IFZwYyhzdGFjaywgJ3ZwYzInKSxcbiAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgbmFtZTogJ3NlY29uZEVmc1ZvbHVtZScsXG4gICAgICAgICAgfSksXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBWb2x1bWVzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgRWZzVm9sdW1lQ29uZmlndXJhdGlvbjoge1xuICAgICAgICAgICAgICBGaWxlU3lzdGVtSWQ6IHtcbiAgICAgICAgICAgICAgICBSZWY6ICdlZnM2QzE3OTgyQScsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIFJvb3REaXJlY3Rvcnk6ICdlZnNSb290RGlyJyxcbiAgICAgICAgICAgICAgVHJhbnNpdEVuY3J5cHRpb25Qb3J0OiAyMDE4MSxcbiAgICAgICAgICAgICAgQXV0aG9yaXphdGlvbkNvbmZpZzoge1xuICAgICAgICAgICAgICAgIEFjY2Vzc1BvaW50SWQ6ICdFZnNWb2x1bWVBY2Nlc3NQb2ludElkJyxcbiAgICAgICAgICAgICAgICBJYW06ICdFTkFCTEVEJyxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBOYW1lOiAnZmlyc3RFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgRWZzVm9sdW1lQ29uZmlndXJhdGlvbjoge1xuICAgICAgICAgICAgICBGaWxlU3lzdGVtSWQ6IHtcbiAgICAgICAgICAgICAgICBSZWY6ICdlZnMyQ0IzOTE2QzEnLFxuICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIE5hbWU6ICdzZWNvbmRFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICAgIE1vdW50UG9pbnRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgQ29udGFpbmVyUGF0aDogJy9maXJzdC9wYXRoJyxcbiAgICAgICAgICAgIFJlYWRPbmx5OiB0cnVlLFxuICAgICAgICAgICAgU291cmNlVm9sdW1lOiAnZmlyc3RFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQ29udGFpbmVyUGF0aDogJy9zZWNvbmQvcGF0aCcsXG4gICAgICAgICAgICBTb3VyY2VWb2x1bWU6ICdzZWNvbmRFZnNWb2x1bWUnLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBob3N0IHZvbHVtZXMnLCAoKSA9PiB7XG4gICAgLy8gV0hFTlxuICAgIG5ldyBFY3NKb2JEZWZpbml0aW9uKHN0YWNrLCAnRUNTSm9iRGVmbicsIHtcbiAgICAgIGNvbnRhaW5lcjogbmV3IENvbnRhaW5lckRlZmluaXRpb24oc3RhY2ssICdFY3NDb250YWluZXInLCB7XG4gICAgICAgIC4uLmRlZmF1bHRDb250YWluZXJQcm9wcyxcbiAgICAgICAgdm9sdW1lczogW1xuICAgICAgICAgIEVjc1ZvbHVtZS5ob3N0KHtcbiAgICAgICAgICAgIGNvbnRhaW5lclBhdGg6ICcvY29udGFpbmVyL3BhdGgnLFxuICAgICAgICAgICAgbmFtZTogJ0Vjc0hvc3RQYXRoVm9sdW1lJyxcbiAgICAgICAgICAgIGhvc3RQYXRoOiAnL2hvc3QvcGF0aCcsXG4gICAgICAgICAgfSksXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBWb2x1bWVzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgTmFtZTogJ0Vjc0hvc3RQYXRoVm9sdW1lJyxcbiAgICAgICAgICAgIEhvc3Q6IHtcbiAgICAgICAgICAgICAgU291cmNlUGF0aDogJy9ob3N0L3BhdGgnLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgICBNb3VudFBvaW50czogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIENvbnRhaW5lclBhdGg6ICcvY29udGFpbmVyL3BhdGgnLFxuICAgICAgICAgIC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hdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGltYWdlOiBlY3MuQ29udGFpbmVySW1hZ2UuZnJvbUVjclJlcG9zaXRvcnkocmVwbywgJ215LXRhZycpLFxuICAgICAgfSksXG4gICAgfSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcyxcbiAgICAgIENvbnRhaW5lclByb3BlcnRpZXM6IHtcbiAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuQ29udGFpbmVyUHJvcGVydGllcyxcbiAgICAgICAgSW1hZ2U6IHtcbiAgICAgICAgICAnRm46OkpvaW4nOiBbXG4gICAgICAgICAgICAnJyxcbiAgICAgICAgICAgIFtcbiAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICAgICAgNCxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICAgICAnOicsXG4gICAgICAgICAgICAgICAgICAgICAgeyAnRm46OkdldEF0dCc6IFsnUmVwbzAyQUM4NkNGJywgJ0FybiddIH0sXG4gICAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICcuZGtyLmVjci4nLFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTZWxlY3QnOiBbXG4gICAgICAgICAgICAgICAgICAzLFxuICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAnRm46OlNwbGl0JzogW1xuICAgICAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgICAgICB7ICdGbjo6R2V0QXR0JzogWydSZXBvMDJBQzg2Q0YnLCAnQXJuJ10gfSxcbiAgICAgICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgJy4nLFxuICAgICAgICAgICAgICB7IFJlZjogJ0FXUzo6VVJMU3VmZml4JyB9LFxuICAgICAgICAgICAgICAnLycsXG4gICAgICAgICAgICAgIHsgUmVmOiAnUmVwbzAyQUM4NkNGJyB9LFxuICAgICAgICAgICAgICAnOm15LXRhZycsXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIF0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcbn0pO1xuXG5kZXNjcmliZSgnRUMyIGNvbnRhaW5lcnMnLCAoKSA9PiB7XG4gIC8vIEdJVkVOXG4gIGJlZm9yZUVhY2goKCkgPT4ge1xuICAgIHN0YWNrID0gbmV3IFN0YWNrKCk7XG4gICAgcGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMgPSBjYXBpdGFsaXplUHJvcGVydHlOYW1lcyhzdGFjaywge1xuICAgICAgLi4uZGVmYXVsdEV4cGVjdGVkUHJvcHMsXG4gICAgICBjb250YWluZXJQcm9wZXJ0aWVzOiB7XG4gICAgICAgIC4uLmRlZmF1bHRFeHBlY3RlZFByb3BzLmNvbnRhaW5lclByb3BlcnRpZXMsXG4gICAgICAgIGV4ZWN1dGlvblJvbGVBcm46IHtcbiAgICAgICAgICAnRm46OkdldEF0dCc6IFsnRWNzRWMyQ29udGFpbmVyRXhlY3V0aW9uUm9sZTkwRTE4NjgwJywgJ0FybiddLFxuICAgICAgICB9IGFzIGFueSxcbiAgICAgIH0sXG4gICAgfSk7XG4gIH0pO1xuXG4gIHRlc3QoJ3Jlc3BlY3RzIGFkZFVsaW1pdC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aXRpb24oc3RhY2ssICdFQ1NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0VjMkNvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICB1bGltaXRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgaGFyZExpbWl0OiAxMDAsXG4gICAgICAgICAgICBuYW1lOiBVbGltaXROYW1lLkNPUkUsXG4gICAgICAgICAgICBzb2Z0TGltaXQ6IDEwLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgQ29udGFpbmVyUHJvcGVydGllczoge1xuICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Db250YWluZXJQcm9wZXJ0aWVzLFxuICAgICAgICBVbGltaXRzOiBbXG4gICAgICAgICAge1xuICAgICAgICAgICAgSGFyZExpbWl0OiAxMDAsXG4gICAgICAgICAgICBOYW1lOiAnY29yZScsXG4gICAgICAgICAgICBTb2Z0TGltaXQ6IDEwLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBwcml2aWxlZ2VkJywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWNzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0VDU0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFY3NFYzJDb250YWluZXJEZWZpbml0aW9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XCIpO1xuXG4gICAgZXhwZWN0KCgpID0+IG5ldyBFY3NKb2JEZWZpbml0aW9uKHN0YWNrLCAnRUNTSm9iRGVmbjInLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFY3NGYXJnYXRlQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0ZhcmdhdGVDb250YWluZXIyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGZhcmdhdGVQbGF0Zm9ybVZlcnNpb246IGVjcy5GYXJnYXRlUGxhdGZvcm1WZXJzaW9uLkxBVEVTVCxcbiAgICAgICAgZXBoZW1lcmFsU3RvcmFnZVNpemU6IFNpemUuZ2liaWJ5dGVzKDIwMSksXG4gICAgICB9KSxcbiAgICB9KSkudG9UaHJvdyhcIkVDUyBGYXJnYXRlIGNvbnRhaW5lciAnRWNzRmFyZ2F0ZUNvbnRhaW5lcjInIHNwZWNpZmllcyAnZXBoZW1lcmFsU3RvcmFnZVNpemUnIGF0IDIwMSA+IDIwMCBHQlwiKTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js deleted file mode 100644 index 0eb741964ca54..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/ecs-job-definition.test.js +++ /dev/null @@ -1,147 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const iam = require("aws-cdk-lib/aws-iam"); -const lib_1 = require("../lib"); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -test('EcsJobDefinition respects propagateTags', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EcsJobDefinition(stack, 'JobDefn', { - propagateTags: true, - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - PropagateTags: true, - }); -}); -test('EcsJobDefinition uses Compatibility.EC2 for EC2 containers', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - PlatformCapabilities: [lib_1.Compatibility.EC2], - }); -}); -test('EcsJobDefinition uses Compatibility.FARGATE for Fargate containers', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - PlatformCapabilities: [lib_1.Compatibility.FARGATE], - }); -}); -test('can be imported from ARN', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - const importedJob = lib_1.EcsJobDefinition.fromJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); - // THEN - expect(importedJob.jobDefinitionArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); -}); -test('JobDefinitionName is parsed from arn', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - const jobDefinition = new lib_1.EcsJobDefinition(stack, 'JobDefn', { - propagateTags: true, - container: new lib_1.EcsEc2ContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - expect(aws_cdk_lib_1.Tokenization.resolve(jobDefinition.jobDefinitionName, { - scope: stack, - resolver: new aws_cdk_lib_1.DefaultTokenResolver(new aws_cdk_lib_1.StringConcat()), - })).toEqual({ - 'Fn::Select': [ - 1, - { - 'Fn::Split': [ - '/', - { - 'Fn::Select': [ - 5, - { - 'Fn::Split': [ - ':', - { - Ref: 'JobDefnA747EE6E', - }, - ], - }, - ], - }, - ], - }, - ], - }); -}); -test('JobDefinitionName is parsed from arn in imported job', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - const importedJob = lib_1.EcsJobDefinition.fromJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); - // THEN - expect(importedJob.jobDefinitionName).toEqual('job-def-name'); -}); -test('grantSubmitJob() grants the job role the correct actions', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const ecsJob = new lib_1.EcsJobDefinition(stack, 'ECSJob', { - container: new lib_1.EcsFargateContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('foorepo/fooimage'), - }), - }); - const queue = new lib_1.JobQueue(stack, 'queue'); - queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'env', { - vpc: new aws_ec2_1.Vpc(stack, 'VPC'), - }), 1); - const user = new iam.User(stack, 'MyUser'); - // WHEN - ecsJob.grantSubmitJob(user, queue); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Policy', { - PolicyDocument: { - Statement: [{ - Action: 'batch:SubmitJob', - Effect: 'Allow', - Resource: [ - { Ref: 'ECSJobFFFEA569' }, - { 'Fn::GetAtt': ['queue276F7297', 'JobQueueArn'] }, - ], - }], - Version: '2012-10-17', - }, - PolicyName: 'MyUserDefaultPolicy7B897426', - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWNzLWpvYi1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJlY3Mtam9iLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsNkNBQTRGO0FBQzVGLDJDQUEyQztBQUMzQyxnQ0FBOEo7QUFDOUosaURBQTBDO0FBRTFDLElBQUksQ0FBQyx5Q0FBeUMsRUFBRSxHQUFHLEVBQUU7SUFDbkQsUUFBUTtJQUNSLE1BQU0sS0FBSyxHQUFHLElBQUksbUJBQUssRUFBRSxDQUFDO0lBRTFCLE9BQU87SUFDUCxJQUFJLHNCQUFnQixDQUFDLEtBQUssRUFBRSxTQUFTLEVBQUU7UUFDckMsYUFBYSxFQUFFLElBQUk7UUFDbkIsU0FBUyxFQUFFLElBQUksK0JBQXlCLENBQUMsS0FBSyxFQUFFLGNBQWMsRUFBRTtZQUM5RCxHQUFHLEVBQUUsR0FBRztZQUNSLEtBQUssRUFBRSxHQUFHLENBQUMsY0FBYyxDQUFDLFlBQVksQ0FBQywwQkFBMEIsQ0FBQztZQUNsRSxNQUFNLEVBQUUsa0JBQUksQ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gICAgY29udGFpbmVyOiBuZXcgRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0NvbnRhaW5lcicsIHtcbiAgICAgIGNwdTogMjU2LFxuICAgICAgaW1hZ2U6IGVjcy5Db250YWluZXJJbWFnZS5mcm9tUmVnaXN0cnkoJ2FtYXpvbi9hbWF6b24tZWNzLXNhbXBsZScpLFxuICAgICAgbWVtb3J5OiBTaXplLm1lYmlieXRlcygyMDQ4KSxcbiAgICB9KSxcbiAgfSk7XG5cbiAgLy8gVEhFTlxuICBleHBlY3QoVG9rZW5pemF0aW9uLnJlc29sdmUoam9iRGVmaW5pdGlvbi5qb2JEZWZpbml0aW9uTmFtZSwge1xuICAgIHNjb3BlOiBzdGFjayxcbiAgICByZXNvbHZlcjogbmV3IERlZmF1bHRUb2tlblJlc29sdmVyKG5ldyBTdHJpbmdDb25jYXQoKSksXG4gIH0pKS50b0VxdWFsKHtcbiAgICAnRm46OlNlbGVjdCc6IFtcbiAgICAgIDEsXG4gICAgICB7XG4gICAgICAgICdGbjo6U3BsaXQnOiBbXG4gICAgICAgICAgJy8nLFxuICAgICAgICAgIHtcbiAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICA1LFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgUmVmOiAnSm9iRGVmbkE3NDdFRTZFJyxcbiAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgXSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIF0sXG4gICAgICAgICAgfSxcbiAgICAgICAgXSxcbiAgICAgIH0sXG4gICAgXSxcbiAgfSk7XG59KTtcblxudGVzdCgnSm9iRGVmaW5pdGlvbk5hbWUgaXMgcGFyc2VkIGZyb20gYXJuIGluIGltc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ZEVjMkVjc0NvbXB1dGVFbnZpcm9ubWVudChzdGFjaywgJ2VudicsIHtcbiAgICAgIHZwYzogbmV3IFZwYyhzdGFjaywgJ1ZQQycpLFxuICAgIH0pLFxuICAgIDEsXG4gICk7XG5cbiAgY29uc3QgdXNlciA9IG5ldyBpYW0uVXNlcihzdGFjaywgJ015VXNlcicpO1xuXG4gIC8vIFdIRU5cbiAgZWNzSm9iLmdyYW50U3VibWl0Sm9iKHVzZXIsIHF1ZXVlKTtcblxuICAvLyBUSEVOXG4gIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OklBTTo6UG9saWN5Jywge1xuICAgIFBvbGljeURvY3VtZW50OiB7XG4gICAgICBTdGF0ZW1lbnQ6IFt7XG4gICAgICAgIEFjdGlvbjogJ2JhdGNoOlN1Ym1pdEpvYicsXG4gICAgICAgIEVmZmVjdDogJ0FsbG93JyxcbiAgICAgICAgUmVzb3VyY2U6IFtcbiAgICAgICAgICB7IFJlZjogJ0VDU0pvYkZGRkVBNTY5JyB9LFxuICAgICAgICAgIHsgJ0ZuOjpHZXRBdHQnOiBbJ3F1ZXVlMjc2RjcyOTcnLCAnSm9iUXVldWVBcm4nXSB9LFxuICAgICAgICBdLFxuICAgICAgfV0sXG4gICAgICBWZXJzaW9uOiAnMjAxMi0xMC0xNycsXG4gICAgfSxcbiAgICBQb2xpY3lOYW1lOiAnTXlVc2VyRGVmYXVsdFBvbGljeTdCODk3NDI2JyxcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js deleted file mode 100644 index 3230501ab97c5..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/eks-container-definition.test.js +++ /dev/null @@ -1,712 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const utils_1 = require("./utils"); -const lib_1 = require("../lib"); -// GIVEN -const defaultContainerProps = { - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), -}; -const defaultExpectedProps = { - type: 'container', - eksProperties: { - podProperties: { - containers: [{ - image: 'amazon/amazon-ecs-sample', - }], - }, - }, -}; -let stack; -let pascalCaseExpectedProps; -describe('eks container', () => { - // GIVEN - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedProps); - }); - test('eks container defaults', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - }); - }); - test('respects args', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - args: ['arg1', 'arg2'], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Args: ['arg1', 'arg2'], - }], - }, - }, - }); - }); - test('respects command', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - command: ['echo', 'bar'], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Command: ['echo', 'bar'], - }], - }, - }, - }); - }); - test('respects cpuLimit', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - cpuLimit: 256, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Limits: { - cpu: 256, - }, - }, - }], - }, - }, - }); - }); - test('respects cpuReservation', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - cpuReservation: 256, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Requests: { - cpu: 256, - }, - }, - }], - }, - }, - }); - }); - test('respects memoryLimitMiB', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - memoryLimit: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Limits: { - memory: '2048Mi', - }, - }, - }], - }, - }, - }); - }); - test('respects memoryReservation', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - memoryReservation: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Requests: { - memory: '2048Mi', - }, - }, - }], - }, - }, - }); - }); - test('respects gpuLimit', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - gpuLimit: 20, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Limits: { - 'nvidia.com/gpu': 20, - }, - }, - }], - }, - }, - }); - }); - test('respects gpuReservation', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - gpuReservation: 20, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Requests: { - 'nvidia.com/gpu': 20, - }, - }, - }], - }, - }, - }); - }); - test('respects resource requests and limits', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - cpuLimit: 256, - cpuReservation: 128, - memoryLimit: aws_cdk_lib_1.Size.mebibytes(2048), - memoryReservation: aws_cdk_lib_1.Size.mebibytes(2048), - gpuLimit: 20, - gpuReservation: 10, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Resources: { - Limits: { - 'cpu': 256, - 'memory': '2048Mi', - 'nvidia.com/gpu': 20, - }, - Requests: { - 'cpu': 128, - 'memory': '2048Mi', - 'nvidia.com/gpu': 10, - }, - }, - }], - }, - }, - }); - }); - test('respects env', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - env: { - var: 'val', - boo: 'bah', - }, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Env: [ - { - Name: 'var', - Value: 'val', - }, - { - Name: 'boo', - Value: 'bah', - }, - ], - }], - }, - }, - }); - }); - test('respects imagePullPolicy', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - imagePullPolicy: lib_1.ImagePullPolicy.NEVER, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - ImagePullPolicy: 'Never', - }], - }, - }, - }); - }); - test('respects name', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - name: 'myContainerName', - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - Name: 'myContainerName', - }], - }, - }, - }); - }); - test('respects privileged', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - privileged: true, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - SecurityContext: { - Privileged: true, - }, - }], - }, - }, - }); - }); - test('respects readonlyFileSystem', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - readonlyRootFilesystem: true, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - SecurityContext: { - ReadOnlyRootFilesystem: true, - }, - }], - }, - }, - }); - }); - test('respects runAsGroup', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - runAsGroup: 1, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - SecurityContext: { - RunAsGroup: 1, - }, - }], - }, - }, - }); - }); - test('respects runAsRoot', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefEksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - runAsRoot: true, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - SecurityContext: { - RunAsNonRoot: false, - }, - }], - }, - }, - }); - }); - test('respects runAsUser', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - runAsUser: 90, - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - SecurityContext: { - RunAsUser: 90, - }, - }], - }, - }, - }); - }); - test('respects emptyDir volumes', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - volumes: [ - lib_1.EksVolume.emptyDir({ - name: 'emptyDirName', - medium: lib_1.EmptyDirMediumType.DISK, - mountPath: '/mount/path', - readonly: false, - sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), - }), - ], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - Name: 'emptyDirName', - ReadOnly: false, - }], - }], - Volumes: [{ - Name: 'emptyDirName', - EmptyDir: { - Medium: '', - SizeLimit: '2048Mi', - }, - }], - }, - }, - }); - }); - test('respects hostPath volumes', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - volumes: [lib_1.EksVolume.hostPath({ - name: 'hostPathName', - hostPath: 'hostPathPath', - mountPath: '/mount/path', - readonly: true, - })], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - Name: 'hostPathName', - ReadOnly: true, - }], - }], - Volumes: [{ - Name: 'hostPathName', - HostPath: { - Path: 'hostPathPath', - }, - }], - }, - }, - }); - }); - test('respects secret volumes, and ensures optional defaults to true', () => { - // WHEN - new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - volumes: [lib_1.EksVolume.secret({ - name: 'secretVolumeName', - secretName: 'myKubeSecret', - mountPath: '/mount/path', - readonly: true, - })], - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - ReadOnly: true, - }], - }], - Volumes: [{ - Name: 'secretVolumeName', - Secret: { - SecretName: 'myKubeSecret', - Optional: true, - }, - }], - }, - }, - }); - }); - test('respects addVolume() with emptyDir volume', () => { - // GIVEN - const jobDefn = new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addVolume(lib_1.EksVolume.emptyDir({ - name: 'emptyDirName', - medium: lib_1.EmptyDirMediumType.DISK, - mountPath: '/mount/path', - readonly: false, - sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - Name: 'emptyDirName', - ReadOnly: false, - }], - }], - Volumes: [{ - Name: 'emptyDirName', - EmptyDir: { - Medium: '', - SizeLimit: '2048Mi', - }, - }], - }, - }, - }); - }); - test('respects addVolume() with hostPath volume', () => { - // GIVEN - const jobDefn = new lib_1.EksJobDefinition(stack, 'EksJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addVolume(lib_1.EksVolume.hostPath({ - name: 'hostPathName', - hostPath: 'hostPathPath', - mountPath: '/mount/path', - readonly: true, - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - Name: 'hostPathName', - ReadOnly: true, - }], - }], - Volumes: [{ - Name: 'hostPathName', - HostPath: { - Path: 'hostPathPath', - }, - }], - }, - }, - }); - }); - test('respects addVolume() with secret volume (optional: false)', () => { - // GIVEN - const jobDefn = new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EcsEc2Container', { - ...defaultContainerProps, - }), - }); - // WHEN - jobDefn.container.addVolume(lib_1.EksVolume.secret({ - name: 'secretVolumeName', - secretName: 'secretName', - optional: false, - mountPath: '/mount/path', - readonly: true, - })); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...pascalCaseExpectedProps, - EksProperties: { - PodProperties: { - ...pascalCaseExpectedProps.EksProperties.PodProperties, - Containers: [{ - ...pascalCaseExpectedProps.EksProperties.PodProperties.Containers[0], - VolumeMounts: [{ - MountPath: '/mount/path', - Name: 'secretVolumeName', - ReadOnly: true, - }], - }], - Volumes: [{ - Name: 'secretVolumeName', - Secret: { - SecretName: 'secretName', - Optional: false, - }, - }], - }, - }, - }); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWNvbnRhaW5lci1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJla3MtY29udGFpbmVyLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FB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Qcm9wcyxcbiAgICAgIEVrc1Byb3BlcnRpZXM6IHtcbiAgICAgICAgUG9kUHJvcGVydGllczoge1xuICAgICAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLkVrc1Byb3BlcnRpZXMuUG9kUHJvcGVydGllcyxcbiAgICAgICAgICBDb250YWluZXJzOiBbe1xuICAgICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLkNvbnRhaW5lcnNbMF0sXG4gICAgICAgICAgICBSZXNvdXJjZXM6IHtcbiAgICAgICAgICAgICAgTGltaXRzOiB7XG4gICAgICAgICAgICAgICAgJ2NwdSc6IDI1NixcbiAgICAgICAgICAgICAgICAnbWVtb3J5JzogJzIwNDhNaScsXG4gICAgICAgICAgICAgICAgJ252aWRpYS5jb20vZ3B1JzogMjAsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgIFJlcXVlc3RzOiB7XG4gICAgICAgICAgICAgICAgJ2NwdSc6IDEyOCxcbiAgICAgICAgICAgICAgICAnbWVtb3J5JzogJzIwNDhNaScsXG4gICAgICAgICAgICAgICAgJ252aWRpYS5jb20vZ3B1JzogMTAsXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH1dLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgZW52JywgKCkgPT4ge1xuICAgIC8vIFdIRU5cbiAgICBuZXcgRWtzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0Vrc0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFa3NDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzRWMyQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICAgIGVudjoge1xuICAgICAgICAgIHZhc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LnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLkVrc1Byb3BlcnRpZXMuUG9kUHJvcGVydGllcyxcbiAgICAgICAgICBDb250YWluZXJzOiBbe1xuICAgICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLkNvbnRhaW5lcnNbMF0sXG4gICAgICAgICAgICBWb2x1bWVNb3VudHM6IFt7XG4gICAgICAgICAgICAgIE1vdW50UGF0aDogJy9tb3VudC9wYXRoJyxcbiAgICAgICAgICAgICAgTmFtZTogJ2VtcHR5RGlyTmFtZScsXG4gICAgICAgICAgICAgIFJlYWRPbmx5OiBmYWxzZSxcbiAgICAgICAgICAgIH1dLFxuICAgICAgICAgIH1dLFxuICAgICAgICAgIFZvbHVtZXM6IFt7XG4gICAgICAgICAgICBOYW1lOiAnZW1wdHlEaXJOYW1lJyxcbiAgICAgICAgICAgIEVtcHR5RGlyOiB7XG4gICAgICAgICAgICAgIE1lZGl1bTogJycsXG4gICAgICAgICAgICAgIFNpemVMaW1pdDogJzIwNDhNaScsXG4gICAgICAgICAgICB9LFxuICAgICAgICAgIH1dLFxuICAgICAgICB9LFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG5cbiAgdGVzdCgncmVzcGVjdHMgaG9zdFBhdGggdm9sdW1lcycsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEVrc0pvYkRlZmluaXRpb24oc3RhY2ssICdFa3NKb2JEZWZuJywge1xuICAgICAgY29udGFpbmVyOiBuZXcgRWtzQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ0Vjc0VjMkNvbnRhaW5lcicsIHtcbiAgICAgICAgLi4uZGVmYXVsdENvbnRhaW5lclByb3BzLFxuICAgICAgICB2b2x1bWVzOiBbRWtzVm9sdW1lLmhvc3RQYXRoKHtcbiAgICAgICAgICBuYW1lOiAnaG9zdFBhdGhOYW1lJyxcbiAgICAgICAgICBob3N0UGF0aDogJ2hvc3RQYXRoUGF0aCcsXG4gICAgICAgICAgbW91bnRQYXRoOiAnL21vdW50L3BhdGgnLFxuICAgICAgICAgIHJlYWRvbmx5OiB0cnVlLFxuICAgICAgICB9KV0sXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgRWtzUHJvcGVydGllczoge1xuICAgICAgICBQb2RQcm9wZXJ0aWVzOiB7XG4gICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLFxuICAgICAgICAgIENvbnRhaW5lcnM6IFt7XG4gICAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMuQ29udGFpbmVyc1swXSxcbiAgICAgICAgICAgIFZvbHVtZU1vdW50czogW3tcbiAgICAgICAgICAgICAgTW91bnRQYXRoOiAnL21vdW50L3BhdGgnLFxuICAgICAgICAgICAgICBOYW1lOiAnaG9zdFBhdGhOYW1lJyxcbiAgICAgICAgICAgICAgUmVhZE9ubHk6IHRydWUsXG4gICAgICAgICAgICB9XSxcbiAgICAgICAgICB9XSxcbiAgICAgICAgICBWb2x1bWVzOiBbe1xuICAgICAgICAgICAgTmFtZTogJ2hvc3RQYXRoTmFtZScsXG4gICAgICAgICAgICBIb3N0UGF0aDoge1xuICAgICAgICAgICAgICBQYXRoOiAnaG9zdFBhdGhQYXRoJyxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfV0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcbl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ICAgICAgICAgICBWb2x1bWVNb3VudHM6IFt7XG4gICAgICAgICAgICAgIE1vdW50UGF0aDogJy9tb3VudC9wYXRoJyxcbiAgICAgICAgICAgICAgUmVhZE9ubHk6IHRydWUsXG4gICAgICAgICAgICB9XSxcbiAgICAgICAgICB9XSxcbiAgICAgICAgICBWb2x1bWVzOiBbe1xuICAgICAgICAgICAgTmFtZTogJ3NlY3JldFZvbHVtZU5hbWUnLFxuICAgICAgICAgICAgU2VjcmV0OiB7XG4gICAgICAgICAgICAgIFNlY3JldE5hbWU6ICdteUt1YmVTZWNyZXQnLFxuICAgICAgICAgICAgICBPcHRpb25hbDogdHJ1ZSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfV0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdyZXNwZWN0cyBhZGRWb2x1bWUoKSB3aXRoIGVtcHR5RGlyIHZvbHVtZScsICgpID0+IHtcbiAgICAvLyBHSVZFTlxuICAgIGNvbnN0IGpvYkRlZm4gPSBuZXcgRWtzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0Vrc0pvYkRlZm4nLCB7XG4gICAgICBjb250YWluZXI6IG5ldyBFa3NDb250YWluZXJEZWZpbml0aW9uKHN0YWNrLCAnRWNzRWMyQ29udGFpbmVyJywge1xuICAgICAgICAuLi5kZWZhdWx0Q29udGFpbmVyUHJvcHMsXG4gICAgICB9KSxcbiAgICB9KTtcblxuICAgIC8vIFdIRU5cbiAgICBqb2JEZWZuLmNvbnRhaW5lci5hZGRWb2x1bWUoRWtzVm9sdW1lLmVtcHR5RGlyKHtcbiAgICAgIG5hbWU6ICdlbXB0eURpck5hbWUnLFxuICAgICAgbWVkaXVtOiBFbXB0eURpck1lZGl1bVR5cGUuRElTSyxcbiAgICAgIG1vdW50UGF0aDogJy9tb3VudC9wYXRoJyxcbiAgICAgIHJlYWRvbmx5OiBmYWxzZSxcbiAgICAgIHNpemVMaW1pdDogU2l6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Y2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Sm9iRGVmaW5pdGlvbicsIHtcbiAgICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgICAgRWtzUHJvcGVydGllczoge1xuICAgICAgICBQb2RQcm9wZXJ0aWVzOiB7XG4gICAgICAgICAgLi4ucGFzY2FsQ2FzZUV4cGVjdGVkUHJvcHMuRWtzUHJvcGVydGllcy5Qb2RQcm9wZXJ0aWVzLFxuICAgICAgICAgIENvbnRhaW5lcnM6IFt7XG4gICAgICAgICAgICAuLi5wYXNjYWxDYXNlRXhwZWN0ZWRQcm9wcy5Fa3NQcm9wZXJ0aWVzLlBvZFByb3BlcnRpZXMuQ29udGFpbmVyc1swXSxcbiAgICAgICAgICAgIFZvbHVtZU1vdW50czogW3tcbiAgICAgICAgICAgICAgTW91bnRQYXRoOiAnL21vdW50L3BhdGgnLFxuICAgICAgICAgICAgICBOYW1lOiAnc2VjcmV0Vm9sdW1lTmFtZScsXG4gICAgICAgICAgICAgIFJlYWRPbmx5OiB0cnVlLFxuICAgICAgICAgICAgfV0sXG4gICAgICAgICAgfV0sXG4gICAgICAgICAgVm9sdW1lczogW3tcbiAgICAgICAgICAgIE5hbWU6ICdzZWNyZXRWb2x1bWVOYW1lJyxcbiAgICAgICAgICAgIFNlY3JldDoge1xuICAgICAgICAgICAgICBTZWNyZXROYW1lOiAnc2VjcmV0TmFtZScsXG4gICAgICAgICAgICAgIE9wdGlvbmFsOiBmYWxzZSxcbiAgICAgICAgICAgIH0sXG4gICAgICAgICAgfV0sXG4gICAgICAgIH0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js deleted file mode 100644 index 6a75c414d26d2..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/eks-job-definition.test.js +++ /dev/null @@ -1,72 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const lib_1 = require("../lib"); -test('EcsJobDefinition respects dnsPolicy', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - dnsPolicy: lib_1.DnsPolicy.CLUSTER_FIRST, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - EksProperties: { - PodProperties: { - DnsPolicy: lib_1.DnsPolicy.CLUSTER_FIRST, - }, - }, - }); -}); -test('EcsJobDefinition respects useHostNetwork', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - useHostNetwork: true, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - EksProperties: { - PodProperties: { - HostNetwork: true, - }, - }, - }); -}); -test('EcsJobDefinition respects serviceAccount', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.EksJobDefinition(stack, 'EKSJobDefn', { - container: new lib_1.EksContainerDefinition(stack, 'EksContainer', { - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - serviceAccount: 'my-service-account', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - EksProperties: { - PodProperties: { - ServiceAccountName: 'my-service-account', - }, - }, - }); -}); -test('can be imported from ARN', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - const importedJob = lib_1.EksJobDefinition.fromEksJobDefinitionArn(stack, 'importedJobDefinition', 'arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); - // THEN - expect(importedJob.jobDefinitionArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-definition/job-def-name:1'); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZWtzLWpvYi1kZWZpbml0aW9uLnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJla3Mtam9iLWRlZmluaXRpb24udGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsNkNBQW9DO0FBQ3BDLGdDQUE2RTtBQUU3RSxJQUFJLENBQUMscUNBQXFDLEVBQUUsR0FBRyxFQUFFO0lBQy9DLFFBQVE7SUFDUixNQUFNLEtBQUssR0FBRyxJQUFJLG1CQUFLLEVBQUUsQ0FBQztJQUUxQixPQUFPO0lBQ1AsSUFBSSxzQkFBZ0IsQ0FBQyxLQUFLLEVBQUUsWUFBWSxFQUFFO1FBQ3hDLFNBQVMsRUFBRSxJQUFJLDRCQUFzQixDQUFDLEtBQUssRUFBRSxjQUFjLEVBQUU7WUFDM0QsS0FBSyxFQUFFLEdBQUcsQ0FBQyxjQUFjLENBQUMsWUFBWSxDQUFDLDBCQUEwQixDQUFDO1NBQ25FLENBQUM7UUFDRixTQUFTLEVBQUUsZUFBUyxDQUFDLGFBQWE7S0FDbkMsQ0FB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9wZXJ0aWVzKCdBV1M6OkJhdGNoOjpKb2JEZWZpbml0aW9uJywge1xuICAgIEVrc1Byb3BlcnRpZXM6IHtcbiAgICAgIFBvZFByb3BlcnRpZXM6IHtcbiAgICAgICAgU2VydmljZUFjY291bnROYW1lOiAnbXktc2VydmljZS1hY2NvdW50JyxcbiAgICAgIH0sXG4gICAgfSxcbiAgfSk7XG59KTtcblxudGVzdCgnY2FuIGJlIGltcG9ydGVkIGZyb20gQVJOJywgKCkgPT4ge1xuICAvLyBHSVZFTlxuICBjb25zdCBzdGFjayA9IG5ldyBTdGFjaygpO1xuXG4gIC8vIFdIRU5cbiAgY29uc3QgaW1wb3J0ZWRKb2IgPSBFa3NKb2JEZWZpbml0aW9uLmZyb21Fa3NKb2JEZWZpbml0aW9uQXJuKHN0YWNrLCAnaW1wb3J0ZWRKb2JEZWZpbml0aW9uJyxcbiAgICAnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOmpvYi1kZWZpbml0aW9uL2pvYi1kZWYtbmFtZToxJyk7XG5cbiAgLy8gVEhFTlxuICBleHBlY3QoaW1wb3J0ZWRKb2Iuam9iRGVmaW5pdGlvbkFybikudG9FcXVhbCgnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOmpvYi1kZWZpbml0aW9uL2pvYi1kZWYtbmFtZToxJyk7XG59KTtcblxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js deleted file mode 100644 index 5d9e85af3e008..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.batch-unique-name.js +++ /dev/null @@ -1,34 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const events = require("aws-cdk-lib/aws-events"); -const targets = require("aws-cdk-lib/aws-events-targets"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const batch = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -const jobQueue = new batch.JobQueue(stack, 'MyQueue', { - computeEnvironments: [ - { - computeEnvironment: new batch.UnmanagedComputeEnvironment(stack, 'ComputeEnvironment'), - order: 1, - }, - ], -}); -const jobDefinition = new batch.EcsJobDefinition(stack, 'MyJob', { - container: new batch.EcsEc2ContainerDefinition(stack, 'container', { - image: aws_ecs_1.ContainerImage.fromRegistry('test-repo'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), -}); -const rule = new events.Rule(stack, 'Rule', { - schedule: events.Schedule.expression('rate(1 minute)'), -}); -rule.addTarget(new targets.BatchJob(jobQueue.jobQueueArn, jobQueue, jobDefinition.jobDefinitionArn, jobDefinition)); -new integ.IntegTest(app, 'BatchUniqueNameTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuYmF0Y2gtdW5pcXVlLW5hbWUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbnRlZy5iYXRjaC11bmlxdWUtbmFtZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLGlEQUFxRDtBQUNyRCw2Q0FBK0M7QUFDL0MsaURBQWlEO0FBQ2pELDBEQUEwRDtBQUMxRCxvREFBb0Q7QUFDcEQsZ0NBQWdDO0FBRWhDLE1BQU0sR0FBRyxHQUFHLElBQUksaUJ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kRlZmluaXRpb24oc3RhY2ssICdNeUpvYicsIHtcbiAgY29udGFpbmVyOiBuZXcgYmF0Y2guRWNzRWMyQ29udGFpbmVyRGVmaW5pdGlvbihzdGFjaywgJ2NvbnRhaW5lcicsIHtcbiAgICBpbWFnZTogQ29udGFpbmVySW1hZ2UuZnJvbVJlZ2lzdHJ5KCd0ZXN0LXJlcG8nKSxcbiAgICBjcHU6IDI1NixcbiAgICBtZW1vcnk6IFNpemUubWViaWJ5dGVzKDIwNDgpLFxuICB9KSxcbn0pO1xuXG5jb25zdCBydWxlID0gbmV3IGV2ZW50cy5SdWxlKHN0YWNrLCAnUnVsZScsIHtcbiAgc2NoZWR1bGU6IGV2ZW50cy5TY2hlZHVsZS5leHByZXNzaW9uKCdyYXRlKDEgbWludXRlKScpLFxufSk7XG5cbnJ1bGUuYWRkVGFyZ2V0KG5ldyB0YXJnZXRzLkJhdGNoSm9iKFxuICBqb2JRdWV1ZS5qb2JRdWV1ZUFybixcbiAgam9iUXVldWUsXG4gIGpvYkRlZmluaXRpb24uam9iRGVmaW5pdGlvbkFybixcbiAgam9iRGVmaW5pdGlvbixcbikpO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoVW5pcXVlTmFtZVRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js deleted file mode 100644 index acacc540d2191..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.ecs-job-definition.js +++ /dev/null @@ -1,94 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); -const efs = require("aws-cdk-lib/aws-efs"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const ssm = require("aws-cdk-lib/aws-ssm"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const batch = require("../lib"); -const aws_ecr_assets_1 = require("aws-cdk-lib/aws-ecr-assets"); -const path = require("path"); -const secretsmanager = require("aws-cdk-lib/aws-secretsmanager"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); -new batch.EcsJobDefinition(stack, 'ECSJobDefn', { - container: new batch.EcsEc2ContainerDefinition(stack, 'myContainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - environment: { - foo: 'bar', - }, - gpu: 12, - volumes: [ - batch.EcsVolume.host({ - name: 'volumeName', - hostPath: '/foo/bar', - containerPath: 'ahhh', - }), - batch.EcsVolume.efs({ - fileSystem: new efs.FileSystem(stack, 'myFileSystem', { - vpc, - }), - name: 'efsVolume', - containerPath: '/my/path', - }), - ], - ulimits: [{ - hardLimit: 50, - name: batch.UlimitName.CORE, - softLimit: 10, - }], - secrets: { - MY_SECRET_ENV_VAR: batch.Secret.fromSecretsManager(new secretsmanager.Secret(stack, 'mySecret')), - ANOTHER_ONE: batch.Secret.fromSecretsManagerVersion(new secretsmanager.Secret(stack, 'anotherSecret'), { - versionId: 'foo', - versionStage: 'bar', - }), - SSM_TIME: batch.Secret.fromSsmParameter(new ssm.StringParameter(stack, 'ssm', { stringValue: 'myString' })), - }, - }), -}); -new batch.EcsJobDefinition(stack, 'ECSFargateJobDefn', { - container: new batch.EcsFargateContainerDefinition(stack, 'myFargateContainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - cpu: 16, - memory: aws_cdk_lib_1.Size.mebibytes(32768), - ephemeralStorageSize: aws_cdk_lib_1.Size.gibibytes(100), - fargatePlatformVersion: aws_ecs_1.FargatePlatformVersion.LATEST, - }), - jobDefinitionName: 'foofoo', - parameters: { - foo: 'bar', - }, - propagateTags: true, - retryAttempts: 5, - retryStrategies: [ - new batch.RetryStrategy(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER), - new batch.RetryStrategy(batch.Action.RETRY, batch.Reason.NON_ZERO_EXIT_CODE), - new batch.RetryStrategy(batch.Action.EXIT, batch.Reason.custom({ - onExitCode: '40*', - onReason: 'reason', - onStatusReason: 'statusreason', - })), - ], - schedulingPriority: 10, - timeout: aws_cdk_lib_1.Duration.minutes(10), -}); -new batch.EcsJobDefinition(stack, 'ECSDockerJobDefn', { - container: new batch.EcsEc2ContainerDefinition(stack, 'EcsDockerContainer', { - cpu: 16, - memory: aws_cdk_lib_1.Size.mebibytes(32768), - image: ecs.ContainerImage.fromDockerImageAsset(new aws_ecr_assets_1.DockerImageAsset(stack, 'dockerImageAsset', { - directory: path.join(__dirname, 'batchjob-image'), - })), - }), -}); -new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuZWNzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcuZWNzLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQTBDO0FBQzFDLGlEQUE2RTtBQUM3RSwyQ0FBMkM7QUFDM0M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YXNvbicsXG4gICAgfSkpLFxuICBdLFxuICBzY2hlZHVsaW5nUHJpb3JpdHk6IDEwLFxuICB0aW1lb3V0OiBEdXJhdGlvbi5taW51dGVzKDEwKSxcbn0pO1xuXG5uZXcgYmF0Y2guRWNzSm9iRGVmaW5pdGlvbihzdGFjaywgJ0VDU0RvY2tlckpvYkRlZm4nLCB7XG4gIGNvbnRhaW5lcjogbmV3IGJhdGNoLkVjc0VjMkNvbnRhaW5lckRlZmluaXRpb24oc3RhY2ssICdFY3NEb2NrZXJDb250YWluZXInLCB7XG4gICAgY3B1OiAxNixcbiAgICBtZW1vcnk6IFNpemUubWViaWJ5dGVzKDMyNzY4KSxcbiAgICBpbWFnZTogZWNzLkNvbnRhaW5lckltYWdlLmZyb21Eb2NrZXJJbWFnZUFzc2V0KG5ldyBEb2NrZXJJbWFnZUFzc2V0KHN0YWNrLCAnZG9ja2VySW1hZ2VBc3NldCcsIHtcbiAgICAgIGRpcmVjdG9yeTogcGF0aC5qb2luKF9fZGlybmFtZSwgJ2JhdGNoam9iLWltYWdlJyksXG4gICAgfSkpLFxuICB9KSxcbn0pO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoRWNzSm9iRGVmaW5pdGlvblRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js deleted file mode 100644 index ec09421f64761..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.eks-job-definition.js +++ /dev/null @@ -1,59 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const batch = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -new batch.EksJobDefinition(stack, 'EksJobDefn', { - container: new batch.EksContainerDefinition(stack, 'EksContainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - args: ['foo'], - command: ['echo foo'], - env: { foo: 'bar' }, - cpuLimit: 8, - cpuReservation: 4, - memoryLimit: aws_cdk_lib_1.Size.mebibytes(8192), - memoryReservation: aws_cdk_lib_1.Size.mebibytes(8192), - gpuLimit: 12, - gpuReservation: 12, - imagePullPolicy: batch.ImagePullPolicy.ALWAYS, - name: 'myBigCoolVolume', - privileged: true, - readonlyRootFilesystem: false, - runAsGroup: 1, - runAsRoot: false, - runAsUser: 20, - volumes: [ - batch.EksVolume.emptyDir({ - name: 'woah', - mountPath: '/mount/path', - medium: batch.EmptyDirMediumType.MEMORY, - readonly: true, - sizeLimit: aws_cdk_lib_1.Size.mebibytes(2048), - }), - batch.EksVolume.secret({ - name: 'secretVolumeName', - secretName: 'secretName', - mountPath: '/secret/path', - optional: false, - }), - batch.EksVolume.secret({ - name: 'defaultOptionalSettingSecretVolume', - secretName: 'NewSecretName', - mountPath: '/secret/path2', - }), - batch.EksVolume.hostPath({ - name: 'hostPath', - hostPath: '/foo/bar', - mountPath: '/fooasdfadfs', - }), - ], - }), -}); -new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuZWtzLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmN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udFBhdGg6ICcvZm9vYXNkZmFkZnMnLFxuICAgICAgfSksXG4gICAgXSxcbiAgfSksXG59KTtcblxubmV3IGludGVnLkludGVnVGVzdChhcHAsICdCYXRjaEVjc0pvYkRlZmluaXRpb25UZXN0Jywge1xuICB0ZXN0Q2FzZXM6IFtzdGFja10sXG59KTtcblxuYXBwLnN5bnRoKCk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js deleted file mode 100644 index 96eab371eb46c..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.grants.js +++ /dev/null @@ -1,35 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const iam = require("aws-cdk-lib/aws-iam"); -const batch = require("../lib"); -const lib_1 = require("../lib"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); -const queue = new batch.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'managedEc2CE', { - vpc, - }), - order: 1, - }], - priority: 10, -}); -const ecsJob = new batch.EcsJobDefinition(stack, 'ECSJob', { - container: new batch.EcsEc2ContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('foorepo/fooimage'), - }), -}); -const user = new iam.User(stack, 'MyUser'); -ecsJob.grantSubmitJob(user, queue); -new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuZ3JhbnRzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcuZ3JhbnRzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQTBDO0FBQzFDLDZDQUErQztBQUMvQyxvREFBb0Q7QUFDcEQsMkNBQTJDO0FBQzNDLGdDQUFnQztBQUNoQyxnQ0FBeUQ7QUFDekQsMkNBQTJDO0FBRTNDLE1BQU0sR0FBRyxHQUFHLElBQUksaUJBQUcsRUFBRSxDQUFDO0FBQ3RCLE1BQU0sS0FBSyxHQUFHLElBQUksbUJBQUssQ0FBQyxHQUFHLEVBQUUsT0FBTyxDQUFDLENBQUM7QUFDdEMsTUFBTSxHQUFHLEdBQUcsSUFBSSxhQUFHLENBQUMsS0FBSyxFQUFFLEtBQUssRUFBRSxFQUFFLDRCQUE0QixFQUFFLEtBQUssRUFBRSxDQUFDLENBQUM7QUFFM0UsTUFBTSxLQUFLLEdBQUcsSUFBSSxLQUFLLENBQUMsUUFBUSxDQUFDLEtBQUssRUFBRSxPQUFPLEVBQUU7SUFDL0MsbUJBQW1CLEVBQUUsQ0FBQztZQUNwQixrQkFBa0IsRUFBRSxJQUFJLHFDQUErQixDQUFDLEtBQUssRUFBRSxjQUFjLEVBQUU7Z0JBQzdFLEdBQUc7YUFDSixDQUFDO1lBQ0YsS0FBSyxFQUFFLENBQUM7U0FDVCxDQUFDO0lBQ0YsUUFBUSxFQUFFLEVBQUU7Q0FDYixDQUFDLENBQUM7QUFFSCxNQUFNLE1BQU0sR0FBRyxJQUFJLEtBQUssQ0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1Rlc3QoYXBwLCAnQmF0Y2hFY3NKb2JEZWZpbml0aW9uVGVzdCcsIHtcbiAgdGVzdENhc2VzOiBbc3RhY2tdLFxufSk7XG5cbmFwcC5zeW50aCgpO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js deleted file mode 100644 index 5798e3b70f7e9..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.job-queue.js +++ /dev/null @@ -1,41 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const batch = require("../lib"); -const lib_1 = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -const vpc = new aws_ec2_1.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); -const fairsharePolicy = new batch.FairshareSchedulingPolicy(stack, 'fairshare', { - computeReservation: 75, - schedulingPolicyName: 'joBBQFairsharePolicy', - shareDecay: aws_cdk_lib_1.Duration.hours(1), - shares: [{ - shareIdentifier: 'shareA', - weightFactor: 0.5, - }], -}); -const queue = new batch.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'managedEc2CE', { - vpc, - }), - order: 1, - }], - priority: 10, - schedulingPolicy: fairsharePolicy, -}); -fairsharePolicy.addShare({ - shareIdentifier: 'shareB', - weightFactor: 7, -}); -queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'newManagedEc2CE', { - vpc, -}), 2); -new integ.IntegTest(app, 'BatchEcsJobDefinitionTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcuam9iLXF1ZXVlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcuam9iLXF1ZXVlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQTBDO0FBQzFDLDZDQUFtRDtBQUNuRCxvREFBb0Q7QUFDcEQsZ0NBQWdDO0FBQ2hDLGdDQUF5RDtBQUV6RCxNQUFNLEdBQUcsR0FBRyxJQUFJLGlCQUFHLEVBQUUsQ0FBQztBQUN0QixNQUFNLEtBQUssR0FBRyxJQUFJLG1CQUFLLENBQUMsR0FBRyxFQUFFLE9BQU8sQ0FBQyxDQUFDO0FBQ3RDLE1BQU0sR0FBRyxHQUFHLElBQUksYUFBRyxDQUFDLEtBQUssRUFBRSxLQUFLLEVBQUUsRUFBRSw0QkFBNEIsRUFBRSxLQUFLLEVBQUUsQ0FBQyxDQUFDO0FBRTNFLE1BQU0sZUFBZSxHQUFHLElBQUksS0FBSyxDQUFDLHlCQUF5QixDQUFDLEtBQUssRUFBRSxXQUFXLEVBQUU7SUFDOUUsa0JBQWtCLEVBQUUsRUFBRTtJQUN0QixvQkFBb0IsRUFBRSxzQkFBc0I7SUFDNUMsVUFBVSxFQUFFLHNCQUFRLENBQUMsS0FBSyxDQUFDLENBQUMsQ0FBQztJQUM3QixNQUFNLEVBQUUsQ0FBQztZQUNQLGVBQWUsRUFBRSxRQUFRO1lBQ3pCLFlBQVksRUFBRSxHQUFHO1NBQ2xCLENBQUM7Q0FDSCxDQUFDLENBQUM7QUFFSCxNQUFNLEtBQUssR0FBRyxJQUFJLEtBQUssQ0FBQyxRQUFRLENBQUMsS0FBS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B1dGVFbnZpcm9ubWVudChzdGFjaywgJ25ld01hbmFnZWRFYzJDRScsIHtcbiAgICB2cGMsXG4gIH0pLFxuICAyLFxuKTtcblxubmV3IGludGVnLkludGVnVGVzdChhcHAsICdCYXRjaEVjc0pvYkRlZmluaXRpb25UZXN0Jywge1xuICB0ZXN0Q2FzZXM6IFtzdGFja10sXG59KTtcblxuYXBwLnN5bnRoKCk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js deleted file mode 100644 index 29a0fed0681b9..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.managed-compute-environment.js +++ /dev/null @@ -1,78 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const lib_1 = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'batch-stack'); -const vpc = new ec2.Vpc(stack, 'vpc', { restrictDefaultSecurityGroup: false }); -new lib_1.FargateComputeEnvironment(stack, 'minimalPropsFargate', { - vpc, - maxvCpus: 512, -}); -new lib_1.FargateComputeEnvironment(stack, 'maximalPropsFargate', { - vpc, - maxvCpus: 512, - computeEnvironmentName: 'maxPropsFargateCE', - replaceComputeEnvironment: true, - spot: true, - terminateOnUpdate: true, - updateTimeout: aws_cdk_lib_1.Duration.minutes(30), - updateToLatestImageVersion: false, -}); -new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'minimalPropsEc2', { - vpc, - images: [{ - image: new ec2.AmazonLinuxImage(), - }], -}); -new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'LaunchTemplate', { - vpc, - images: [{ - image: new ec2.AmazonLinuxImage(), - }], - allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, - minvCpus: 256, - maxvCpus: 512, - replaceComputeEnvironment: true, - terminateOnUpdate: false, - placementGroup: new ec2.PlacementGroup(stack, 'placementGroup'), - updateTimeout: aws_cdk_lib_1.Duration.hours(1), - launchTemplate: new aws_ec2_1.LaunchTemplate(stack, 'launchTemplate'), -}); -new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SpotEc2', { - vpc, - images: [{ - image: new ec2.AmazonLinuxImage(), - }], - spot: true, - spotBidPercentage: 95, - spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { - assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), - }), -}); -new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'AllocationStrategySPOT_CAPACITY', { - vpc, - images: [{ - image: new ec2.AmazonLinuxImage(), - }], - spot: true, - spotBidPercentage: 95, - allocationStrategy: lib_1.AllocationStrategy.SPOT_CAPACITY_OPTIMIZED, -}); -const taggedEc2Ecs = new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'taggedCE', { - vpc, - images: [{ - image: new ec2.AmazonLinuxImage(), - }], -}); -aws_cdk_lib_1.Tags.of(taggedEc2Ecs).add('foo', 'bar'); -aws_cdk_lib_1.Tags.of(taggedEc2Ecs).add('super', 'salamander'); -new integ.IntegTest(app, 'BatchManagedComputeEnvironmentTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcubWFuYWdlZC1jb21wdXRlLWVudmlyb25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/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js deleted file mode 100644 index 5c3d60fee788b..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.multinode-job-definition.js +++ /dev/null @@ -1,48 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const aws_ecs_1 = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const batch = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'stack'); -new batch.MultiNodeJobDefinition(stack, 'SingleContainerMultiNodeJob', { - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - containers: [{ - startNode: 0, - endNode: 10, - container: new batch.EcsEc2ContainerDefinition(stack, 'myContainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }], - propagateTags: true, -}); -const multinodeJob = new batch.MultiNodeJobDefinition(stack, 'MultiContainerMultiNodeJob', { - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - containers: [{ - startNode: 0, - endNode: 10, - container: new batch.EcsEc2ContainerDefinition(stack, 'multinodecontainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), - }], -}); -multinodeJob.addContainer({ - startNode: 11, - endNode: 20, - container: new batch.EcsEc2ContainerDefinition(stack, 'multiContainer', { - image: aws_ecs_1.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - }), -}); -new integ.IntegTest(app, 'BatchMultiNodeJobDefinitionTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcubXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaW50ZWcubXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsaURBQWdGO0FBQ2hGLGlEQUFxRDtBQUNyRCw2Q0FBK0M7QUFDL0Msb0RBQW9EO0FBQ3BELGdDQUFnQztBQUVoQyxNQUFNLEdBQUcsR0FBRyxJQUFJLGlCQUFHLEVBQUUsQ0FBQztBQUN0QixNQUFNLEtBQUssR0FBRyxJQUFJLG1CQUFLLENBQUMsR0FBRyxFQUFFLE9BQU8sQ0FBQyxDQUFDO0FBRXRDLElBQUksS0FBSyxDQUFDLHNCQUFzQixDQUFDLEtBQUssRUFBRSw2QkFBNkIsRUFBRTtJQUNyRSxZQUFZLEVBQUUsc0JBQVksQ0FBQyxFQUFFLENBQUMsdUJBQWEsQ0FBQyxFQUFFLEVBQUUsc0JBQVksQ0FBQyxLQUFLLENBQUM7SUFDbkUsVUFBVSxFQUFFLENBQUM7WUFDWCxTQUFTLEVBQUUsQ0FBQztZQUNaLE9BQU8sRUFBRSxFQUFFO1lBQ1gsU0FBUyxFQUFFLElBQUksS0FBSyxDQUFDLHlCQUF5QixDQUFDLEtBQUssRUFBRSxhQUFhLEVBQUU7Z0JBQ25FLEtBQU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haW5lckltYWdlLmZyb21SZWdpc3RyeSgnYW1hem9uL2FtYXpvbi1lY3Mtc2FtcGxlJyksXG4gICAgY3B1OiAyNTYsXG4gICAgbWVtb3J5OiBTaXplLm1lYmlieXRlcygyMDQ4KSxcbiAgfSksXG59KTtcblxubmV3IGludGVnLkludGVnVGVzdChhcHAsICdCYXRjaE11bHRpTm9kZUpvYkRlZmluaXRpb25UZXN0Jywge1xuICB0ZXN0Q2FzZXM6IFtzdGFja10sXG59KTtcblxuYXBwLnN5bnRoKCk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js b/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js deleted file mode 100644 index 55a17c9cfbbe7..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/integ.unmanaged-compute-environment.js +++ /dev/null @@ -1,25 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const integ = require("@aws-cdk/integ-tests-alpha"); -const lib_1 = require("../lib"); -const app = new aws_cdk_lib_1.App(); -const stack = new aws_cdk_lib_1.Stack(app, 'batch-stack'); -new lib_1.UnmanagedComputeEnvironment(stack, 'minimalProps'); -new lib_1.UnmanagedComputeEnvironment(stack, 'maximalProps', { - computeEnvironmentName: 'unmanagedIntegTestCE', - enabled: true, - unmanagedvCpus: 256, - serviceRole: new aws_iam_1.Role(stack, 'IntegServiceRole', { - managedPolicies: [ - aws_iam_1.ManagedPolicy.fromAwsManagedPolicyName('service-role/AWSBatchServiceRole'), - ], - assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), - }), -}); -new integ.IntegTest(app, 'BatchManagedComputeEnvironmentTest', { - testCases: [stack], -}); -app.synth(); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZWcudW5tYW5hZ2VkLWNvbXB1dGUtZW52aXJvbm1lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbnRlZy51bm1hbmFnZWQtY29tcHV0ZS1lbnZpcm9ubWVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLGlEQUE0RTtBQUM1RSw2Q0FBeUM7QUFDekMsb0RBQW9EO0FBQ3BELGdDQUFxRDtBQUVyRCxNQUFNLEdBQUcsR0FBRyxJQUFJLGlCQUFHLEVBQUUsQ0FBQztBQUN0QixNQUFNLEtBQUssR0FBRyxJQUFJLG1CQUFLLENBQUMsR0FBRyxFQUFFLGFBQWEsQ0FBQyxDQUFDO0FBRTVDLElBQUksaUNBQTJCLENBQUMsS0FBSyxFQUFFLGNBQWMsQ0FBQyxDQUFDO0FBRXZELElBQUksaUNBQTJCLENBQUMsS0FBSyxFQUFFLGNBQWMsRUFBRTtJQUNyRCxzQkFBc0IsRUFBRSxzQkFBc0I7SUFDOUMsT0FBTyxFQUFFLElBQUk7SUFDYixjQUFjLEVBQUUsR0FBRztJQUNuQixXQUFXLEVBQUUsSUFBSSxjQUFJLENBQUMsS0FBSyxFQUFFLGtCQUFrQixFQUFFO1FBQy9DLGVBQWUsRUFBRTtZQUNmLHVCQUFhLENBQUMsd0JBQXdCLENBQUMsa0NBQWtDLENBQUM7U0FDM0U7UUFDRCxTQUFTLEVBQUUsSUFBSSwwQkFBZ0IsQ0FBQyxxQkFBcUIsQ0FBQztLQUN2RCxDQUFDO0NBQ0gsQ0FBQyxDQUFDO0FBRUgsSUFBSSxLQUFLLENBQUM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pLFxuICAgIF0sXG4gICAgYXNzdW1lZEJ5OiBuZXcgU2VydmljZVByaW5jaXBhbCgnYmF0Y2guYW1hem9uYXdzLmNvbScpLFxuICB9KSxcbn0pO1xuXG5uZXcgaW50ZWcuSW50ZWdUZXN0KGFwcCwgJ0JhdGNoTWFuYWdlZENvbXB1dGVFbnZpcm9ubWVudFRlc3QnLCB7XG4gIHRlc3RDYXNlczogW3N0YWNrXSxcbn0pO1xuXG5hcHAuc3ludGgoKTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js b/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js deleted file mode 100644 index 5a3ad995469b0..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/job-definition-base.test.js +++ /dev/null @@ -1,205 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const utils_1 = require("./utils"); -const batch = require("../lib"); -const defaultExpectedEcsProps = { - type: 'container', - platformCapabilities: [batch.Compatibility.EC2], -}; -const defaultExpectedEksProps = { - type: 'container', -}; -const defaultExpectedMultiNodeProps = { - type: 'multinode', -}; -let stack; -let pascalCaseExpectedEcsProps; -let pascalCaseExpectedEksProps; -let pascalCaseExpectedMultiNodeProps; -let defaultEcsProps; -let defaultEksProps; -let defaultMultiNodeProps; -let expectedProps; -let defaultProps; -describe.each([batch.EcsJobDefinition, batch.EksJobDefinition, batch.MultiNodeJobDefinition])('%p type JobDefinition', (JobDefinition) => { - // GIVEN - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); - pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); - pascalCaseExpectedMultiNodeProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedMultiNodeProps); - defaultEcsProps = { - container: new batch.EcsEc2ContainerDefinition(stack, 'EcsContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - }; - defaultEksProps = { - container: new batch.EksContainerDefinition(stack, 'EksContainer', { - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - }; - defaultMultiNodeProps = { - containers: [{ - container: new batch.EcsEc2ContainerDefinition(stack, 'MultinodeEcsContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 0, - endNode: 10, - }], - mainNode: 0, - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - }; - switch (JobDefinition) { - case batch.EcsJobDefinition: - expectedProps = pascalCaseExpectedEcsProps; - defaultProps = defaultEcsProps; - break; - case batch.EksJobDefinition: - expectedProps = pascalCaseExpectedEksProps; - defaultProps = defaultEksProps; - break; - case batch.MultiNodeJobDefinition: - expectedProps = pascalCaseExpectedMultiNodeProps; - defaultProps = defaultMultiNodeProps; - break; - } - }); - test('JobDefinition respects name', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - jobDefinitionName: 'myEcsJob', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - JobDefinitionName: 'myEcsJob', - }); - }); - test('JobDefinition respects parameters', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - parameters: { - foo: 'bar', - }, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - Parameters: { - foo: 'bar', - }, - }); - }); - test('JobDefinition respects retryAttempts', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - retryAttempts: 8, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - RetryStrategy: { - Attempts: 8, - }, - }); - }); - test('JobDefinition respects retryStrategies', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - retryStrategies: [ - batch.RetryStrategy.of(batch.Action.EXIT, batch.Reason.CANNOT_PULL_CONTAINER), - batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.NON_ZERO_EXIT_CODE), - batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.SPOT_INSTANCE_RECLAIMED), - batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.custom({ - onExitCode: '40*', - onReason: 'reason*', - onStatusReason: 'statusReason', - })), - ], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - RetryStrategy: { - EvaluateOnExit: [ - { - Action: 'EXIT', - OnReason: 'CannotPullContainerError:*', - }, - { - Action: 'RETRY', - OnExitCode: '*', - }, - { - Action: 'RETRY', - OnStatusReason: 'Host EC2*', - }, - { - Action: 'RETRY', - OnExitCode: '40*', - OnReason: 'reason*', - OnStatusReason: 'statusReason', - }, - ], - }, - }); - }); - test('JobDefinition respects schedulingPriority', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - schedulingPriority: 10, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - SchedulingPriority: 10, - }); - }); - test('JobDefinition respects schedulingPriority', () => { - // WHEN - new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - timeout: aws_cdk_lib_1.Duration.minutes(10), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - Timeout: { - AttemptDurationSeconds: 600, - }, - }); - }); - test('JobDefinition respects addRetryStrategy()', () => { - // WHEN - const jobDefn = new JobDefinition(stack, 'JobDefn', { - ...defaultProps, - }); - jobDefn.addRetryStrategy(batch.RetryStrategy.of(batch.Action.RETRY, batch.Reason.SPOT_INSTANCE_RECLAIMED)); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - ...expectedProps, - RetryStrategy: { - EvaluateOnExit: [ - { - Action: 'RETRY', - OnStatusReason: 'Host EC2*', - }, - ], - }, - }); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiam9iLWRlZmluaXRpb24tYmFzZS50ZXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiam9iLWRlZmluaXRpb24tYmFzZS50ZXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUEsdURBQWtEO0FBQ2xELGlEQUFnRjtBQUNoRiwyQ0FBMkM7QUFDM0MsNkNBQTZEO0FBQzdELG1DQUFrRDtBQUNsRCxnQ0FBZ0M7QUFHaEMsTUFBTSx1QkFBdUIsR0FBMEI7SUFDckQsSUFBSSxFQUFFLFdBQVc7SUFDakIsb0JBQW9CLEVBQUUsQ0FBQyxLQUFLLENBQUMsYUFBYSxDQUFDLEdBQUcsQ0FBQztDQUNoRCxDQUFDO0FBQ0YsTUFBTSx1QkFBdUIsR0FBMEI7SUFDckQsSUFBSSxFQUFFLFdBQVc7Q0FDbEIsQ0FBQztBQUNGLE1BQU0sNkJBQTZCLEdBQTBCO0lBQzNELElBQUksRUFBRSxXQUFXO0NBQ2xCLENBQUM7QUFFRixJQUFJLEt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gVEhFTlxuICAgIFRlbXBsYXRlLmZyb21TdGFjayhzdGFjaykuaGFzUmVzb3VyY2VQcm9wZXJ0aWVzKCdBV1M6OkJhdGNoOjpKb2JEZWZpbml0aW9uJywge1xuICAgICAgLi4uZXhwZWN0ZWRQcm9wcyxcbiAgICAgIFJldHJ5U3RyYXRlZ3k6IHtcbiAgICAgICAgRXZhbHVhdGVPbkV4aXQ6IFtcbiAgICAgICAgICB7XG4gICAgICAgICAgICBBY3Rpb246ICdFWElUJyxcbiAgICAgICAgICAgIE9uUmVhc29uOiAnQ2Fubm90UHVsbENvbnRhaW5lckVycm9yOionLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25FeGl0Q29kZTogJyonLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25TdGF0dXNSZWFzb246ICdIb3N0IEVDMionLFxuICAgICAgICAgIH0sXG4gICAgICAgICAge1xuICAgICAgICAgICAgQWN0aW9uOiAnUkVUUlknLFxuICAgICAgICAgICAgT25FeGl0Q29kZTogJzQwKicsXG4gICAgICAgICAgICBPblJlYXNvbjogJ3JlYXNvbionLFxuICAgICAgICAgICAgT25TdGF0dXNSZWFzb246ICdzdGF0dXNSZWFzb24nLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIH0pO1xuICB9KTtcblxuICB0ZXN0KCdKb2JEZWZpbml0aW9uIHJlc3BlY3RzIHNjaGVkdWxpbmdQcmlvcml0eScsICgpID0+IHtcbiAgICAvLyBXSEVOXG4gICAgbmV3IEpvYkRlZmluaXRpb24oc3RhY2ssICdKb2JEZWZuJywge1xuICAgICAgLi4uZGVmYXVsdFByb3BzLFxuICAgICAgc2NoZWR1bGluZ1ByaW9yaXR5OiAxMCxcbiAgICB9KTtcblxuICAgIC8vIFRIRU5cb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kVDTEFJTUVEKSk7XG5cbiAgICAvLyBUSEVOXG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKS5oYXNSZXNvdXJjZVByb3BlcnRpZXMoJ0FXUzo6QmF0Y2g6OkpvYkRlZmluaXRpb24nLCB7XG4gICAgICAuLi5leHBlY3RlZFByb3BzLFxuICAgICAgUmV0cnlTdHJhdGVneToge1xuICAgICAgICBFdmFsdWF0ZU9uRXhpdDogW1xuICAgICAgICAgIHtcbiAgICAgICAgICAgIEFjdGlvbjogJ1JFVFJZJyxcbiAgICAgICAgICAgIE9uU3RhdHVzUmVhc29uOiAnSG9zdCBFQzIqJyxcbiAgICAgICAgICB9LFxuICAgICAgICBdLFxuICAgICAgfSxcbiAgICB9KTtcbiAgfSk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js b/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js deleted file mode 100644 index b15482f2d3cc1..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/job-queue.test.js +++ /dev/null @@ -1,228 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const lib_1 = require("../lib"); -test('JobQueue respects computeEnvironments', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - new lib_1.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { - vpc, - }), - order: 1, - }], - priority: 10, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { - ComputeEnvironmentOrder: [{ - ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, - Order: 1, - }], - Priority: 10, - State: 'ENABLED', - }); -}); -test('JobQueue respects enabled', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - new lib_1.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { - vpc, - }), - order: 1, - }], - priority: 10, - enabled: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { - ComputeEnvironmentOrder: [{ - ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, - Order: 1, - }], - Priority: 10, - State: 'DISABLED', - }); -}); -test('JobQueue respects name', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - new lib_1.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { - vpc, - }), - order: 1, - }], - priority: 10, - jobQueueName: 'JoBBQ', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { - ComputeEnvironmentOrder: [{ - ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, - Order: 1, - }], - Priority: 10, - JobQueueName: 'JoBBQ', - }); -}); -test('JobQueue name is parsed from arn', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - const queue = new lib_1.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { - vpc, - }), - order: 1, - }], - priority: 10, - jobQueueName: 'JoBBQ', - }); - // THEN - expect(aws_cdk_lib_1.Tokenization.resolve(queue.jobQueueName, { - scope: stack, - resolver: new aws_cdk_lib_1.DefaultTokenResolver(new aws_cdk_lib_1.StringConcat()), - })).toEqual({ - 'Fn::Select': [ - 1, - { - 'Fn::Split': [ - '/', - { - 'Fn::Select': [ - 5, - { - 'Fn::Split': [ - ':', - { - 'Fn::GetAtt': [ - 'joBBQ9FD52DAF', - 'JobQueueArn', - ], - }, - ], - }, - ], - }, - ], - }, - ], - }); -}); -test('JobQueue respects schedulingPolicy', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - new lib_1.JobQueue(stack, 'JobQueue', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'CE', { - vpc, - }), - order: 1, - }], - priority: 10, - schedulingPolicy: new lib_1.FairshareSchedulingPolicy(stack, 'FairsharePolicy'), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { - ComputeEnvironmentOrder: [{ - ComputeEnvironment: { 'Fn::GetAtt': ['CE1BFE03A1', 'ComputeEnvironmentArn'] }, - Order: 1, - }], - Priority: 10, - SchedulingPolicyArn: { - 'Fn::GetAtt': ['FairsharePolicyA0C549BE', 'Arn'], - }, - }); -}); -test('JobQueue respects addComputeEnvironment', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - const queue = new lib_1.JobQueue(stack, 'JobQueue', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'FirstCE', { - vpc, - }), - order: 1, - }], - priority: 10, - schedulingPolicy: new lib_1.FairshareSchedulingPolicy(stack, 'FairsharePolicy'), - }); - queue.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SecondCE', { - vpc, - }), 2); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobQueue', { - ComputeEnvironmentOrder: [ - { - ComputeEnvironment: { 'Fn::GetAtt': ['FirstCEAD3794AD', 'ComputeEnvironmentArn'] }, - Order: 1, - }, - { - ComputeEnvironment: { 'Fn::GetAtt': ['SecondCEEBA93938', 'ComputeEnvironmentArn'] }, - Order: 2, - }, - ], - Priority: 10, - SchedulingPolicyArn: { - 'Fn::GetAtt': ['FairsharePolicyA0C549BE', 'Arn'], - }, - }); -}); -test('can be imported from ARN', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - const queue = lib_1.JobQueue.fromJobQueueArn(stack, 'importedJobQueue', 'arn:aws:batch:us-east-1:123456789012:job-queue/importedJobQueue'); - // THEN - expect(queue.jobQueueArn).toEqual('arn:aws:batch:us-east-1:123456789012:job-queue/importedJobQueue'); -}); -test('JobQueue throws when the same order is assigned to multiple ComputeEnvironments', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - const vpc = new ec2.Vpc(stack, 'vpc'); - // WHEN - const joBBQ = new lib_1.JobQueue(stack, 'joBBQ', { - computeEnvironments: [{ - computeEnvironment: new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'FirstCE', { - vpc, - }), - order: 1, - }], - priority: 10, - }); - joBBQ.addComputeEnvironment(new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'SecondCE', { - vpc, - }), 1); - expect(() => { - assertions_1.Template.fromStack(stack); - }).toThrow(/assigns the same order to different ComputeEnvironments/); -}); -test('JobQueue throws when there are no linked ComputeEnvironments', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.JobQueue(stack, 'joBBQ'); - expect(() => { - assertions_1.Template.fromStack(stack); - }).toThrow(/This JobQueue does not link any ComputeEnvironments/); -}); -//# sourceMappingURL=data:application/json;base64,eyJ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HNjb3BlOiBzdGFjayxcbiAgICByZXNvbHZlcjogbmV3IERlZmF1bHRUb2tlblJlc29sdmVyKG5ldyBTdHJpbmdDb25jYXQoKSksXG4gIH0pKS50b0VxdWFsKHtcbiAgICAnRm46OlNlbGVjdCc6IFtcbiAgICAgIDEsXG4gICAgICB7XG4gICAgICAgICdGbjo6U3BsaXQnOiBbXG4gICAgICAgICAgJy8nLFxuICAgICAgICAgIHtcbiAgICAgICAgICAgICdGbjo6U2VsZWN0JzogW1xuICAgICAgICAgICAgICA1LFxuICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgJ0ZuOjpTcGxpdCc6IFtcbiAgICAgICAgICAgICAgICAgICc6JyxcbiAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgJ0ZuOjpHZXRBdHQnOiBbXG4gICAgICAgICAgICAgICAgICAgICAgJ2pvQkJROUZENTJEQUYnLFxuICAgICAgICAgICAgICAgICAgICAgICdKb2JRdWV1ZUFybicsXG4gICAgICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIF0sXG4gICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICBdLFxuICAgICAgICAgIH0sXG4gICAgICAgIF0sXG4gICAgICB9LFxuICAgIF0sXG4gIH0pO1xufSk7XG5cbnRlc3QoJ0pvYlF1ZXVlIHJlc3BlY3RzIHNjaGVkdWxpbmdQb2xpY3knLCAoKSA9PiB7XG4gIC8vIEdJVkVOXG4gIGNvbnN0IHN0YWNrID0gbmV3IFN0YWNrKCk7XG4gIGNvbnN0IHZwYyA9IG5ldyBlYzIuVnBjKHN0YWNrLCAndnBjJyk7XG5cbiAgLy8gV0hFTlxuICBuZXcgSm9iUXVldWUoc3RhY2ssICdKb2JRdWV1ZScsIHtcbiAgICBjb21wdXRlRW52aXJvbm1lbnRzOiBbe1xuICAgICAgY29tcHV0ZUVudmlyb25tZW50OiBuZXcgTWFuYWdlZEVjMkVjc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I6IDEsXG4gICAgfV0sXG4gICAgcHJpb3JpdHk6IDEwLFxuICB9KTtcblxuICBqb0JCUS5hZGRDb21wdXRlRW52aXJvbm1lbnQoXG4gICAgbmV3IE1hbmFnZWRFYzJFY3NDb21wdXRlRW52aXJvbm1lbnQoc3RhY2ssICdTZWNvbmRDRScsIHtcbiAgICAgIHZwYyxcbiAgICB9KSxcbiAgICAxLFxuICApO1xuXG4gIGV4cGVjdCgoKSA9PiB7XG4gICAgVGVtcGxhdGUuZnJvbVN0YWNrKHN0YWNrKTtcbiAgfSkudG9UaHJvdygvYXNzaWducyB0aGUgc2FtZSBvcmRlciB0byBkaWZmZXJlbnQgQ29tcHV0ZUVudmlyb25tZW50cy8pO1xufSk7XG5cbnRlc3QoJ0pvYlF1ZXVlIHRocm93cyB3aGVuIHRoZXJlIGFyZSBubyBsaW5rZWQgQ29tcHV0ZUVudmlyb25tZW50cycsICgpID0+IHtcbiAgLy8gR0lWRU5cbiAgY29uc3Qgc3RhY2sgPSBuZXcgU3RhY2soKTtcblxuICAvLyBXSEVOXG4gIG5ldyBKb2JRdWV1ZShzdGFjaywgJ2pvQkJRJyk7XG5cbiAgZXhwZWN0KCgpID0+IHtcbiAgICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spO1xuICB9KS50b1Rocm93KC9UaGlzIEpvYlF1ZXVlIGRvZXMgbm90IGxpbmsgYW55IENvbXB1dGVFbnZpcm9ubWVudHMvKTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js b/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js deleted file mode 100644 index 012dc0b22f7ed..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/managed-compute-environment.test.js +++ /dev/null @@ -1,860 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const ec2 = require("aws-cdk-lib/aws-ec2"); -const eks = require("aws-cdk-lib/aws-eks"); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const utils_1 = require("./utils"); -const batch = require("../lib"); -const lib_1 = require("../lib"); -const defaultExpectedEcsProps = { - type: 'managed', - computeEnvironmentName: undefined, - serviceRole: undefined, - state: 'ENABLED', - eksConfiguration: undefined, - computeResources: { - allocationStrategy: lib_1.AllocationStrategy.BEST_FIT_PROGRESSIVE, - bidPercentage: undefined, - desiredvCpus: undefined, - maxvCpus: 256, - type: 'EC2', - ec2Configuration: undefined, - minvCpus: 0, - subnets: [ - { Ref: 'vpcPrivateSubnet1Subnet934893E8' }, - { Ref: 'vpcPrivateSubnet2Subnet7031C2BA' }, - ], - ec2KeyPair: undefined, - imageId: undefined, - instanceRole: { 'Fn::GetAtt': ['MyCEInstanceProfile6D69963F', 'Arn'] }, - instanceTypes: ['optimal'], - launchTemplate: undefined, - placementGroup: undefined, - securityGroupIds: [{ - 'Fn::GetAtt': ['MyCESecurityGroup81DCAA06', 'GroupId'], - }], - spotIamFleetRole: undefined, - updateToLatestImageVersion: true, - }, - replaceComputeEnvironment: false, -}; -const defaultExpectedEksProps = { - ...defaultExpectedEcsProps, - eksConfiguration: { - eksClusterArn: { - 'Fn::GetAtt': ['eksTestCluster1B416C0E', 'Arn'], - }, - kubernetesNamespace: 'cdk-test-namespace', - }, -}; -let stack; -let vpc; -let pascalCaseExpectedEcsProps; -let pascalCaseExpectedEksProps; -let defaultComputeResources; -let defaultEcsProps; -let defaultEksProps; -let expectedProps; -let defaultProps; -describe.each([lib_1.ManagedEc2EcsComputeEnvironment, lib_1.ManagedEc2EksComputeEnvironment])('%p type ComputeEnvironment', (ComputeEnvironment) => { - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - vpc = new ec2.Vpc(stack, 'vpc'); - pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); - pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); - defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; - defaultEcsProps = { - vpc, - }; - defaultEksProps = { - vpc, - kubernetesNamespace: 'cdk-test-namespace', - eksCluster: new eks.Cluster(stack, 'eksTestCluster', { - version: eks.KubernetesVersion.V1_24, - }), - }; - expectedProps = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment - ? pascalCaseExpectedEcsProps - : pascalCaseExpectedEksProps; - defaultProps = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment - ? defaultEcsProps - : defaultEksProps; - }); - test('default props', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::InstanceProfile', { - Roles: [{ Ref: 'MyCEInstanceProfileRole895D248D' }], - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - AssumeRolePolicyDocument: { - Statement: [{ - Action: 'sts:AssumeRole', - Effect: 'Allow', - Principal: { Service: 'ec2.amazonaws.com' }, - }], - Version: '2012-10-17', - }, - }); - }); - test('can specify maxvCpus', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - maxvCpus: 512, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - MaxvCpus: 512, - }, - }); - }); - test('can specify minvCpus', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - minvCpus: 8, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - MinvCpus: 8, - }, - }); - }); - test('can be disabled', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - enabled: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - State: 'DISABLED', - }); - }); - test('spot => AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spot: true, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - Type: 'SPOT', - AllocationStrategy: 'SPOT_PRICE_CAPACITY_OPTIMIZED', - }, - }); - }); - test('images are correctly rendered as EC2ConfigurationObjects', () => { - const expectedImageType = ComputeEnvironment === lib_1.ManagedEc2EcsComputeEnvironment - ? batch.EcsMachineImageType.ECS_AL2 - : batch.EksMachineImageType.EKS_AL2; - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - images: [ - { - image: ec2.MachineImage.latestAmazonLinux2(), - }, - ], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - Ec2Configuration: [ - { - ImageIdOverride: { Ref: 'SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amikernel510hvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter' }, - ImageType: expectedImageType, - }, - ], - }, - }); - }); - test('instance classes are correctly rendered', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - instanceClasses: [ec2.InstanceClass.R4], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - InstanceTypes: [ - 'r4', - 'optimal', - ], - }, - }); - }); - test('instance types are correctly rendered', () => { - // WHEN - const ce = new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.R4, ec2.InstanceSize.LARGE)], - }); - ce.addInstanceClass(ec2.InstanceClass.M4); - ce.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.C4, ec2.InstanceSize.LARGE)); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - InstanceTypes: [ - 'r4.large', - 'c4.large', - 'm4', - 'optimal', - ], - }, - }); - }); - test('respects useOptimalInstanceClasses: false', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - useOptimalInstanceClasses: false, - instanceClasses: [ec2.InstanceClass.R4], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - InstanceTypes: [ - 'r4', - ], - }, - }); - }); - test('does not throw with useOptimalInstanceClasses: false and a call to addInstanceClass()', () => { - // WHEN - const myCE = new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - useOptimalInstanceClasses: false, - }); - myCE.addInstanceClass(ec2.InstanceClass.C4); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - InstanceTypes: [ - 'c4', - ], - }, - }); - }); - test('does not throw with useOptimalInstanceClasses: false and a call to addInstanceType()', () => { - // WHEN - const myCE = new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - useOptimalInstanceClasses: false, - }); - myCE.addInstanceType(ec2.InstanceType.of(ec2.InstanceClass.C4, ec2.InstanceSize.XLARGE112)); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - InstanceTypes: [ - 'c4.112xlarge', - ], - }, - }); - }); - test('creates and uses instanceProfile, even when instanceRole is specified', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - instanceRole: new aws_iam_1.Role(stack, 'myRole', { - assumedBy: new aws_iam_1.ServicePrincipal('foo.amazonaws.com', { - region: 'bermuda-triangle-1337', - }), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - // instanceRole is unchanged from default - }, - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::InstanceProfile', { - Roles: [{ Ref: 'myRoleE60D68E8' }], - }); - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - AssumeRolePolicyDocument: { - Statement: [{ - Action: 'sts:AssumeRole', - Effect: 'Allow', - Principal: { Service: 'foo.amazonaws.com' }, - }], - Version: '2012-10-17', - }, - }); - }); - test('respects launch template', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - launchTemplate: new ec2.LaunchTemplate(stack, 'launchTemplate'), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - LaunchTemplate: { - LaunchTemplateId: { Ref: 'launchTemplateDEE5742D' }, - }, - }, - }); - }); - test('respects name', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - computeEnvironmentName: 'NamedCE', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeEnvironmentName: 'NamedCE', - ComputeResources: { - ...defaultComputeResources, - }, - }); - }); - test('respects placement group', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - placementGroup: new ec2.PlacementGroup(stack, 'myPlacementGroup'), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - PlacementGroup: { - 'Fn::GetAtt': ['myPlacementGroup2E94D14E', 'GroupName'], - }, - }, - }); - }); - test('respects replaceComputeEnvironment', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - replaceComputeEnvironment: true, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - }, - ReplaceComputeEnvironment: true, - }); - }); - test('respects security groups', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - securityGroups: [new ec2.SecurityGroup(stack, 'TestSG', { - vpc, - allowAllOutbound: false, - })], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - SecurityGroupIds: [{ - 'Fn::GetAtt': ['TestSG581D3391', 'GroupId'], - }], - }, - }); - }); - test('respects service role', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - serviceRole: new aws_iam_1.Role(stack, 'TestSLR', { - assumedBy: new aws_iam_1.ServicePrincipal('cdk.amazonaws.com'), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ServiceRole: { - 'Fn::GetAtt': ['TestSLR05974C22', 'Arn'], - }, - ComputeResources: { - ...defaultComputeResources, - }, - }); - }); - test('respects vpcSubnets', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpcSubnets: { - subnets: [new ec2.Subnet(stack, 'testSubnet', { - availabilityZone: 'az-3', - cidrBlock: '10.0.0.0/32', - vpcId: new ec2.Vpc(stack, 'subnetVpc').vpcId, - })], - }, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - Subnets: [ - { Ref: 'testSubnet42F0FA0C' }, - ], - }, - }); - }); - test('respects updateTimeout', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - updateTimeout: aws_cdk_lib_1.Duration.minutes(1), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - }, - UpdatePolicy: { - JobExecutionTimeoutMinutes: 1, - }, - }); - }); - test('respects terminateOnUpdate', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - terminateOnUpdate: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - }, - UpdatePolicy: { - TerminateJobsOnUpdate: false, - }, - }); - }); - test('respects updateToLatestImageVersion', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - updateToLatestImageVersion: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - UpdateToLatestImageVersion: false, - }, - }); - }); - test('respects tags', () => { - // WHEN - const ce = new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - }); - aws_cdk_lib_1.Tags.of(ce).add('superfood', 'acai'); - aws_cdk_lib_1.Tags.of(ce).add('super', 'salamander'); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...expectedProps, - ComputeResources: { - ...defaultComputeResources, - Tags: { - superfood: 'acai', - super: 'salamander', - }, - }, - }); - }); - test('can be imported from arn', () => { - // WHEN - const ce = lib_1.ManagedEc2EcsComputeEnvironment.fromManagedEc2EcsComputeEnvironmentArn(stack, 'import', 'arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); - // THEN - expect(ce.computeEnvironmentArn).toEqual('arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); - }); - test('attach necessary managed policy to instance role', () => { - // WHEN - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::IAM::Role', { - ManagedPolicyArns: [ - { - 'Fn::Join': [ - '', - [ - 'arn:', - { - Ref: 'AWS::Partition', - }, - ':iam::aws:policy/service-role/AmazonEC2ContainerServiceforEC2Role', - ], - ], - }, - ], - }); - }); - test('throws when no instance types are provided', () => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - useOptimalInstanceClasses: false, - vpc, - }); - expect(() => { - assertions_1.Template.fromStack(stack); - }).toThrow(/Specifies 'useOptimalInstanceClasses: false' without specifying any instance types or classes/); - }); - test('throws error when AllocationStrategy.SPOT_CAPACITY_OPTIMIZED is used without specfiying spot', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - allocationStrategy: lib_1.AllocationStrategy.SPOT_CAPACITY_OPTIMIZED, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'AllocationStrategy.SPOT_CAPACITY_OPTIMIZED' without using spot instances/); - }); - test('throws error when AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED is used without specfiying spot', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - allocationStrategy: lib_1.AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED' without using spot instances/); - }); - test('throws error when spotBidPercentage is specified without spot', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spotBidPercentage: 80, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' without specifying 'spot'/); - }); - test('throws error when spotBidPercentage is specified and spot is false', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spotBidPercentage: 80, - spot: false, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' without specifying 'spot'/); - }); - test('throws error when spotBidPercentage > 100', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spotBidPercentage: 120, - spot: true, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' > 100/); - }); - test('throws error when spotBidPercentage < 0', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spotBidPercentage: -120, - spot: true, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotBidPercentage' < 0/); - }); - test('throws error when minvCpus > maxvCpus', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - maxvCpus: 512, - minvCpus: 1024, - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' has 'minvCpus' = 1024 > 'maxvCpus' = 512; 'minvCpus' cannot be greater than 'maxvCpus'/); - }); - test('throws error when minvCpus < 0', () => { - // THEN - expect(() => { - new ComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - minvCpus: -256, - }); - }).toThrowError(/Managed ComputeEnvironment 'MyCE' has 'minvCpus' = -256 < 0; 'minvCpus' cannot be less than zero/); - }); -}); -describe('ManagedEc2EcsComputeEnvironment', () => { - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - vpc = new ec2.Vpc(stack, 'vpc'); - pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); - pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); - defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; - defaultEcsProps = { - vpc, - }; - defaultEksProps = { - vpc, - kubernetesNamespace: 'cdk-test-namespace', - eksCluster: new eks.Cluster(stack, 'eksTestCluster', { - version: eks.KubernetesVersion.V1_24, - }), - }; - }); - test('respects spotFleetRole', () => { - // WHEN - new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { - ...defaultEcsProps, - spot: true, - spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { - assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:magicuser/foobar'), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEcsProps, - ComputeResources: { - ...defaultComputeResources, - AllocationStrategy: lib_1.AllocationStrategy.SPOT_PRICE_CAPACITY_OPTIMIZED, - Type: 'SPOT', - SpotIamFleetRole: { - 'Fn::GetAtt': ['SpotFleetRole6D4F7558', 'Arn'], - }, - }, - }); - }); - test('image types are correctly rendered as EC2ConfigurationObjects', () => { - // WHEN - new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { - ...defaultEcsProps, - vpc, - images: [ - { - imageType: batch.EcsMachineImageType.ECS_AL2_NVIDIA, - }, - ], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEcsProps, - ComputeResources: { - ...defaultComputeResources, - Ec2Configuration: [ - { - ImageType: 'ECS_AL2_NVIDIA', - }, - ], - }, - }); - }); - test('can use non-default allocation strategy', () => { - // WHEN - new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEcsProps, - ComputeResources: { - ...defaultComputeResources, - AllocationStrategy: 'BEST_FIT', - }, - }); - }); - test('spot and AllocationStrategy.BEST_FIT => a default spot fleet role is created', () => { - // WHEN - new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - vpc, - spot: true, - allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEcsProps, - ComputeResources: { - ...defaultComputeResources, - Type: 'SPOT', - AllocationStrategy: 'BEST_FIT', - SpotIamFleetRole: { 'Fn::GetAtt': ['MyCESpotFleetRole70BE30A0', 'Arn'] }, - }, - }); - }); - test('throws when spotFleetRole is specified without spot', () => { - // WHEN - expect(() => { - new lib_1.ManagedEc2EcsComputeEnvironment(stack, 'MyCE', { - ...defaultEcsProps, - spotFleetRole: new aws_iam_1.Role(stack, 'SpotFleetRole', { - assumedBy: new aws_iam_1.ArnPrincipal('arn:aws:iam:123456789012:magicuser/foobar'), - }), - }); - }).toThrow(/Managed ComputeEnvironment 'MyCE' specifies 'spotFleetRole' without specifying 'spot'/); - }); -}); -describe('ManagedEc2EksComputeEnvironment', () => { - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - vpc = new ec2.Vpc(stack, 'vpc'); - pascalCaseExpectedEcsProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEcsProps); - pascalCaseExpectedEksProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedEksProps); - defaultComputeResources = pascalCaseExpectedEcsProps.ComputeResources; - defaultEcsProps = { - vpc, - }; - defaultEksProps = { - vpc, - kubernetesNamespace: 'cdk-test-namespace', - eksCluster: new eks.Cluster(stack, 'eksTestCluster', { - version: eks.KubernetesVersion.V1_24, - }), - }; - }); - test('default props', () => { - // WHEN - new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { - ...defaultEksProps, - vpc, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEksProps, - ComputeResources: { - ...defaultComputeResources, - }, - }); - }); - test('throws error when AllocationStrategy.BEST_FIT is used', () => { - // THEN - expect(() => { - new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { - ...defaultProps, - allocationStrategy: lib_1.AllocationStrategy.BEST_FIT, - }); - }).toThrow(/ManagedEc2EksComputeEnvironment 'MyCE' uses invalid allocation strategy 'AllocationStrategy.BEST_FIT'/); - }); - test('image types are correctly rendered as EC2ConfigurationObjects', () => { - // WHEN - new lib_1.ManagedEc2EksComputeEnvironment(stack, 'MyCE', { - ...defaultEksProps, - vpc, - images: [ - { - imageType: batch.EksMachineImageType.EKS_AL2_NVIDIA, - }, - ], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedEksProps, - ComputeResources: { - ...defaultComputeResources, - Ec2Configuration: [ - { - ImageType: 'EKS_AL2_NVIDIA', - }, - ], - }, - }); - }); -}); -describe('FargateComputeEnvironment', () => { - beforeEach(() => { - stack = new aws_cdk_lib_1.Stack(); - vpc = new ec2.Vpc(stack, 'vpc'); - }); - test('respects name', () => { - // WHEN - new lib_1.FargateComputeEnvironment(stack, 'maximalPropsFargate', { - vpc, - maxvCpus: 512, - computeEnvironmentName: 'maxPropsFargateCE', - replaceComputeEnvironment: true, - spot: true, - terminateOnUpdate: true, - updateTimeout: aws_cdk_lib_1.Duration.minutes(30), - updateToLatestImageVersion: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ComputeEnvironmentName: 'maxPropsFargateCE', - }); - }); - test('can be imported from arn', () => { - // WHEN - const ce = lib_1.FargateComputeEnvironment.fromFargateComputeEnvironmentArn(stack, 'import', 'arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); - // THEN - expect(ce.computeEnvironmentArn).toEqual('arn:aws:batch:us-east-1:123456789012:compute-environment/ce-name'); - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFuYWdlZC1jb21wdXRlLWVudmlyb25tZW50LnRlc3QuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJtYW5hZ2VkLWNvbXB1dGUtZW52aXJvbm1lbnQudGVzdC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBLHVEQUFrRDtBQUNsRCwyQ0FBMkM7QUFDM0MsMkNBQTJDO0FBQzNDLGlEQUEyRTtBQUMzRSw2Q0FBb0Q7QUFDcEQsbUNBQWtEO0FBQ2xELGdDQUFnQztBQUNoQyxnQ0FBcU47QUFHck4sTUFBTSx1QkFBdUIsR0FBK0I7SUFDMUQsSUFBSSxFQUFFLFNBQVM7SUFDZixzQkFBc0IsRUFBRSxTQUFTO0lBQ2pDLFdBQVcsRUFBRSxTQUFTO0lBQ3RCLEtBQUssRUFBRSxTQUFTO0lBQ2hCLGdCQUFnQixFQUFFLFNBQVM7SUFDM0IsZ0JBQWdCLEVBQUU7UUFDaEIsa0JBQWtCLEVBQUUsd0JBQWtCLENBQUMsb0JBQW9CO1FBQzNELGFBQWEsRUFBRSxTQUFTO1FBQ3hCLFlBQVksRUFBRSxTQUFTO1FBQ3ZCLFFBQVEsRUFBRSxHQUFHO1FBQ2IsSUFBSSxFQUFFLEtBQUs7UUFDWCxnQkFBZ0IsRUFBRSxTQUFTO1FBQzNCLFFBQVEsRUFBRSxDQUFDO1FBQ1gsT0FBTyxFQUFFO1lBQ1AsRUFBRSxHQUFHLEVBQUUsaUNBQWlDLEVBQVM7WUFDakQsRUFBRSxHQUFHLEVBQUUsaUNBQWlDLEVBQVM7U0FDbEQ7UUFDRCxVQUFVLEVBQUUsU0FBUztRQUNyQixPQUFPLEVBQUUsU0FBUztRQUNs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ydCcsICdhcm46YXdzOmJhdGNoOnVzLWVhc3QtMToxMjM0NTY3ODkwMTI6Y29tcHV0ZS1lbnZpcm9ubWVudC9jZS1uYW1lJyk7XG5cbiAgICAvLyBUSEVOXG4gICAgZXhwZWN0KGNlLmNvbXB1dGVFbnZpcm9ubWVudEFybikudG9FcXVhbCgnYXJuOmF3czpiYXRjaDp1cy1lYXN0LTE6MTIzNDU2Nzg5MDEyOmNvbXB1dGUtZW52aXJvbm1lbnQvY2UtbmFtZScpO1xuICB9KTtcbn0pO1xuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js b/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js deleted file mode 100644 index 0120ecf9bd8eb..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/multinode-job-definition.test.js +++ /dev/null @@ -1,155 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const aws_ec2_1 = require("aws-cdk-lib/aws-ec2"); -const ecs = require("aws-cdk-lib/aws-ecs"); -const aws_cdk_lib_1 = require("aws-cdk-lib"); -const lib_1 = require("../lib"); -test('MultiNodeJobDefinition respects mainNode', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { - containers: [{ - container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 0, - endNode: 9, - }], - mainNode: 5, - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - NodeProperties: { - MainNode: 5, - NodeRangeProperties: [{ - Container: { - InstanceType: 'r4.large', - }, - TargetNodes: '0:9', - }], - NumNodes: 10, - }, - PlatformCapabilities: [lib_1.Compatibility.EC2], - }); -}); -test('EcsJobDefinition respects propagateTags', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { - propagateTags: true, - containers: [{ - container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 0, - endNode: 9, - }], - mainNode: 0, - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - PropagateTags: true, - }); -}); -test('MultiNodeJobDefinition one container', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { - containers: [{ - container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 0, - endNode: 9, - }], - mainNode: 0, - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - NodeProperties: { - MainNode: 0, - NodeRangeProperties: [{ - Container: { - InstanceType: 'r4.large', - }, - TargetNodes: '0:9', - }], - NumNodes: 10, - }, - PlatformCapabilities: [lib_1.Compatibility.EC2], - }); -}); -test('MultiNodeJobDefinition two containers', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { - containers: [ - { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer1', { - cpu: 256, - memory: aws_cdk_lib_1.Size.mebibytes(2048), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 0, - endNode: 9, - }, - { - container: new lib_1.EcsEc2ContainerDefinition(stack, 'MultinodeContainer2', { - cpu: 512, - memory: aws_cdk_lib_1.Size.mebibytes(4096), - image: ecs.ContainerImage.fromRegistry('amazon/amazon-ecs-sample'), - }), - startNode: 10, - endNode: 14, - }, - ], - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.R4, aws_ec2_1.InstanceSize.LARGE), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::JobDefinition', { - NodeProperties: { - MainNode: 0, - NodeRangeProperties: [ - { - Container: { - InstanceType: 'r4.large', - }, - TargetNodes: '0:9', - }, - { - Container: { - InstanceType: 'r4.large', - }, - TargetNodes: '10:14', - }, - ], - NumNodes: 15, - }, - PlatformCapabilities: [lib_1.Compatibility.EC2], - }); -}); -test('multinode job requires at least one container', () => { - // GIVEN - const stack = new aws_cdk_lib_1.Stack(); - // WHEN - new lib_1.MultiNodeJobDefinition(stack, 'ECSJobDefn', { - instanceType: aws_ec2_1.InstanceType.of(aws_ec2_1.InstanceClass.C4, aws_ec2_1.InstanceSize.LARGE), - }); - // THEN - expect(() => assertions_1.Template.fromStack(stack)).toThrow(/multinode job has no containers!/); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXVsdGlub2RlLWpvYi1kZWZpbml0aW9uLnRlc3Q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BJbnN0YW5jZVR5cGU6ICdyNC5sYXJnZScsXG4gICAgICAgICAgfSxcbiAgICAgICAgICBUYXJnZXROb2RlczogJzA6OScsXG4gICAgICAgIH0sXG4gICAgICAgIHtcbiAgICAgICAgICBDb250YWluZXI6IHtcbiAgICAgICAgICAgIEluc3RhbmNlVHlwZTogJ3I0LmxhcmdlJyxcbiAgICAgICAgICB9LFxuICAgICAgICAgIFRhcmdldE5vZGVzOiAnMTA6MTQnLFxuICAgICAgICB9LFxuXG4gICAgICBdLFxuICAgICAgTnVtTm9kZXM6IDE1LFxuICAgIH0sXG4gICAgUGxhdGZvcm1DYXBhYmlsaXRpZXM6IFtDb21wYXRpYmlsaXR5LkVDMl0sXG4gIH0pO1xufSk7XG5cbnRlc3QoJ211bHRpbm9kZSBqb2IgcmVxdWlyZXMgYXQgbGVhc3Qgb25lIGNvbnRhaW5lcicsICgpID0+IHtcbiAgLy8gR0lWRU5cbiAgY29uc3Qgc3RhY2sgPSBuZXcgU3RhY2soKTtcblxuICAvLyBXSEVOXG4gIG5ldyBNdWx0aU5vZGVKb2JEZWZpbml0aW9uKHN0YWNrLCAnRUNTSm9iRGVmbicsIHtcbiAgICBpbnN0YW5jZVR5cGU6IEluc3RhbmNlVHlwZS5vZihJbnN0YW5jZUNsYXNzLkM0LCBJbnN0YW5jZVNpemUuTEFSR0UpLFxuICB9KTtcblxuICAvLyBUSEVOXG4gIGV4cGVjdCgoKSA9PiBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spKS50b1Rocm93KC9tdWx0aW5vZGUgam9iIGhhcyBubyBjb250YWluZXJzIS8pO1xufSk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js b/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js deleted file mode 100644 index b15d5d7caa7f6..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/scheduling-policy.test.js +++ /dev/null @@ -1,133 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const core_1 = require("aws-cdk-lib/core"); -const lib_1 = require("../lib"); -test('empty fairshare policy', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy'); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - FairsharePolicy: { - ShareDistribution: [], - }, - }); -}); -test('fairshare policy respects computeReservation', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { - computeReservation: 75, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - FairsharePolicy: { - ComputeReservation: 75, - ShareDistribution: [], - }, - }); -}); -test('fairshare policy respects name', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { - schedulingPolicyName: 'FairsharePolicyName', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - Name: 'FairsharePolicyName', - FairsharePolicy: { - ShareDistribution: [], - }, - }); -}); -test('fairshare policy respects shareDecay', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { - shareDecay: core_1.Duration.hours(1), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - FairsharePolicy: { - ShareDecaySeconds: 3600, - ShareDistribution: [], - }, - }); -}); -test('fairshare policy respects shares', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { - shares: [ - { - shareIdentifier: 'myShareId', - weightFactor: 0.5, - }, - { - shareIdentifier: 'myShareId2', - weightFactor: 1, - }, - ], - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - FairsharePolicy: { - ShareDistribution: [ - { - ShareIdentifier: 'myShareId', - WeightFactor: 0.5, - }, - { - ShareIdentifier: 'myShareId2', - WeightFactor: 1, - }, - ], - }, - }); -}); -test('addShare() works', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - const policy = new lib_1.FairshareSchedulingPolicy(stack, 'schedulingPolicy', { - shares: [{ - shareIdentifier: 'myShareId', - weightFactor: 0.5, - }], - }); - policy.addShare({ - shareIdentifier: 'addedShareId', - weightFactor: 0.5, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::SchedulingPolicy', { - FairsharePolicy: { - ShareDistribution: [ - { - ShareIdentifier: 'myShareId', - WeightFactor: 0.5, - }, - { - ShareIdentifier: 'addedShareId', - WeightFactor: 0.5, - }, - ], - }, - }); -}); -test('can be imported from ARN', () => { - // GIVEN - const stack = new core_1.Stack(); - // WHEN - const policy = lib_1.FairshareSchedulingPolicy.fromFairshareSchedulingPolicyArn(stack, 'policyImport', 'arn:aws:batch:us-east-1:123456789012:scheduling-policy/policyImport'); - // THEN - expect(policy.schedulingPolicyArn).toEqual('arn:aws:batch:us-east-1:123456789012:scheduling-policy/policyImport'); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NoZWR1bGluZy1wb2xpY3kudGVzdC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbInNjaGVkdWxpbmctcG9saWN5LnRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSx1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eUltcG9ydCcpO1xuXG4gIC8vIFRIRU5cbiAgZXhwZWN0KHBvbGljeS5zY2hlZHVsaW5nUG9saWN5QXJuKS50b0VxdWFsKCdhcm46YXdzOmJhdGNoOnVzLWVhc3QtMToxMjM0NTY3ODkwMTI6c2NoZWR1bGluZy1wb2xpY3kvcG9saWN5SW1wb3J0Jyk7XG59KTtcbiJdfQ== \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts deleted file mode 100644 index cb0ff5c3b541f..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.d.ts +++ /dev/null @@ -1 +0,0 @@ -export {}; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js b/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js deleted file mode 100644 index 4c7fe0a2e433a..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/unmanaged-compute-environment.test.js +++ /dev/null @@ -1,90 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const assertions_1 = require("aws-cdk-lib/assertions"); -const aws_iam_1 = require("aws-cdk-lib/aws-iam"); -const core_1 = require("aws-cdk-lib/core"); -const utils_1 = require("./utils"); -const unmanaged_compute_environment_1 = require("../lib/unmanaged-compute-environment"); -const defaultExpectedProps = { - type: 'unmanaged', - computeEnvironmentName: undefined, - computeResources: undefined, - eksConfiguration: undefined, - replaceComputeEnvironment: undefined, - serviceRole: { - 'Fn::GetAtt': ['MyCEBatchServiceRole4FDA2CB6', 'Arn'], - }, - state: 'ENABLED', - tags: undefined, - unmanagedvCpus: undefined, - updatePolicy: undefined, -}; -let stack = new core_1.Stack(); -const pascalCaseExpectedProps = (0, utils_1.capitalizePropertyNames)(stack, defaultExpectedProps); -test('default props', () => { - // GIVEN - stack = new core_1.Stack(); - // WHEN - new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE'); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedProps, - }); -}); -test('respects enabled: false', () => { - // GIVEN - stack = new core_1.Stack(); - // WHEN - new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { - enabled: false, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedProps, - State: 'DISABLED', - }); -}); -test('respects name', () => { - // GIVEN - stack = new core_1.Stack(); - // WHEN - new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { - computeEnvironmentName: 'magic', - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedProps, - ComputeEnvironmentName: 'magic', - }); -}); -test('respects serviceRole', () => { - // GIVEN - stack = new core_1.Stack(); - // WHEN - new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { - serviceRole: new aws_iam_1.Role(stack, 'myMagicRole', { - assumedBy: new aws_iam_1.ServicePrincipal('batch.amazonaws.com'), - }), - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedProps, - ServiceRole: { - 'Fn::GetAtt': ['myMagicRole2BBD827A', 'Arn'], - }, - }); -}); -test('respects unmanagedvCpus', () => { - // GIVEN - stack = new core_1.Stack(); - // WHEN - new unmanaged_compute_environment_1.UnmanagedComputeEnvironment(stack, 'MyCE', { - unmanagedvCpus: 256, - }); - // THEN - assertions_1.Template.fromStack(stack).hasResourceProperties('AWS::Batch::ComputeEnvironment', { - ...pascalCaseExpectedProps, - UnmanagedvCpus: 256, - }); -}); -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidW5tYW5hZ2VkLWNvbXB1dGUtZW52aX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WVudChzdGFjaywgJ015Q0UnLCB7XG4gICAgdW5tYW5hZ2VkdkNwdXM6IDI1NixcbiAgfSk7XG5cbiAgLy8gVEhFTlxuICBUZW1wbGF0ZS5mcm9tU3RhY2soc3RhY2spLmhhc1Jlc291cmNlUHJvcGVydGllcygnQVdTOjpCYXRjaDo6Q29tcHV0ZUVudmlyb25tZW50Jywge1xuICAgIC4uLnBhc2NhbENhc2VFeHBlY3RlZFByb3BzLFxuICAgIFVubWFuYWdlZHZDcHVzOiAyNTYsXG4gIH0pO1xufSk7XG4iXX0= \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts b/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts deleted file mode 100644 index 934fcac4357e0..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/utils.d.ts +++ /dev/null @@ -1,6 +0,0 @@ -import { IConstruct } from 'constructs'; -/** - * Given an object, converts all keys to PascalCase given they are currently in camel case. - * @param obj The object. - */ -export declare function capitalizePropertyNames(construct: IConstruct, obj: any): any; diff --git a/packages/@aws-cdk/aws-batch-alpha/test/utils.js b/packages/@aws-cdk/aws-batch-alpha/test/utils.js deleted file mode 100644 index c804b15bf6337..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/test/utils.js +++ /dev/null @@ -1,28 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -exports.capitalizePropertyNames = void 0; -const aws_cdk_lib_1 = require("aws-cdk-lib"); -/** - * Given an object, converts all keys to PascalCase given they are currently in camel case. - * @param obj The object. - */ -function capitalizePropertyNames(construct, obj) { - const stack = aws_cdk_lib_1.Stack.of(construct); - obj = stack.resolve(obj); - if (typeof (obj) !== 'object') { - return obj; - } - if (Array.isArray(obj)) { - return obj.map(x => capitalizePropertyNames(construct, x)); - } - const newObj = {}; - for (const key of Object.keys(obj)) { - const value = obj[key]; - const first = key.charAt(0).toUpperCase(); - const newKey = first + key.slice(1); - newObj[newKey] = capitalizePropertyNames(construct, value); - } - return newObj; -} -exports.capitalizePropertyNames = capitalizePropertyNames; -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXRpbHMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJ1dGlscy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSw2Q0FBb0M7QUFHcEM7OztHQUdHO0FBQ0gsU0FBZ0IsdUJBQXVCLENBQUMsU0FBcUIsRUFBRSxHQUFRO0lBQ3JFLE1BQU0sS0FBSyxHQUFHLG1CQUFLLENBQUMsRUFBRSxDQUFDLFNBQVMsQ0FBQyxDQUFDO0lBQ2xDLEdBQUcsR0FBRyxLQUFLLENBQUMsT0FBTyxDQUFDLEdBQUcsQ0FBQyxDQUFDO0lBRXpCLElBQUksT0FBTSxDQUFDLEdBQUcsQ0FBQyxLQUFLLFFBQVEsRUFBRTtRQUM1QixPQUFPLEdBQUcsQ0FBQztLQUNaO0lBRUQsSUFBSSxLQUFLLENBQUMsT0FBTyxDQUFDLEdBQUcsQ0FBQyxFQUFFO1FBQ3RCLE9BQU8sR0FBRyxDQUFDLEdBQUcsQ0FBQyxDQUFDLENBQUMsRUFBRSxDQUFDLHVCQUF1QixDQUFDLFNBQVMsRUFBRSxDQUFDLENBQUMsQ0FBQyxDQUFDO0tBQzVEO0lBRUQsTUFBTSxNQUFNLEdBQVEsRUFBRyxDQUFDO0lBQ3hCLEtBQUssTUFBTSxHQUFHLElBQUksTUFBTSxDQUFDLElBQUksQ0FBQyxHQUFHLENBQUMsRUFBRTtRQUNsQyxNQUFNLEtBQUssR0FBRyxHQUFHLENBQUMsR0FBRyxDQUFDLENBQUM7UUFFdkIsTUFBTSxLQUFLLEdBQUcsR0FBRyxDQUFDLE1BQU0sQ0FBQyxDQUFDLENBQUMsQ0FBQyxXQUFXLEVBQUUsQ0FBQztRQUMxQyxNQUFNLE1BQU0sR0FBRyxLQUFLLEdBQUcsR0FBRyxDQ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oYXJBdCgwKS50b1VwcGVyQ2FzZSgpO1xuICAgIGNvbnN0IG5ld0tleSA9IGZpcnN0ICsga2V5LnNsaWNlKDEpO1xuICAgIG5ld09ialtuZXdLZXldID0gY2FwaXRhbGl6ZVByb3BlcnR5TmFtZXMoY29uc3RydWN0LCB2YWx1ZSk7XG4gIH1cblxuICByZXR1cm4gbmV3T2JqO1xufVxuIl19 \ No newline at end of file diff --git a/packages/@aws-cdk/aws-batch-alpha/tsconfig.json b/packages/@aws-cdk/aws-batch-alpha/tsconfig.json deleted file mode 100644 index 00315950564fd..0000000000000 --- a/packages/@aws-cdk/aws-batch-alpha/tsconfig.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "compilerOptions": { - "declarationMap": false, - "inlineSourceMap": true, - "inlineSources": true, - "alwaysStrict": true, - "declaration": true, - "experimentalDecorators": true, - "incremental": true, - "lib": [ - "es2020" - ], - "module": "CommonJS", - "noEmitOnError": true, - "noFallthroughCasesInSwitch": true, - "noImplicitAny": true, - "noImplicitReturns": true, - "noImplicitThis": true, - "noUnusedLocals": true, - "noUnusedParameters": true, - "resolveJsonModule": true, - "skipLibCheck": true, - "strict": true, - "strictNullChecks": true, - "strictPropertyInitialization": true, - "stripInternal": false, - "target": "ES2020", - "composite": true, - "tsBuildInfoFile": "tsconfig.tsbuildinfo" - }, - "include": [ - "**/*.ts" - ], - "exclude": [ - "node_modules", - ".types-compat" - ], - "references": [ - { - "path": "../../../tools/@aws-cdk/cdk-build-tools" - }, - { - "path": "../integ-runner" - }, - { - "path": "../../../tools/@aws-cdk/pkglint" - }, - { - "path": "../integ-tests-alpha" - } - ], - "_generated_by_jsii_": "Generated by jsii - safe to delete, and ideally should be in .gitignore" -} \ No newline at end of file diff --git a/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts b/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts index 896a8105d2e3a..e97e45bf48689 100644 --- a/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts +++ b/packages/@aws-cdk/integ-runner/test/workers/integ-worker.test.ts @@ -222,7 +222,7 @@ describe('parallel worker', () => { const results = await runIntegrationTestsInParallel({ pool, tests, - regions: ['us-west-2'], + regions: ['us-east-1'], }); expect(stderrMock.mock.calls[0][0]).toContain( @@ -408,7 +408,7 @@ describe('parallel worker', () => { const results = await runIntegrationTestsInParallel({ tests, pool, - regions: ['us-west-2'], + regions: ['us-east-1'], }); expect(stderrMock.mock.calls[1][0]).toContain( From 7a950faa9c85a0c0bd2da94a881bbf0a79533119 Mon Sep 17 00:00:00 2001 From: Michael Sambol Date: Tue, 12 Sep 2023 18:58:27 -0500 Subject: [PATCH 4/7] remove these too --- .../manifest.json | 237 ------------------ ...e782b91873a033a2af81afb07f38cf38ec67ea.zip | Bin 310 -> 0 bytes 2 files changed, 237 deletions(-) delete mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json delete mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json deleted file mode 100644 index 169010b153254..0000000000000 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json +++ /dev/null @@ -1,237 +0,0 @@ -{ - "version": "34.0.0", - "artifacts": { - "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets": { - "type": "cdk:asset-manifest", - "properties": { - "file": "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "aws-cdk-codepipeline-elastic-beanstalk-deploy": { - "type": "aws:cloudformation:stack", - "environment": "aws://unknown-account/unknown-region", - "properties": { - "templateFile": "aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json", - "validateOnSynth": false, - "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", - "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", - "additionalDependencies": [ - "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets" - ], - "lookupRole": { - "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", - "requiresBootstrapStackVersion": 8, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "dependencies": [ - "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets" - ], - "metadata": { - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineBucketB967BD35" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/Policy/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineBucketPolicyD65CDEF5" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/AutoDeleteObjectsCustomResource/Default": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineBucketAutoDeleteObjectsCustomResource5F37E165" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ - { - "type": "aws:cdk:logicalId", - "data": "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler": [ - { - "type": "aws:cdk:logicalId", - "data": "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/DeployApp/AwsCliLayer/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "DeployAppAwsCliLayerAEF99B2F" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/DeployApp/CustomResource/Default": [ - { - "type": "aws:cdk:logicalId", - "data": "DeployAppCustomResourceDEE6DDD6" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/ServiceRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756CServiceRole89A01265" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/ServiceRole/DefaultPolicy/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756CServiceRoleDefaultPolicy88902FDF" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C81C01536" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/service-role/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "servicerole2C3CD20E" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/instance-profile-role/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "instanceprofilerole786BCBC7" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/instance-profile": [ - { - "type": "aws:cdk:logicalId", - "data": "instanceprofile" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/beastalk-app": [ - { - "type": "aws:cdk:logicalId", - "data": "beastalkapp" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/beanstlk-env": [ - { - "type": "aws:cdk:logicalId", - "data": "beanstlkenv" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Role/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineRoleD68726F7" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Role/DefaultPolicy/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineRoleDefaultPolicyC7A05455" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineC660917D" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Source/Source/CodePipelineActionRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineSourceCodePipelineActionRoleC6F9E7F5" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Source/Source/CodePipelineActionRole/DefaultPolicy/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineSourceCodePipelineActionRoleDefaultPolicy2D565925" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Deploy/Deploy/CodePipelineActionRole/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineDeployCodePipelineActionRole8B83082E" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Deploy/Deploy/CodePipelineActionRole/DefaultPolicy/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PipelineDeployCodePipelineActionRoleDefaultPolicyEE6D615B" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/BootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" - } - ], - "/aws-cdk-codepipeline-elastic-beanstalk-deploy/CheckBootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" - } - ] - }, - "displayName": "aws-cdk-codepipeline-elastic-beanstalk-deploy" - }, - "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets": { - "type": "cdk:asset-manifest", - "properties": { - "file": "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B": { - "type": "aws:cloudformation:stack", - "environment": "aws://unknown-account/unknown-region", - "properties": { - "templateFile": "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.template.json", - "validateOnSynth": false, - "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", - "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", - "additionalDependencies": [ - "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets" - ], - "lookupRole": { - "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", - "requiresBootstrapStackVersion": 8, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "dependencies": [ - "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets" - ], - "metadata": { - "/codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert/BootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" - } - ], - "/codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert/CheckBootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" - } - ] - }, - "displayName": "codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert" - }, - "Tree": { - "type": "cdk:tree", - "properties": { - "file": "tree.json" - } - } - } -} \ No newline at end of file diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip b/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/d1ba2cb2e5cfca13267ff70863e782b91873a033a2af81afb07f38cf38ec67ea.zip deleted file mode 100644 index 3cf3517aadf3c86fe0b7520aa3a9693e6b601fcd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 310 zcmWIWW@Zs#-~d7f21Ou700$t`)Xc=xz|_FN(AXl?Fv-Niz%nH%$uu$1GAY^AFgZEJ zFx4O_*}%ZWB-t#{#MC&+#2_WjJk>PO(A>zx#N5O{ThCWZ@1%~V?#VOfx%E7OjBP<0 zZbFxJ^?d#OboKnS&jvm@<$1=}%d Date: Tue, 12 Sep 2023 19:01:17 -0500 Subject: [PATCH 5/7] remove --- ...1497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip | Bin 4540 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip b/packages/@aws-cdk-testing/framework-integ/test/aws-s3-deployment/test/integ.bucket-deployment-substitution.js.snapshot/.cache/9eb41a5505d37607ac419321497a4f8c21cf0ee1f9b4a6b29aa04301aea5c7fd.zip deleted file mode 100644 index cb2790cf47f87701182d2d185a3bef4ec4634d2b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4540 zcmV;t5ku}!O9KQH00;mG0000X00000000000000000;m80BLSyWq2-ddBt0AbK5v` zf3Humr6xn_F|Az3ebLd3I+MreJoUtJTs!Vft9m#vxsq_E06qk0S;^(QcNTw0K$ddX z>ooO?NFo=D-Nj<@+r@@&8rf;6~w z*tD`l)xX!cX_mak(Xy2r=-RsGkJA?a-l5XqCc3phb9yZs6ppszm8a-BUj37O{Dm8S z{>^{#<~_0Z5_G8&b&?5bre zg@!p8e$%q%D0G$%uhPj#oxOUm&eF+fbpHOjxVt|;zqq@DIVA3DVxGT$cX@U3Gd;H7 zlF`NWzZV}a{-gN#>Hhk2ar5r;ztY>`*FbUi;qs<9zq)vLeSc#Z2fvfi=-n@O#rf4` zasKK0{pH_^_m@`}MDD)fGGG*$~LWR zu+&#MMaBEKRd zS{aMSu6#mW2)02|!HBjl?Lfj#*{22G1g{<0^-D<&UscVh_C z9MW`H6q?%m2z~c|&XiW83+qHQRJR?b6PVB4*GR7xHRGa?qOe{|%pyj&hTxO<**JBY zLqhx#!_R(=_*Go#mOq-kNnZ1c-_HTTWpzNcPGMVYP_v3@=5&iBx>wkKbnnyHUx{4p zl*UcWAsT;Y2)@IiX*+>#X8#d!xFLeUw9{H{vCWQ|7+=b|t73)`y9-N@=CF8(m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-ifK1X@wt9Jh`5|cbEsl8;101@K1*-nAm06%Od%JyX0XSG!bdGnoJBbdNEkg z-dHV?&un#vI&paDkNKPTVbeDaE7u64*~%5_t)#!>V=hp9GQ@OU*?PHYBQoeHl)zMgf{Pq7a?p0f z6;;Z6PLr8A4Y}xS_1-QDElXSm><0v;KV$bpg!W$Cmm96!Oi$G_w%SypD_&}Sit-y_CuR=c!)OpRwOc@E~Cu&TO9u$F`T<=!5dZ)qGynil zO928c0~7!V00;m803iUh`T<=!5dZ)qGynhy000000000003ZOQfdBvi0BLSyWq2-d ac~DCQ1^@s60096205$*s0B{ii00014ZoSF? From 15459f9b8a07798c4544817405a1fa66e7f8bd3d Mon Sep 17 00:00:00 2001 From: Michael Sambol Date: Tue, 12 Sep 2023 19:14:37 -0500 Subject: [PATCH 6/7] update snaps --- .../manifest.json | 237 ++++++++++++++++++ 1 file changed, 237 insertions(+) create mode 100644 packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json new file mode 100644 index 0000000000000..169010b153254 --- /dev/null +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json @@ -0,0 +1,237 @@ +{ + "version": "34.0.0", + "artifacts": { + "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "aws-cdk-codepipeline-elastic-beanstalk-deploy": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "aws-cdk-codepipeline-elastic-beanstalk-deploy.assets" + ], + "metadata": { + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBucketB967BD35" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/Policy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBucketPolicyD65CDEF5" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/PipelineBucket/AutoDeleteObjectsCustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineBucketAutoDeleteObjectsCustomResource5F37E165" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::S3AutoDeleteObjectsCustomResourceProvider/Role": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomS3AutoDeleteObjectsCustomResourceProviderRole3B1BD092" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::S3AutoDeleteObjectsCustomResourceProvider/Handler": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomS3AutoDeleteObjectsCustomResourceProviderHandler9D90184F" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/DeployApp/AwsCliLayer/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "DeployAppAwsCliLayerAEF99B2F" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/DeployApp/CustomResource/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "DeployAppCustomResourceDEE6DDD6" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/ServiceRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756CServiceRole89A01265" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/ServiceRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756CServiceRoleDefaultPolicy88902FDF" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Custom::CDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "CustomCDKBucketDeployment8693BB64968944B69AAFB0CC9EB8756C81C01536" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/service-role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "servicerole2C3CD20E" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/instance-profile-role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "instanceprofilerole786BCBC7" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/instance-profile": [ + { + "type": "aws:cdk:logicalId", + "data": "instanceprofile" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/beastalk-app": [ + { + "type": "aws:cdk:logicalId", + "data": "beastalkapp" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/beanstlk-env": [ + { + "type": "aws:cdk:logicalId", + "data": "beanstlkenv" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Role/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineRoleD68726F7" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Role/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineRoleDefaultPolicyC7A05455" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineC660917D" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Source/Source/CodePipelineActionRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineSourceCodePipelineActionRoleC6F9E7F5" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Source/Source/CodePipelineActionRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineSourceCodePipelineActionRoleDefaultPolicy2D565925" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Deploy/Deploy/CodePipelineActionRole/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineDeployCodePipelineActionRole8B83082E" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/Pipeline/Deploy/Deploy/CodePipelineActionRole/DefaultPolicy/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PipelineDeployCodePipelineActionRoleDefaultPolicyEE6D615B" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/aws-cdk-codepipeline-elastic-beanstalk-deploy/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "aws-cdk-codepipeline-elastic-beanstalk-deploy" + }, + "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B": { + "type": "aws:cloudformation:stack", + "environment": "aws://unknown-account/unknown-region", + "properties": { + "templateFile": "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/21fbb51d7b23f6a6c262b46a9caee79d744a3ac019fd45422d988b96d44b2a22.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "codepipelineelasticbeanstalkdeployDefaultTestDeployAssert785E452B.assets" + ], + "metadata": { + "/codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "codepipeline-elastic-beanstalk-deploy/DefaultTest/DeployAssert" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file From ea7f63712c9057e05f671ff98b649c9a23e9a55d Mon Sep 17 00:00:00 2001 From: Michael Sambol Date: Tue, 12 Sep 2023 19:28:52 -0500 Subject: [PATCH 7/7] but actually --- .../aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json | 4 ++-- ...ws-cdk-codepipeline-elastic-beanstalk-deploy.template.json | 4 ++-- .../manifest.json | 2 +- .../tree.json | 4 ++-- .../test/integ.pipeline-elastic-beanstalk-deploy.ts | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json index 0d246ebffb760..8a5031d35779d 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.assets.json @@ -53,7 +53,7 @@ } } }, - "c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55": { + "4de4e5d8bb87dcc2a1eea96c71bef35d6dcf4a63d8767f64f0d53f9362cbbef2": { "source": { "path": "aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json", "packaging": "file" @@ -61,7 +61,7 @@ "destinations": { "current_account-current_region": { "bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}", - "objectKey": "c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", + "objectKey": "4de4e5d8bb87dcc2a1eea96c71bef35d6dcf4a63d8767f64f0d53f9362cbbef2.json", "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}" } } diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json index 3fabf1dc5a284..2debab0dd131e 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/aws-cdk-codepipeline-elastic-beanstalk-deploy.template.json @@ -579,7 +579,7 @@ "Name": "Source", "OutputArtifacts": [ { - "Name": "SourceArtifact" + "Name": "SourceArtifact-issue-27117" } ], "RoleArn": { @@ -608,7 +608,7 @@ }, "InputArtifacts": [ { - "Name": "SourceArtifact" + "Name": "SourceArtifact-issue-27117" } ], "Name": "Deploy", diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json index 169010b153254..86ae22a0097ab 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/manifest.json @@ -17,7 +17,7 @@ "validateOnSynth": false, "assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}", "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c1011949c96fc4192d3b0537c512ef1797916ab8aaa1ce027020b92033705b55.json", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/4de4e5d8bb87dcc2a1eea96c71bef35d6dcf4a63d8767f64f0d53f9362cbbef2.json", "requiresBootstrapStackVersion": 6, "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", "additionalDependencies": [ diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/tree.json b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/tree.json index f862bf0af9093..2ebd0efab5f8f 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/tree.json +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.js.snapshot/tree.json @@ -862,7 +862,7 @@ "name": "Source", "outputArtifacts": [ { - "name": "SourceArtifact" + "name": "SourceArtifact-issue-27117" } ], "actionTypeId": { @@ -904,7 +904,7 @@ "name": "Deploy", "inputArtifacts": [ { - "name": "SourceArtifact" + "name": "SourceArtifact-issue-27117" } ], "actionTypeId": { diff --git a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.ts b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.ts index 30760ddbbb7c4..7d592b76c0712 100644 --- a/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.ts +++ b/packages/@aws-cdk-testing/framework-integ/test/aws-codepipeline-actions/test/integ.pipeline-elastic-beanstalk-deploy.ts @@ -111,7 +111,7 @@ const pipeline = new codepipeline.Pipeline(stack, 'Pipeline', { artifactBucket: bucket, }); -const sourceOutput = new codepipeline.Artifact('SourceArtifact'); +const sourceOutput = new codepipeline.Artifact('SourceArtifact-issue-27117'); const sourceAction = new cpactions.S3SourceAction({ actionName: 'Source', output: sourceOutput,