@cdklabs/deploy-time-build 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.jsii +223 -29
- package/.jsii.tabl.json +1 -1
- package/API.md +236 -0
- package/README.md +40 -0
- package/lib/container-image-build.js +1 -1
- package/lib/nodejs-build.d.ts +28 -0
- package/lib/nodejs-build.js +51 -9
- package/lib/soci-index-build.js +1 -1
- package/lib/soci-index-v2-build.js +1 -1
- package/package.json +4 -12
- package/rosetta/imported.ts-fixture +1 -1
- package/scripts/verify-min-cdk.sh +28 -0
package/.jsii
CHANGED
|
@@ -1423,6 +1423,19 @@
|
|
|
1423
1423
|
}
|
|
1424
1424
|
}
|
|
1425
1425
|
},
|
|
1426
|
+
"aws-cdk-lib.aws_eks_v2": {
|
|
1427
|
+
"targets": {
|
|
1428
|
+
"dotnet": {
|
|
1429
|
+
"namespace": "Amazon.CDK.AWS.EKSv2"
|
|
1430
|
+
},
|
|
1431
|
+
"java": {
|
|
1432
|
+
"package": "software.amazon.awscdk.services.eks_v2"
|
|
1433
|
+
},
|
|
1434
|
+
"python": {
|
|
1435
|
+
"module": "aws_cdk.aws_eks_v2"
|
|
1436
|
+
}
|
|
1437
|
+
}
|
|
1438
|
+
},
|
|
1426
1439
|
"aws-cdk-lib.aws_elasticache": {
|
|
1427
1440
|
"targets": {
|
|
1428
1441
|
"dotnet": {
|
|
@@ -2606,6 +2619,19 @@
|
|
|
2606
2619
|
}
|
|
2607
2620
|
}
|
|
2608
2621
|
},
|
|
2622
|
+
"aws-cdk-lib.aws_mwaaserverless": {
|
|
2623
|
+
"targets": {
|
|
2624
|
+
"dotnet": {
|
|
2625
|
+
"namespace": "Amazon.CDK.AWS.MWAAServerless"
|
|
2626
|
+
},
|
|
2627
|
+
"java": {
|
|
2628
|
+
"package": "software.amazon.awscdk.services.mwaaserverless"
|
|
2629
|
+
},
|
|
2630
|
+
"python": {
|
|
2631
|
+
"module": "aws_cdk.aws_mwaaserverless"
|
|
2632
|
+
}
|
|
2633
|
+
}
|
|
2634
|
+
},
|
|
2609
2635
|
"aws-cdk-lib.aws_neptune": {
|
|
2610
2636
|
"targets": {
|
|
2611
2637
|
"dotnet": {
|
|
@@ -6811,6 +6837,22 @@
|
|
|
6811
6837
|
}
|
|
6812
6838
|
}
|
|
6813
6839
|
},
|
|
6840
|
+
"aws-cdk-lib.interfaces.aws_mwaaserverless": {
|
|
6841
|
+
"targets": {
|
|
6842
|
+
"dotnet": {
|
|
6843
|
+
"namespace": "Amazon.CDK.Interfaces.MWAAServerless"
|
|
6844
|
+
},
|
|
6845
|
+
"go": {
|
|
6846
|
+
"packageName": "interfacesawsmwaaserverless"
|
|
6847
|
+
},
|
|
6848
|
+
"java": {
|
|
6849
|
+
"package": "software.amazon.awscdk.interfaces.mwaaserverless"
|
|
6850
|
+
},
|
|
6851
|
+
"python": {
|
|
6852
|
+
"module": "aws_cdk.interfaces.aws_mwaaserverless"
|
|
6853
|
+
}
|
|
6854
|
+
}
|
|
6855
|
+
},
|
|
6814
6856
|
"aws-cdk-lib.interfaces.aws_neptune": {
|
|
6815
6857
|
"targets": {
|
|
6816
6858
|
"dotnet": {
|
|
@@ -8470,7 +8512,7 @@
|
|
|
8470
8512
|
"stability": "experimental"
|
|
8471
8513
|
},
|
|
8472
8514
|
"homepage": "https://github.com/cdklabs/deploy-time-build.git",
|
|
8473
|
-
"jsiiVersion": "5.9.
|
|
8515
|
+
"jsiiVersion": "5.9.29 (build f415c53)",
|
|
8474
8516
|
"keywords": [
|
|
8475
8517
|
"aws",
|
|
8476
8518
|
"aws-cdk",
|
|
@@ -8490,7 +8532,7 @@
|
|
|
8490
8532
|
},
|
|
8491
8533
|
"name": "@cdklabs/deploy-time-build",
|
|
8492
8534
|
"readme": {
|
|
8493
|
-
"markdown": "# Deploy-time Build\nAWS CDK L3 construct that allows you to run a build job for specific purposes. Currently this library supports the following use cases:\n\n* Build web frontend static files\n* Build a container image\n* Build Seekable OCI (SOCI) indices for container images\n\n[](https://constructs.dev/packages/@cdklabs/deploy-time-build)\n\n## Usage\nInstall from npm:\n\n```sh\nnpm i @cdklabs/deploy-time-build\n```\n\nThis library defines several L3 constructs for specific use cases. Here is the usage for each case.\n\n### Build Node.js apps\n\nYou can build a Node.js app such as a React frontend app on deploy time by the `NodejsBuild` construct.\n\n\n\nThe following code is an example to use the construct:\n\n```ts\nimport { NodejsBuild } from '@cdklabs/deploy-time-build';\n\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n buildCommands: ['npm ci', 'npm run build'],\n buildEnvironment: {\n VITE_API_ENDPOINT: api.url,\n },\n});\n```\n\nNote that it is possible to pass environment variable `VITE_API_ENDPOINT: api.url` to the construct, which is resolved on deploy time, and injected to the build environment (a vite process in this case.)\nThe resulting build artifacts will be deployed to `destinationBucket` from CodeBuild.\n\nYou can specify multiple input assets by `assets` property. These assets are extracted to respective sub directories. For example, assume you specified assets like the following:\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n // directory containing source code and package.json\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n commands: ['npm install'],\n },\n {\n // directory that is also required for the build\n path: 'module1',\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n});\n```\n\nThen, the extracted directories will be located as the following:\n\n```sh\n. # a temporary directory (automatically created)\n├── example-app # extracted example-app assets\n│ ├── src/ # dist or node_modules directories are excluded even if they exist locally.\n│ ├── package.json # npm install will be executed since its specified in `commands` property.\n│ └── package-lock.json\n└── module1 # extracted module1 assets\n```\n\nYou can also override the path where assets are extracted by `extractPath` property for each asset.\n\nWith `outputEnvFile` property enabled, a `.env` file is automatically generated and uploaded to your S3 bucket. This file can be used running you frontend project locally. You can download the file to your local machine by running the command added in the stack output.\n\nPlease also check [the example directory](./example/) for a complete example.\n\n#### Allowing access from the build environment to other AWS resources\nSince `NodejsBuild` construct implements [`iam.IGrantable`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_iam.IGrantable.html) interface, you can use `grant*` method of other constructs to allow access from the build environment.\n\n```ts fixture=imported\ndeclare const someBucket: s3.IBucket;\ndeclare const build: NodejsBuild;\nsomeBucket.grantReadWrite(build);\n```\n\nYou can also use [`iam.Grant`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_iam.Grant.html) class to allow any actions and resources.\n\n```ts fixture=imported\ndeclare const build: NodejsBuild;\niam.Grant.addToPrincipal({ grantee: build, actions: ['s3:ListBucket'], resourceArns:['*'] })\n```\n\n#### Motivation - why do we need the `NodejsBuild` construct?\nI talked about why this construct can be useful in some situations at CDK Day 2023. See the recording or slides below:\n\n[Recording](https://www.youtube.com/live/b-nSH18gFQk?si=ogEZ2x1NixOj6J6j&t=373) | [Slides](https://speakerdeck.com/tmokmss/deploy-web-frontend-apps-with-aws-cdk)\n\n#### Considerations\nSince this construct builds your frontend apps every time you deploy the stack and there is any change in input assets (and currently there's even no build cache in the Lambda function!), the time a deployment takes tends to be longer (e.g. a few minutes even for the simple app in `example` directory.) This might results in worse developer experience if you want to deploy changes frequently (imagine `cdk watch` deployment always re-build your frontend app).\n\nTo mitigate this issue, you can separate the stack for frontend construct from other stacks especially for a dev environment. Another solution would be to set a fixed string as an asset hash, and avoid builds on every deployment.\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: '../frontend',\n exclude: ['node_modules', 'dist'],\n commands: ['npm ci'],\n // Set a fixed string as a asset hash to prevent deploying changes.\n // This can be useful for an environment you use to develop locally.\n assetHash: 'frontend_asset',\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n});\n```\n\n### Build a container image\nYou can build a container image at deploy time by the following code:\n\n```ts\nimport { ContainerImageBuild } from '@cdklabs/deploy-time-build';\n\nconst image = new ContainerImageBuild(this, 'Build', {\n directory: 'example-image',\n buildArgs: { DUMMY_FILE_SIZE_MB: '15' },\n tag: 'my-image-tag',\n});\nnew DockerImageFunction(this, 'Function', {\n code: image.toLambdaDockerImageCode(),\n});\nconst armImage = new ContainerImageBuild(this, 'BuildArm', {\n directory: 'example-image',\n platform: Platform.LINUX_ARM64,\n repository: image.repository,\n zstdCompression: true,\n});\nnew FargateTaskDefinition(this, 'TaskDefinition', {\n runtimePlatform: { cpuArchitecture: CpuArchitecture.ARM64 }\n}).addContainer('main', {\n image: armImage.toEcsDockerImageCode(),\n});\n```\n\nThe third argument (props) are a superset of DockerImageAsset's properties. You can set a few additional properties such as `tag`, `repository`, and `zstdCompression`.\n\n### Build SOCI index for a container image\n[Seekable OCI (SOCI)](https://aws.amazon.com/about-aws/whats-new/2022/09/introducing-seekable-oci-lazy-loading-container-images/) is a way to help start tasks faster for Amazon ECS tasks on Fargate 1.4.0. You can build and push a SOCI index using the `SociIndexV2Build` construct.\n\n\n\nThe following code is an example to use the construct:\n\n```ts\nimport { SociIndexV2Build } from '@cdklabs/deploy-time-build';\n\nconst asset = new DockerImageAsset(this, 'Image', { directory: 'example-image' });\nconst sociIndex = new SociIndexV2Build(this, 'SociV2Index', {\n repository: asset.repository,\n inputImageTag: asset.assetHash,\n outputImageTag: `${asset.assetHash}-soci`,\n});\n\n// Use with ECS Fargate\nconst taskDefinition = new FargateTaskDefinition(this, 'TaskDefinition');\ntaskDefinition.addContainer('main', {\n image: sociIndex.toEcsDockerImageCode(),\n});\n\n// Or create from DockerImageAsset using utility method\nconst sociIndexFromAsset = SociIndexV2Build.fromDockerImageAsset(this, 'SociV2Index2', asset);\n```\n\nThe `SociIndexV2Build` construct:\n- Takes an input container image and builds a SOCI v2 index for it\n- Outputs a new image tag with the embedded SOCI index\n- Provides `toEcsDockerImageCode()` method to easily use with ECS tasks\n- Uses the same ECR repository for input and output images\n\nWe currently use [`soci-wrapper`](https://github.com/tmokmss/soci-wrapper) to build and push SOCI indices.\n\n> [!WARNING]\n> The previous `SocideIndexBuild` construct is now deprecated. Customers new to SOCI on AWS Fargate can only use SOCI index manifest v2. See [this article](https://aws.amazon.com/blogs/containers/improving-amazon-ecs-deployment-consistency-with-soci-index-manifest-v2/) for more details.\n\n#### Motivation - why do we need the `SociIndexBuild` construct?\n\nCurrently there are several other ways to build a SOCI index; 1. use `soci-snapshotter` CLI, or 2. use [cfn-ecr-aws-soci-index-builder](https://github.com/aws-ia/cfn-ecr-aws-soci-index-builder) solution, none of which can be directly used from AWS CDK. If you are familiar with CDK, you should often deploy container images as CDK assets, which is an ideal way to integrate with other L2 constructs such as ECS. To make the developer experience for SOCI as close as the ordinary container images, the `SociIndexBuild` allows you to deploying a SOCI index directly from CDK, without any dependencies outside of CDK context.\n\n## Development\nCommands for maintainers:\n\n```sh\n# run test locally\nnpx tsc -p tsconfig.dev.json\nnpx integ-runner\nnpx integ-runner --update-on-failed\n```\n"
|
|
8535
|
+
"markdown": "# Deploy-time Build\nAWS CDK L3 construct that allows you to run a build job for specific purposes. Currently this library supports the following use cases:\n\n* Build web frontend static files\n* Build a container image\n* Build Seekable OCI (SOCI) indices for container images\n\n[](https://constructs.dev/packages/@cdklabs/deploy-time-build)\n\n## Usage\nInstall from npm:\n\n```sh\nnpm i @cdklabs/deploy-time-build\n```\n\nThis library defines several L3 constructs for specific use cases. Here is the usage for each case.\n\n### Build Node.js apps\n\nYou can build a Node.js app such as a React frontend app on deploy time by the `NodejsBuild` construct.\n\n\n\nThe following code is an example to use the construct:\n\n```ts\nimport { NodejsBuild } from '@cdklabs/deploy-time-build';\n\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n buildCommands: ['npm ci', 'npm run build'],\n buildEnvironment: {\n VITE_API_ENDPOINT: api.url,\n },\n});\n```\n\nNote that it is possible to pass environment variable `VITE_API_ENDPOINT: api.url` to the construct, which is resolved on deploy time, and injected to the build environment (a vite process in this case.)\nThe resulting build artifacts will be deployed to `destinationBucket` from CodeBuild.\n\nYou can specify multiple input assets by `assets` property. These assets are extracted to respective sub directories. For example, assume you specified assets like the following:\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n // directory containing source code and package.json\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n commands: ['npm install'],\n },\n {\n // directory that is also required for the build\n path: 'module1',\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n});\n```\n\nThen, the extracted directories will be located as the following:\n\n```sh\n. # a temporary directory (automatically created)\n├── example-app # extracted example-app assets\n│ ├── src/ # dist or node_modules directories are excluded even if they exist locally.\n│ ├── package.json # npm install will be executed since its specified in `commands` property.\n│ └── package-lock.json\n└── module1 # extracted module1 assets\n```\n\nYou can also override the path where assets are extracted by `extractPath` property for each asset.\n\nWith `outputEnvFile` property enabled, a `.env` file is automatically generated and uploaded to your S3 bucket. This file can be used running you frontend project locally. You can download the file to your local machine by running the command added in the stack output.\n\nPlease also check [the example directory](./example/) for a complete example.\n\n#### Allowing access from the build environment to other AWS resources\nSince `NodejsBuild` construct implements [`iam.IGrantable`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_iam.IGrantable.html) interface, you can use `grant*` method of other constructs to allow access from the build environment.\n\n```ts fixture=imported\ndeclare const someBucket: s3.IBucket;\ndeclare const build: NodejsBuild;\nsomeBucket.grantReadWrite(build);\n```\n\nYou can also use [`iam.Grant`](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_iam.Grant.html) class to allow any actions and resources.\n\n```ts fixture=imported\ndeclare const build: NodejsBuild;\niam.Grant.addToPrincipal({ grantee: build, actions: ['s3:ListBucket'], resourceArns:['*'] })\n```\n\n#### Motivation - why do we need the `NodejsBuild` construct?\nI talked about why this construct can be useful in some situations at CDK Day 2023. See the recording or slides below:\n\n[Recording](https://www.youtube.com/live/b-nSH18gFQk?si=ogEZ2x1NixOj6J6j&t=373) | [Slides](https://speakerdeck.com/tmokmss/deploy-web-frontend-apps-with-aws-cdk)\n\n#### Caching\n\nYou can enable npm caching to speed up builds using the `cache` property:\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n },\n ],\n destinationBucket,\n outputSourceDirectory: 'dist',\n cache: CacheType.S3, // or CacheType.LOCAL\n});\n```\n\nTwo cache types are available:\n- `CacheType.S3`: Stores the npm cache directory in an S3 bucket. Good for builds that run infrequently on different hosts.\n- `CacheType.LOCAL`: Stores the npm cache directory on the build host. Faster than S3 but only effective if builds run on the same host.\n\n#### Compute Type\n\nYou can specify the compute type for the CodeBuild project using the `computeType` property:\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: 'example-app',\n exclude: ['dist', 'node_modules'],\n },\n ],\n destinationBucket,\n outputSourceDirectory: 'dist',\n computeType: ComputeType.MEDIUM,\n});\n```\n\n#### Considerations\nSince this construct builds your frontend apps every time you deploy the stack and there is any change in input assets (and currently there's even no build cache in the Lambda function!), the time a deployment takes tends to be longer (e.g. a few minutes even for the simple app in `example` directory.) This might results in worse developer experience if you want to deploy changes frequently (imagine `cdk watch` deployment always re-build your frontend app).\n\nTo mitigate this issue, you can separate the stack for frontend construct from other stacks especially for a dev environment. Another solution would be to set a fixed string as an asset hash, and avoid builds on every deployment.\n\n```ts fixture=imported\nnew NodejsBuild(this, 'ExampleBuild', {\n assets: [\n {\n path: '../frontend',\n exclude: ['node_modules', 'dist'],\n commands: ['npm ci'],\n // Set a fixed string as a asset hash to prevent deploying changes.\n // This can be useful for an environment you use to develop locally.\n assetHash: 'frontend_asset',\n },\n ],\n destinationBucket,\n distribution,\n outputSourceDirectory: 'dist',\n});\n```\n\n### Build a container image\nYou can build a container image at deploy time by the following code:\n\n```ts\nimport { ContainerImageBuild } from '@cdklabs/deploy-time-build';\n\nconst image = new ContainerImageBuild(this, 'Build', {\n directory: 'example-image',\n buildArgs: { DUMMY_FILE_SIZE_MB: '15' },\n tag: 'my-image-tag',\n});\nnew DockerImageFunction(this, 'Function', {\n code: image.toLambdaDockerImageCode(),\n});\nconst armImage = new ContainerImageBuild(this, 'BuildArm', {\n directory: 'example-image',\n platform: Platform.LINUX_ARM64,\n repository: image.repository,\n zstdCompression: true,\n});\nnew FargateTaskDefinition(this, 'TaskDefinition', {\n runtimePlatform: { cpuArchitecture: CpuArchitecture.ARM64 }\n}).addContainer('main', {\n image: armImage.toEcsDockerImageCode(),\n});\n```\n\nThe third argument (props) are a superset of DockerImageAsset's properties. You can set a few additional properties such as `tag`, `repository`, and `zstdCompression`.\n\n### Build SOCI index for a container image\n[Seekable OCI (SOCI)](https://aws.amazon.com/about-aws/whats-new/2022/09/introducing-seekable-oci-lazy-loading-container-images/) is a way to help start tasks faster for Amazon ECS tasks on Fargate 1.4.0. You can build and push a SOCI index using the `SociIndexV2Build` construct.\n\n\n\nThe following code is an example to use the construct:\n\n```ts\nimport { SociIndexV2Build } from '@cdklabs/deploy-time-build';\n\nconst asset = new DockerImageAsset(this, 'Image', { directory: 'example-image' });\nconst sociIndex = new SociIndexV2Build(this, 'SociV2Index', {\n repository: asset.repository,\n inputImageTag: asset.assetHash,\n outputImageTag: `${asset.assetHash}-soci`,\n});\n\n// Use with ECS Fargate\nconst taskDefinition = new FargateTaskDefinition(this, 'TaskDefinition');\ntaskDefinition.addContainer('main', {\n image: sociIndex.toEcsDockerImageCode(),\n});\n\n// Or create from DockerImageAsset using utility method\nconst sociIndexFromAsset = SociIndexV2Build.fromDockerImageAsset(this, 'SociV2Index2', asset);\n```\n\nThe `SociIndexV2Build` construct:\n- Takes an input container image and builds a SOCI v2 index for it\n- Outputs a new image tag with the embedded SOCI index\n- Provides `toEcsDockerImageCode()` method to easily use with ECS tasks\n- Uses the same ECR repository for input and output images\n\nWe currently use [`soci-wrapper`](https://github.com/tmokmss/soci-wrapper) to build and push SOCI indices.\n\n> [!WARNING]\n> The previous `SocideIndexBuild` construct is now deprecated. Customers new to SOCI on AWS Fargate can only use SOCI index manifest v2. See [this article](https://aws.amazon.com/blogs/containers/improving-amazon-ecs-deployment-consistency-with-soci-index-manifest-v2/) for more details.\n\n#### Motivation - why do we need the `SociIndexBuild` construct?\n\nCurrently there are several other ways to build a SOCI index; 1. use `soci-snapshotter` CLI, or 2. use [cfn-ecr-aws-soci-index-builder](https://github.com/aws-ia/cfn-ecr-aws-soci-index-builder) solution, none of which can be directly used from AWS CDK. If you are familiar with CDK, you should often deploy container images as CDK assets, which is an ideal way to integrate with other L2 constructs such as ECS. To make the developer experience for SOCI as close as the ordinary container images, the `SociIndexBuild` allows you to deploying a SOCI index directly from CDK, without any dependencies outside of CDK context.\n\n## Development\nCommands for maintainers:\n\n```sh\n# run test locally\nnpx tsc -p tsconfig.dev.json\nnpx integ-runner\nnpx integ-runner --update-on-failed\n```\n"
|
|
8494
8536
|
},
|
|
8495
8537
|
"repository": {
|
|
8496
8538
|
"type": "git",
|
|
@@ -8498,13 +8540,6 @@
|
|
|
8498
8540
|
},
|
|
8499
8541
|
"schema": "jsii/0.10.0",
|
|
8500
8542
|
"targets": {
|
|
8501
|
-
"java": {
|
|
8502
|
-
"maven": {
|
|
8503
|
-
"artifactId": "deploy-time-build",
|
|
8504
|
-
"groupId": "io.github.cdklabs"
|
|
8505
|
-
},
|
|
8506
|
-
"package": "io.github.cdklabs.deploy.time.build"
|
|
8507
|
-
},
|
|
8508
8543
|
"js": {
|
|
8509
8544
|
"npm": "@cdklabs/deploy-time-build"
|
|
8510
8545
|
},
|
|
@@ -8527,7 +8562,7 @@
|
|
|
8527
8562
|
"kind": "interface",
|
|
8528
8563
|
"locationInModule": {
|
|
8529
8564
|
"filename": "src/nodejs-build.ts",
|
|
8530
|
-
"line":
|
|
8565
|
+
"line": 31
|
|
8531
8566
|
},
|
|
8532
8567
|
"name": "AssetConfig",
|
|
8533
8568
|
"properties": [
|
|
@@ -8541,7 +8576,7 @@
|
|
|
8541
8576
|
"immutable": true,
|
|
8542
8577
|
"locationInModule": {
|
|
8543
8578
|
"filename": "src/nodejs-build.ts",
|
|
8544
|
-
"line":
|
|
8579
|
+
"line": 36
|
|
8545
8580
|
},
|
|
8546
8581
|
"name": "commands",
|
|
8547
8582
|
"optional": true,
|
|
@@ -8564,7 +8599,7 @@
|
|
|
8564
8599
|
"immutable": true,
|
|
8565
8600
|
"locationInModule": {
|
|
8566
8601
|
"filename": "src/nodejs-build.ts",
|
|
8567
|
-
"line":
|
|
8602
|
+
"line": 42
|
|
8568
8603
|
},
|
|
8569
8604
|
"name": "extractPath",
|
|
8570
8605
|
"optional": true,
|
|
@@ -8575,6 +8610,129 @@
|
|
|
8575
8610
|
],
|
|
8576
8611
|
"symbolId": "src/nodejs-build:AssetConfig"
|
|
8577
8612
|
},
|
|
8613
|
+
"@cdklabs/deploy-time-build.CacheType": {
|
|
8614
|
+
"assembly": "@cdklabs/deploy-time-build",
|
|
8615
|
+
"docs": {
|
|
8616
|
+
"stability": "experimental",
|
|
8617
|
+
"summary": "Cache type for NodejsBuild."
|
|
8618
|
+
},
|
|
8619
|
+
"fqn": "@cdklabs/deploy-time-build.CacheType",
|
|
8620
|
+
"kind": "enum",
|
|
8621
|
+
"locationInModule": {
|
|
8622
|
+
"filename": "src/nodejs-build.ts",
|
|
8623
|
+
"line": 17
|
|
8624
|
+
},
|
|
8625
|
+
"members": [
|
|
8626
|
+
{
|
|
8627
|
+
"docs": {
|
|
8628
|
+
"remarks": "Stores the npm cache directory in an S3 bucket.\nGood for builds that run on different hosts.",
|
|
8629
|
+
"stability": "experimental",
|
|
8630
|
+
"summary": "S3 caching."
|
|
8631
|
+
},
|
|
8632
|
+
"name": "S3"
|
|
8633
|
+
},
|
|
8634
|
+
{
|
|
8635
|
+
"docs": {
|
|
8636
|
+
"remarks": "Stores the npm cache directory on the build host.\nFaster than S3 but only effective if builds run on the same host.\nNot supported with VPC or certain compute types.",
|
|
8637
|
+
"stability": "experimental",
|
|
8638
|
+
"summary": "Local caching."
|
|
8639
|
+
},
|
|
8640
|
+
"name": "LOCAL"
|
|
8641
|
+
}
|
|
8642
|
+
],
|
|
8643
|
+
"name": "CacheType",
|
|
8644
|
+
"symbolId": "src/nodejs-build:CacheType"
|
|
8645
|
+
},
|
|
8646
|
+
"@cdklabs/deploy-time-build.ComputeType": {
|
|
8647
|
+
"assembly": "@cdklabs/deploy-time-build",
|
|
8648
|
+
"docs": {
|
|
8649
|
+
"see": "https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-compute-types.html#environment.types",
|
|
8650
|
+
"stability": "experimental",
|
|
8651
|
+
"summary": "Build machine compute type."
|
|
8652
|
+
},
|
|
8653
|
+
"fqn": "@cdklabs/deploy-time-build.ComputeType",
|
|
8654
|
+
"kind": "enum",
|
|
8655
|
+
"locationInModule": {
|
|
8656
|
+
"filename": "node_modules/aws-cdk-lib/aws-codebuild/lib/compute-type.d.ts",
|
|
8657
|
+
"line": 6
|
|
8658
|
+
},
|
|
8659
|
+
"members": [
|
|
8660
|
+
{
|
|
8661
|
+
"docs": {
|
|
8662
|
+
"stability": "experimental"
|
|
8663
|
+
},
|
|
8664
|
+
"name": "SMALL"
|
|
8665
|
+
},
|
|
8666
|
+
{
|
|
8667
|
+
"docs": {
|
|
8668
|
+
"stability": "experimental"
|
|
8669
|
+
},
|
|
8670
|
+
"name": "MEDIUM"
|
|
8671
|
+
},
|
|
8672
|
+
{
|
|
8673
|
+
"docs": {
|
|
8674
|
+
"stability": "experimental"
|
|
8675
|
+
},
|
|
8676
|
+
"name": "LARGE"
|
|
8677
|
+
},
|
|
8678
|
+
{
|
|
8679
|
+
"docs": {
|
|
8680
|
+
"stability": "experimental"
|
|
8681
|
+
},
|
|
8682
|
+
"name": "X_LARGE"
|
|
8683
|
+
},
|
|
8684
|
+
{
|
|
8685
|
+
"docs": {
|
|
8686
|
+
"stability": "experimental"
|
|
8687
|
+
},
|
|
8688
|
+
"name": "X2_LARGE"
|
|
8689
|
+
},
|
|
8690
|
+
{
|
|
8691
|
+
"docs": {
|
|
8692
|
+
"stability": "experimental"
|
|
8693
|
+
},
|
|
8694
|
+
"name": "LAMBDA_1GB"
|
|
8695
|
+
},
|
|
8696
|
+
{
|
|
8697
|
+
"docs": {
|
|
8698
|
+
"stability": "experimental"
|
|
8699
|
+
},
|
|
8700
|
+
"name": "LAMBDA_2GB"
|
|
8701
|
+
},
|
|
8702
|
+
{
|
|
8703
|
+
"docs": {
|
|
8704
|
+
"stability": "experimental"
|
|
8705
|
+
},
|
|
8706
|
+
"name": "LAMBDA_4GB"
|
|
8707
|
+
},
|
|
8708
|
+
{
|
|
8709
|
+
"docs": {
|
|
8710
|
+
"stability": "experimental"
|
|
8711
|
+
},
|
|
8712
|
+
"name": "LAMBDA_8GB"
|
|
8713
|
+
},
|
|
8714
|
+
{
|
|
8715
|
+
"docs": {
|
|
8716
|
+
"stability": "experimental"
|
|
8717
|
+
},
|
|
8718
|
+
"name": "LAMBDA_10GB"
|
|
8719
|
+
},
|
|
8720
|
+
{
|
|
8721
|
+
"docs": {
|
|
8722
|
+
"stability": "experimental"
|
|
8723
|
+
},
|
|
8724
|
+
"name": "ATTRIBUTE_BASED"
|
|
8725
|
+
},
|
|
8726
|
+
{
|
|
8727
|
+
"docs": {
|
|
8728
|
+
"stability": "experimental"
|
|
8729
|
+
},
|
|
8730
|
+
"name": "CUSTOM_INSTANCE_TYPE"
|
|
8731
|
+
}
|
|
8732
|
+
],
|
|
8733
|
+
"name": "ComputeType",
|
|
8734
|
+
"symbolId": "aws-codebuild/lib/compute-type:ComputeType"
|
|
8735
|
+
},
|
|
8578
8736
|
"@cdklabs/deploy-time-build.ContainerImageBuild": {
|
|
8579
8737
|
"assembly": "@cdklabs/deploy-time-build",
|
|
8580
8738
|
"base": "constructs.Construct",
|
|
@@ -8942,7 +9100,7 @@
|
|
|
8942
9100
|
},
|
|
8943
9101
|
"locationInModule": {
|
|
8944
9102
|
"filename": "src/nodejs-build.ts",
|
|
8945
|
-
"line":
|
|
9103
|
+
"line": 120
|
|
8946
9104
|
},
|
|
8947
9105
|
"parameters": [
|
|
8948
9106
|
{
|
|
@@ -8971,7 +9129,7 @@
|
|
|
8971
9129
|
"kind": "class",
|
|
8972
9130
|
"locationInModule": {
|
|
8973
9131
|
"filename": "src/nodejs-build.ts",
|
|
8974
|
-
"line":
|
|
9132
|
+
"line": 117
|
|
8975
9133
|
},
|
|
8976
9134
|
"name": "NodejsBuild",
|
|
8977
9135
|
"properties": [
|
|
@@ -8983,7 +9141,7 @@
|
|
|
8983
9141
|
"immutable": true,
|
|
8984
9142
|
"locationInModule": {
|
|
8985
9143
|
"filename": "src/nodejs-build.ts",
|
|
8986
|
-
"line":
|
|
9144
|
+
"line": 118
|
|
8987
9145
|
},
|
|
8988
9146
|
"name": "grantPrincipal",
|
|
8989
9147
|
"overrides": "aws-cdk-lib.aws_iam.IGrantable",
|
|
@@ -9004,7 +9162,7 @@
|
|
|
9004
9162
|
"kind": "interface",
|
|
9005
9163
|
"locationInModule": {
|
|
9006
9164
|
"filename": "src/nodejs-build.ts",
|
|
9007
|
-
"line":
|
|
9165
|
+
"line": 45
|
|
9008
9166
|
},
|
|
9009
9167
|
"name": "NodejsBuildProps",
|
|
9010
9168
|
"properties": [
|
|
@@ -9017,7 +9175,7 @@
|
|
|
9017
9175
|
"immutable": true,
|
|
9018
9176
|
"locationInModule": {
|
|
9019
9177
|
"filename": "src/nodejs-build.ts",
|
|
9020
|
-
"line":
|
|
9178
|
+
"line": 49
|
|
9021
9179
|
},
|
|
9022
9180
|
"name": "assets",
|
|
9023
9181
|
"type": {
|
|
@@ -9038,7 +9196,7 @@
|
|
|
9038
9196
|
"immutable": true,
|
|
9039
9197
|
"locationInModule": {
|
|
9040
9198
|
"filename": "src/nodejs-build.ts",
|
|
9041
|
-
"line":
|
|
9199
|
+
"line": 59
|
|
9042
9200
|
},
|
|
9043
9201
|
"name": "destinationBucket",
|
|
9044
9202
|
"type": {
|
|
@@ -9054,7 +9212,7 @@
|
|
|
9054
9212
|
"immutable": true,
|
|
9055
9213
|
"locationInModule": {
|
|
9056
9214
|
"filename": "src/nodejs-build.ts",
|
|
9057
|
-
"line":
|
|
9215
|
+
"line": 84
|
|
9058
9216
|
},
|
|
9059
9217
|
"name": "outputSourceDirectory",
|
|
9060
9218
|
"type": {
|
|
@@ -9072,7 +9230,7 @@
|
|
|
9072
9230
|
"immutable": true,
|
|
9073
9231
|
"locationInModule": {
|
|
9074
9232
|
"filename": "src/nodejs-build.ts",
|
|
9075
|
-
"line":
|
|
9233
|
+
"line": 75
|
|
9076
9234
|
},
|
|
9077
9235
|
"name": "buildCommands",
|
|
9078
9236
|
"optional": true,
|
|
@@ -9096,7 +9254,7 @@
|
|
|
9096
9254
|
"immutable": true,
|
|
9097
9255
|
"locationInModule": {
|
|
9098
9256
|
"filename": "src/nodejs-build.ts",
|
|
9099
|
-
"line":
|
|
9257
|
+
"line": 55
|
|
9100
9258
|
},
|
|
9101
9259
|
"name": "buildEnvironment",
|
|
9102
9260
|
"optional": true,
|
|
@@ -9109,6 +9267,42 @@
|
|
|
9109
9267
|
}
|
|
9110
9268
|
}
|
|
9111
9269
|
},
|
|
9270
|
+
{
|
|
9271
|
+
"abstract": true,
|
|
9272
|
+
"docs": {
|
|
9273
|
+
"default": "- No caching",
|
|
9274
|
+
"stability": "experimental",
|
|
9275
|
+
"summary": "Cache type for the npm cache directory."
|
|
9276
|
+
},
|
|
9277
|
+
"immutable": true,
|
|
9278
|
+
"locationInModule": {
|
|
9279
|
+
"filename": "src/nodejs-build.ts",
|
|
9280
|
+
"line": 106
|
|
9281
|
+
},
|
|
9282
|
+
"name": "cache",
|
|
9283
|
+
"optional": true,
|
|
9284
|
+
"type": {
|
|
9285
|
+
"fqn": "@cdklabs/deploy-time-build.CacheType"
|
|
9286
|
+
}
|
|
9287
|
+
},
|
|
9288
|
+
{
|
|
9289
|
+
"abstract": true,
|
|
9290
|
+
"docs": {
|
|
9291
|
+
"default": "ComputeType.SMALL",
|
|
9292
|
+
"stability": "experimental",
|
|
9293
|
+
"summary": "The type of compute to use for this build."
|
|
9294
|
+
},
|
|
9295
|
+
"immutable": true,
|
|
9296
|
+
"locationInModule": {
|
|
9297
|
+
"filename": "src/nodejs-build.ts",
|
|
9298
|
+
"line": 111
|
|
9299
|
+
},
|
|
9300
|
+
"name": "computeType",
|
|
9301
|
+
"optional": true,
|
|
9302
|
+
"type": {
|
|
9303
|
+
"fqn": "aws-cdk-lib.aws_codebuild.ComputeType"
|
|
9304
|
+
}
|
|
9305
|
+
},
|
|
9112
9306
|
{
|
|
9113
9307
|
"abstract": true,
|
|
9114
9308
|
"docs": {
|
|
@@ -9119,7 +9313,7 @@
|
|
|
9119
9313
|
"immutable": true,
|
|
9120
9314
|
"locationInModule": {
|
|
9121
9315
|
"filename": "src/nodejs-build.ts",
|
|
9122
|
-
"line":
|
|
9316
|
+
"line": 64
|
|
9123
9317
|
},
|
|
9124
9318
|
"name": "destinationKeyPrefix",
|
|
9125
9319
|
"optional": true,
|
|
@@ -9138,7 +9332,7 @@
|
|
|
9138
9332
|
"immutable": true,
|
|
9139
9333
|
"locationInModule": {
|
|
9140
9334
|
"filename": "src/nodejs-build.ts",
|
|
9141
|
-
"line":
|
|
9335
|
+
"line": 70
|
|
9142
9336
|
},
|
|
9143
9337
|
"name": "distribution",
|
|
9144
9338
|
"optional": true,
|
|
@@ -9156,7 +9350,7 @@
|
|
|
9156
9350
|
"immutable": true,
|
|
9157
9351
|
"locationInModule": {
|
|
9158
9352
|
"filename": "src/nodejs-build.ts",
|
|
9159
|
-
"line":
|
|
9353
|
+
"line": 101
|
|
9160
9354
|
},
|
|
9161
9355
|
"name": "excludeCommonFiles",
|
|
9162
9356
|
"optional": true,
|
|
@@ -9174,7 +9368,7 @@
|
|
|
9174
9368
|
"immutable": true,
|
|
9175
9369
|
"locationInModule": {
|
|
9176
9370
|
"filename": "src/nodejs-build.ts",
|
|
9177
|
-
"line":
|
|
9371
|
+
"line": 89
|
|
9178
9372
|
},
|
|
9179
9373
|
"name": "nodejsVersion",
|
|
9180
9374
|
"optional": true,
|
|
@@ -9192,7 +9386,7 @@
|
|
|
9192
9386
|
"immutable": true,
|
|
9193
9387
|
"locationInModule": {
|
|
9194
9388
|
"filename": "src/nodejs-build.ts",
|
|
9195
|
-
"line":
|
|
9389
|
+
"line": 95
|
|
9196
9390
|
},
|
|
9197
9391
|
"name": "outputEnvFile",
|
|
9198
9392
|
"optional": true,
|
|
@@ -9210,7 +9404,7 @@
|
|
|
9210
9404
|
"immutable": true,
|
|
9211
9405
|
"locationInModule": {
|
|
9212
9406
|
"filename": "src/nodejs-build.ts",
|
|
9213
|
-
"line":
|
|
9407
|
+
"line": 80
|
|
9214
9408
|
},
|
|
9215
9409
|
"name": "workingDirectory",
|
|
9216
9410
|
"optional": true,
|
|
@@ -9558,6 +9752,6 @@
|
|
|
9558
9752
|
"symbolId": "src/soci-index-v2-build:SociIndexV2BuildProps"
|
|
9559
9753
|
}
|
|
9560
9754
|
},
|
|
9561
|
-
"version": "0.0.
|
|
9562
|
-
"fingerprint": "
|
|
9755
|
+
"version": "0.0.7",
|
|
9756
|
+
"fingerprint": "dBHWACb0A5ovfQFhmdE3UaLWs8NkmTDi+vIyipfB+tw="
|
|
9563
9757
|
}
|