@aws-cdk/aws-lambda-python-alpha 2.62.2-alpha.0 → 2.63.0-alpha.0
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 +38 -7
- package/.jsii.tabl.json.gz +0 -0
- package/README.md +17 -0
- package/lib/bundling.d.ts +7 -1
- package/lib/bundling.js +2 -1
- package/lib/function.js +1 -1
- package/lib/layer.js +1 -1
- package/lib/types.d.ts +6 -1
- package/lib/types.js +1 -1
- package/package.json +7 -7
- package/rosetta/default.ts-fixture +1 -1
package/.jsii
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"url": "https://aws.amazon.com"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"aws-cdk-lib": "^2.
|
|
11
|
+
"aws-cdk-lib": "^2.63.0",
|
|
12
12
|
"constructs": "^10.0.0"
|
|
13
13
|
},
|
|
14
14
|
"dependencyClosure": {
|
|
@@ -925,6 +925,19 @@
|
|
|
925
925
|
}
|
|
926
926
|
}
|
|
927
927
|
},
|
|
928
|
+
"aws-cdk-lib.aws_devicefarm": {
|
|
929
|
+
"targets": {
|
|
930
|
+
"dotnet": {
|
|
931
|
+
"namespace": "Amazon.CDK.AWS.DeviceFarm"
|
|
932
|
+
},
|
|
933
|
+
"java": {
|
|
934
|
+
"package": "software.amazon.awscdk.services.devicefarm"
|
|
935
|
+
},
|
|
936
|
+
"python": {
|
|
937
|
+
"module": "aws_cdk.aws_devicefarm"
|
|
938
|
+
}
|
|
939
|
+
}
|
|
940
|
+
},
|
|
928
941
|
"aws-cdk-lib.aws_devopsguru": {
|
|
929
942
|
"targets": {
|
|
930
943
|
"dotnet": {
|
|
@@ -3310,7 +3323,7 @@
|
|
|
3310
3323
|
"stability": "experimental"
|
|
3311
3324
|
},
|
|
3312
3325
|
"homepage": "https://github.com/aws/aws-cdk",
|
|
3313
|
-
"jsiiVersion": "1.
|
|
3326
|
+
"jsiiVersion": "1.74.0 (build 6d08790)",
|
|
3314
3327
|
"keywords": [
|
|
3315
3328
|
"aws",
|
|
3316
3329
|
"cdk",
|
|
@@ -3331,7 +3344,7 @@
|
|
|
3331
3344
|
},
|
|
3332
3345
|
"name": "@aws-cdk/aws-lambda-python-alpha",
|
|
3333
3346
|
"readme": {
|
|
3334
|
-
"markdown": "# Amazon Lambda Python Library\n\n<!--BEGIN STABILITY BANNER-->\n\n---\n\n\n\n> The APIs of higher level constructs in this module are experimental and under active development.\n> They are subject to non-backward compatible changes or removal in any future version. These are\n> not subject to the [Semantic Versioning](https://semver.org/) model and breaking changes will be\n> announced in the release notes. This means that while you may use them, you may need to update\n> your source code when upgrading to a newer version of this package.\n\n---\n\n<!--END STABILITY BANNER-->\n\nThis library provides constructs for Python Lambda functions.\n\nTo use this module, you will need to have Docker installed.\n\n## Python Function\n\nDefine a `PythonFunction`:\n\n```ts\nnew python.PythonFunction(this, 'MyFunction', {\n entry: '/path/to/my/function', // required\n runtime: Runtime.PYTHON_3_8, // required\n index: 'my_index.py', // optional, defaults to 'index.py'\n handler: 'my_exported_func', // optional, defaults to 'handler'\n});\n```\n\nAll other properties of `lambda.Function` are supported, see also the [AWS Lambda construct library](https://github.com/aws/aws-cdk/tree/main/packages/%40aws-cdk/aws-lambda).\n\n## Python Layer\n\nYou may create a python-based lambda layer with `PythonLayerVersion`. If `PythonLayerVersion` detects a `requirements.txt`\nor `Pipfile` or `poetry.lock` with the associated `pyproject.toml` at the entry path, then `PythonLayerVersion` will include the dependencies inline with your code in the\nlayer.\n\nDefine a `PythonLayerVersion`:\n\n```ts\nnew python.PythonLayerVersion(this, 'MyLayer', {\n entry: '/path/to/my/layer', // point this to your library's directory\n})\n```\n\nA layer can also be used as a part of a `PythonFunction`:\n\n```ts\nnew python.PythonFunction(this, 'MyFunction', {\n entry: '/path/to/my/function',\n runtime: Runtime.PYTHON_3_8,\n layers: [\n new python.PythonLayerVersion(this, 'MyLayer', {\n entry: '/path/to/my/layer', // point this to your library's directory\n }),\n ],\n});\n```\n\n## Packaging\n\nIf `requirements.txt`, `Pipfile` or `poetry.lock` exists at the entry path, the construct will handle installing all required modules in a [Lambda compatible Docker container](https://gallery.ecr.aws/sam/build-python3.7) according to the `runtime` and with the Docker platform based on the target architecture of the Lambda function.\n\nPython bundles are only recreated and published when a file in a source directory has changed.\nTherefore (and as a general best-practice), it is highly recommended to commit a lockfile with a\nlist of all transitive dependencies and their exact versions. This will ensure that when any dependency version is updated, the bundle asset is recreated and uploaded.\n\nTo that end, we recommend using [`pipenv`] or [`poetry`] which have lockfile support.\n\n- [`pipenv`](https://pipenv-fork.readthedocs.io/en/latest/basics.html#example-pipfile-lock)\n- [`poetry`](https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control)\n\nPackaging is executed using the `Packaging` class, which:\n\n1. Infers the packaging type based on the files present.\n2. If it sees a `Pipfile` or a `poetry.lock` file, it exports it to a compatible `requirements.txt` file with credentials (if they're available in the source files or in the bundling container).\n3. Installs dependencies using `pip`.\n4. Copies the dependencies into an asset that is bundled for the Lambda package.\n\n**Lambda with a requirements.txt**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── requirements.txt # has to be present at the entry path\n```\n\n**Lambda with a Pipfile**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── Pipfile # has to be present at the entry path\n├── Pipfile.lock # your lock file\n```\n\n**Lambda with a poetry.lock**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── pyproject.toml # your poetry project definition\n├── poetry.lock # your poetry lock file has to be present at the entry path\n```\n\n## Custom Bundling\n\nCustom bundling can be performed by passing in additional build arguments that point to index URLs to private repos, or by using an entirely custom Docker images for bundling dependencies. The build args currently supported are:\n\n- `PIP_INDEX_URL`\n- `PIP_EXTRA_INDEX_URL`\n- `HTTPS_PROXY`\n\nAdditional build args for bundling that refer to PyPI indexes can be specified as:\n\n```ts\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n buildArgs: { PIP_INDEX_URL: \"https://your.index.url/simple/\", PIP_EXTRA_INDEX_URL: \"https://your.extra-index.url/simple/\" },\n },\n});\n```\n\nIf using a custom Docker image for bundling, the dependencies are installed with `pip`, `pipenv` or `poetry` by using the `Packaging` class. A different bundling Docker image that is in the same directory as the function can be specified as:\n\n ```ts\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: { image },\n});\n```\n\nYou can set additional Docker options to configure the build environment:\n\n ```ts\nconst entry = '/path/to/function';\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n network: 'host',\n securityOpt: 'no-new-privileges',\n user: 'user:group',\n volumesFrom: ['777f7dc92da7'],\n volumes: [{ hostPath: '/host-path', containerPath: '/container-path' }],\n },\n});\n```\n\n## Custom Bundling with Code Artifact\n\nTo use a Code Artifact PyPI repo, the `PIP_INDEX_URL` for bundling the function can be customized (requires AWS CLI in the build environment):\n\n```ts\nimport { execSync } from 'child_process';\n\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nconst domain = 'my-domain';\nconst domainOwner = '111122223333';\nconst repoName = 'my_repo';\nconst region = 'us-east-1';\nconst codeArtifactAuthToken = execSync(`aws codeartifact get-authorization-token --domain ${domain} --domain-owner ${domainOwner} --query authorizationToken --output text`).toString().trim();\n\nconst indexUrl = `https://aws:${codeArtifactAuthToken}@${domain}-${domainOwner}.d.codeartifact.${region}.amazonaws.com/pypi/${repoName}/simple/`;\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n environment: { PIP_INDEX_URL: indexUrl },\n },\n});\n```\n\nThe index URL or the token are only used during bundling and thus not included in the final asset. Setting only environment variable for `PIP_INDEX_URL` or `PIP_EXTRA_INDEX_URL` should work for accesing private Python repositories with `pip`, `pipenv` and `poetry` based dependencies.\n\nIf you also want to use the Code Artifact repo for building the base Docker image for bundling, use `buildArgs`. However, note that setting custom build args for bundling will force the base bundling image to be rebuilt every time (i.e. skip the Docker cache). Build args can be customized as:\n\n```ts\nimport { execSync } from 'child_process';\n\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nconst domain = 'my-domain';\nconst domainOwner = '111122223333';\nconst repoName = 'my_repo';\nconst region = 'us-east-1';\nconst codeArtifactAuthToken = execSync(`aws codeartifact get-authorization-token --domain ${domain} --domain-owner ${domainOwner} --query authorizationToken --output text`).toString().trim();\n\nconst indexUrl = `https://aws:${codeArtifactAuthToken}@${domain}-${domainOwner}.d.codeartifact.${region}.amazonaws.com/pypi/${repoName}/simple/`;\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n buildArgs: { PIP_INDEX_URL: indexUrl },\n },\n});\n```\n\n## Command hooks\n\nIt is possible to run additional commands by specifying the `commandHooks` prop:\n\n```ts\nconst entry = '/path/to/function';\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n commandHooks: {\n // run tests\n beforeBundling(inputDir: string): string[] {\n return ['pytest'];\n },\n afterBundling(inputDir: string): string[] {\n return ['pylint'];\n },\n // ...\n },\n },\n});\n```\n\nThe following hooks are available:\n\n- `beforeBundling`: runs before all bundling commands\n- `afterBundling`: runs after all bundling commands\n\nThey all receive the directory containing the dependencies file (`inputDir`) and the\ndirectory where the bundled asset will be output (`outputDir`). They must return\nan array of commands to run. Commands are chained with `&&`.\n\nThe commands will run in the environment in which bundling occurs: inside the\ncontainer for Docker bundling or on the host OS for local bundling.\n"
|
|
3347
|
+
"markdown": "# Amazon Lambda Python Library\n\n<!--BEGIN STABILITY BANNER-->\n\n---\n\n\n\n> The APIs of higher level constructs in this module are experimental and under active development.\n> They are subject to non-backward compatible changes or removal in any future version. These are\n> not subject to the [Semantic Versioning](https://semver.org/) model and breaking changes will be\n> announced in the release notes. This means that while you may use them, you may need to update\n> your source code when upgrading to a newer version of this package.\n\n---\n\n<!--END STABILITY BANNER-->\n\nThis library provides constructs for Python Lambda functions.\n\nTo use this module, you will need to have Docker installed.\n\n## Python Function\n\nDefine a `PythonFunction`:\n\n```ts\nnew python.PythonFunction(this, 'MyFunction', {\n entry: '/path/to/my/function', // required\n runtime: Runtime.PYTHON_3_8, // required\n index: 'my_index.py', // optional, defaults to 'index.py'\n handler: 'my_exported_func', // optional, defaults to 'handler'\n});\n```\n\nAll other properties of `lambda.Function` are supported, see also the [AWS Lambda construct library](https://github.com/aws/aws-cdk/tree/main/packages/%40aws-cdk/aws-lambda).\n\n## Python Layer\n\nYou may create a python-based lambda layer with `PythonLayerVersion`. If `PythonLayerVersion` detects a `requirements.txt`\nor `Pipfile` or `poetry.lock` with the associated `pyproject.toml` at the entry path, then `PythonLayerVersion` will include the dependencies inline with your code in the\nlayer.\n\nDefine a `PythonLayerVersion`:\n\n```ts\nnew python.PythonLayerVersion(this, 'MyLayer', {\n entry: '/path/to/my/layer', // point this to your library's directory\n})\n```\n\nA layer can also be used as a part of a `PythonFunction`:\n\n```ts\nnew python.PythonFunction(this, 'MyFunction', {\n entry: '/path/to/my/function',\n runtime: Runtime.PYTHON_3_8,\n layers: [\n new python.PythonLayerVersion(this, 'MyLayer', {\n entry: '/path/to/my/layer', // point this to your library's directory\n }),\n ],\n});\n```\n\n## Packaging\n\nIf `requirements.txt`, `Pipfile` or `poetry.lock` exists at the entry path, the construct will handle installing all required modules in a [Lambda compatible Docker container](https://gallery.ecr.aws/sam/build-python3.7) according to the `runtime` and with the Docker platform based on the target architecture of the Lambda function.\n\nPython bundles are only recreated and published when a file in a source directory has changed.\nTherefore (and as a general best-practice), it is highly recommended to commit a lockfile with a\nlist of all transitive dependencies and their exact versions. This will ensure that when any dependency version is updated, the bundle asset is recreated and uploaded.\n\nTo that end, we recommend using [`pipenv`] or [`poetry`] which have lockfile support.\n\n- [`pipenv`](https://pipenv-fork.readthedocs.io/en/latest/basics.html#example-pipfile-lock)\n- [`poetry`](https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control)\n\nPackaging is executed using the `Packaging` class, which:\n\n1. Infers the packaging type based on the files present.\n2. If it sees a `Pipfile` or a `poetry.lock` file, it exports it to a compatible `requirements.txt` file with credentials (if they're available in the source files or in the bundling container).\n3. Installs dependencies using `pip`.\n4. Copies the dependencies into an asset that is bundled for the Lambda package.\n\n**Lambda with a requirements.txt**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── requirements.txt # has to be present at the entry path\n```\n\n**Lambda with a Pipfile**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── Pipfile # has to be present at the entry path\n├── Pipfile.lock # your lock file\n```\n\n**Lambda with a poetry.lock**\n\n```plaintext\n.\n├── lambda_function.py # exports a function named 'handler'\n├── pyproject.toml # your poetry project definition\n├── poetry.lock # your poetry lock file has to be present at the entry path\n```\n\n## Custom Bundling\n\nCustom bundling can be performed by passing in additional build arguments that point to index URLs to private repos, or by using an entirely custom Docker images for bundling dependencies. The build args currently supported are:\n\n- `PIP_INDEX_URL`\n- `PIP_EXTRA_INDEX_URL`\n- `HTTPS_PROXY`\n\nAdditional build args for bundling that refer to PyPI indexes can be specified as:\n\n```ts\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n buildArgs: { PIP_INDEX_URL: \"https://your.index.url/simple/\", PIP_EXTRA_INDEX_URL: \"https://your.extra-index.url/simple/\" },\n },\n});\n```\n\nIf using a custom Docker image for bundling, the dependencies are installed with `pip`, `pipenv` or `poetry` by using the `Packaging` class. A different bundling Docker image that is in the same directory as the function can be specified as:\n\n ```ts\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: { image },\n});\n```\n\nYou can set additional Docker options to configure the build environment:\n\n ```ts\nconst entry = '/path/to/function';\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n network: 'host',\n securityOpt: 'no-new-privileges',\n user: 'user:group',\n volumesFrom: ['777f7dc92da7'],\n volumes: [{ hostPath: '/host-path', containerPath: '/container-path' }],\n },\n});\n```\n\n## Custom Bundling with Code Artifact\n\nTo use a Code Artifact PyPI repo, the `PIP_INDEX_URL` for bundling the function can be customized (requires AWS CLI in the build environment):\n\n```ts\nimport { execSync } from 'child_process';\n\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nconst domain = 'my-domain';\nconst domainOwner = '111122223333';\nconst repoName = 'my_repo';\nconst region = 'us-east-1';\nconst codeArtifactAuthToken = execSync(`aws codeartifact get-authorization-token --domain ${domain} --domain-owner ${domainOwner} --query authorizationToken --output text`).toString().trim();\n\nconst indexUrl = `https://aws:${codeArtifactAuthToken}@${domain}-${domainOwner}.d.codeartifact.${region}.amazonaws.com/pypi/${repoName}/simple/`;\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n environment: { PIP_INDEX_URL: indexUrl },\n },\n});\n```\n\nThe index URL or the token are only used during bundling and thus not included in the final asset. Setting only environment variable for `PIP_INDEX_URL` or `PIP_EXTRA_INDEX_URL` should work for accesing private Python repositories with `pip`, `pipenv` and `poetry` based dependencies.\n\nIf you also want to use the Code Artifact repo for building the base Docker image for bundling, use `buildArgs`. However, note that setting custom build args for bundling will force the base bundling image to be rebuilt every time (i.e. skip the Docker cache). Build args can be customized as:\n\n```ts\nimport { execSync } from 'child_process';\n\nconst entry = '/path/to/function';\nconst image = DockerImage.fromBuild(entry);\n\nconst domain = 'my-domain';\nconst domainOwner = '111122223333';\nconst repoName = 'my_repo';\nconst region = 'us-east-1';\nconst codeArtifactAuthToken = execSync(`aws codeartifact get-authorization-token --domain ${domain} --domain-owner ${domainOwner} --query authorizationToken --output text`).toString().trim();\n\nconst indexUrl = `https://aws:${codeArtifactAuthToken}@${domain}-${domainOwner}.d.codeartifact.${region}.amazonaws.com/pypi/${repoName}/simple/`;\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n buildArgs: { PIP_INDEX_URL: indexUrl },\n },\n});\n```\n\n## Command hooks\n\nIt is possible to run additional commands by specifying the `commandHooks` prop:\n\n```ts\nconst entry = '/path/to/function';\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n commandHooks: {\n // run tests\n beforeBundling(inputDir: string): string[] {\n return ['pytest'];\n },\n afterBundling(inputDir: string): string[] {\n return ['pylint'];\n },\n // ...\n },\n },\n});\n```\n\nThe following hooks are available:\n\n- `beforeBundling`: runs before all bundling commands\n- `afterBundling`: runs after all bundling commands\n\nThey all receive the directory containing the dependencies file (`inputDir`) and the\ndirectory where the bundled asset will be output (`outputDir`). They must return\nan array of commands to run. Commands are chained with `&&`.\n\nThe commands will run in the environment in which bundling occurs: inside the\ncontainer for Docker bundling or on the host OS for local bundling.\n\n## Docker based bundling in complex Docker configurations\n\nBy default the input and output of Docker based bundling is handled via bind mounts.\nIn situtations where this does not work, like Docker-in-Docker setups or when using a remote Docker socket, you can configure an alternative, but slower, variant that also works in these situations.\n\n```ts\nconst entry = '/path/to/function';\n\nnew python.PythonFunction(this, 'function', {\n entry,\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n bundlingFileAccess: BundlingFileAccess.VOLUME_COPY,\n },\n});\n```\n"
|
|
3335
3348
|
},
|
|
3336
3349
|
"repository": {
|
|
3337
3350
|
"directory": "packages/individual-packages/aws-lambda-python",
|
|
@@ -3453,6 +3466,24 @@
|
|
|
3453
3466
|
}
|
|
3454
3467
|
}
|
|
3455
3468
|
},
|
|
3469
|
+
{
|
|
3470
|
+
"abstract": true,
|
|
3471
|
+
"docs": {
|
|
3472
|
+
"default": "- BundlingFileAccess.BIND_MOUNT",
|
|
3473
|
+
"stability": "experimental",
|
|
3474
|
+
"summary": "Which option to use to copy the source files to the docker container and output files back."
|
|
3475
|
+
},
|
|
3476
|
+
"immutable": true,
|
|
3477
|
+
"locationInModule": {
|
|
3478
|
+
"filename": "lib/types.ts",
|
|
3479
|
+
"line": 94
|
|
3480
|
+
},
|
|
3481
|
+
"name": "bundlingFileAccess",
|
|
3482
|
+
"optional": true,
|
|
3483
|
+
"type": {
|
|
3484
|
+
"fqn": "aws-cdk-lib.BundlingFileAccess"
|
|
3485
|
+
}
|
|
3486
|
+
},
|
|
3456
3487
|
{
|
|
3457
3488
|
"abstract": true,
|
|
3458
3489
|
"docs": {
|
|
@@ -3542,7 +3573,7 @@
|
|
|
3542
3573
|
"kind": "interface",
|
|
3543
3574
|
"locationInModule": {
|
|
3544
3575
|
"filename": "lib/types.ts",
|
|
3545
|
-
"line":
|
|
3576
|
+
"line": 115
|
|
3546
3577
|
},
|
|
3547
3578
|
"methods": [
|
|
3548
3579
|
{
|
|
@@ -3554,7 +3585,7 @@
|
|
|
3554
3585
|
},
|
|
3555
3586
|
"locationInModule": {
|
|
3556
3587
|
"filename": "lib/types.ts",
|
|
3557
|
-
"line":
|
|
3588
|
+
"line": 128
|
|
3558
3589
|
},
|
|
3559
3590
|
"name": "afterBundling",
|
|
3560
3591
|
"parameters": [
|
|
@@ -3591,7 +3622,7 @@
|
|
|
3591
3622
|
},
|
|
3592
3623
|
"locationInModule": {
|
|
3593
3624
|
"filename": "lib/types.ts",
|
|
3594
|
-
"line":
|
|
3625
|
+
"line": 121
|
|
3595
3626
|
},
|
|
3596
3627
|
"name": "beforeBundling",
|
|
3597
3628
|
"parameters": [
|
|
@@ -3942,6 +3973,6 @@
|
|
|
3942
3973
|
"symbolId": "lib/layer:PythonLayerVersionProps"
|
|
3943
3974
|
}
|
|
3944
3975
|
},
|
|
3945
|
-
"version": "2.
|
|
3976
|
+
"version": "2.63.0-alpha.0",
|
|
3946
3977
|
"fingerprint": "**********"
|
|
3947
3978
|
}
|
package/.jsii.tabl.json.gz
CHANGED
|
Binary file
|
package/README.md
CHANGED
|
@@ -252,3 +252,20 @@ an array of commands to run. Commands are chained with `&&`.
|
|
|
252
252
|
|
|
253
253
|
The commands will run in the environment in which bundling occurs: inside the
|
|
254
254
|
container for Docker bundling or on the host OS for local bundling.
|
|
255
|
+
|
|
256
|
+
## Docker based bundling in complex Docker configurations
|
|
257
|
+
|
|
258
|
+
By default the input and output of Docker based bundling is handled via bind mounts.
|
|
259
|
+
In situtations where this does not work, like Docker-in-Docker setups or when using a remote Docker socket, you can configure an alternative, but slower, variant that also works in these situations.
|
|
260
|
+
|
|
261
|
+
```ts
|
|
262
|
+
const entry = '/path/to/function';
|
|
263
|
+
|
|
264
|
+
new python.PythonFunction(this, 'function', {
|
|
265
|
+
entry,
|
|
266
|
+
runtime: Runtime.PYTHON_3_8,
|
|
267
|
+
bundling: {
|
|
268
|
+
bundlingFileAccess: BundlingFileAccess.VOLUME_COPY,
|
|
269
|
+
},
|
|
270
|
+
});
|
|
271
|
+
```
|
package/lib/bundling.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Architecture, AssetCode, Runtime } from 'aws-cdk-lib/aws-lambda';
|
|
2
|
-
import { BundlingOptions as CdkBundlingOptions, DockerImage, DockerVolume } from 'aws-cdk-lib';
|
|
2
|
+
import { BundlingFileAccess, BundlingOptions as CdkBundlingOptions, DockerImage, DockerVolume } from 'aws-cdk-lib';
|
|
3
3
|
import { BundlingOptions } from './types';
|
|
4
4
|
/**
|
|
5
5
|
* Dependency files to exclude from the asset hash.
|
|
@@ -33,6 +33,11 @@ export interface BundlingProps extends BundlingOptions {
|
|
|
33
33
|
* @default - Does not skip bundling
|
|
34
34
|
*/
|
|
35
35
|
readonly skip?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Which option to use to copy the source files to the docker container and output files back
|
|
38
|
+
* @default - BundlingFileAccess.BIND_MOUNT
|
|
39
|
+
*/
|
|
40
|
+
bundlingFileAccess?: BundlingFileAccess;
|
|
36
41
|
}
|
|
37
42
|
/**
|
|
38
43
|
* Produce bundled Lambda asset code
|
|
@@ -51,6 +56,7 @@ export declare class Bundling implements CdkBundlingOptions {
|
|
|
51
56
|
readonly user?: string;
|
|
52
57
|
readonly securityOpt?: string;
|
|
53
58
|
readonly network?: string;
|
|
59
|
+
readonly bundlingFileAccess?: BundlingFileAccess;
|
|
54
60
|
constructor(props: BundlingProps);
|
|
55
61
|
private createBundlingCommand;
|
|
56
62
|
}
|
package/lib/bundling.js
CHANGED
|
@@ -43,6 +43,7 @@ class Bundling {
|
|
|
43
43
|
this.user = props.user;
|
|
44
44
|
this.securityOpt = props.securityOpt;
|
|
45
45
|
this.network = props.network;
|
|
46
|
+
this.bundlingFileAccess = props.bundlingFileAccess;
|
|
46
47
|
}
|
|
47
48
|
static bundle(options) {
|
|
48
49
|
return aws_lambda_1.Code.fromAsset(options.entry, {
|
|
@@ -73,4 +74,4 @@ exports.Bundling = Bundling;
|
|
|
73
74
|
function chain(commands) {
|
|
74
75
|
return commands.filter(c => !!c).join(' && ');
|
|
75
76
|
}
|
|
76
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
77
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYnVuZGxpbmcuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJidW5kbGluZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSw2QkFBNkI7QUFDN0IsdURBQWdGO0FBQ2hGLDZDQUFpSTtBQUNqSSwyQ0FBMEQ7QUFHMUQ7O0dBRUc7QUFDVSxRQUFBLG1CQUFtQixHQUFHLENBQUMsT0FBTyxDQUFDLENBQUM7QUFFN0M7O0dBRUc7QUFDVSxRQUFBLDBC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YWdpbmcuZXhwb3J0Q29tbWFuZCA/PyAnJyk7XG4gICAgaWYgKHBhY2thZ2luZy5kZXBlbmRlbmNpZXNGaWxlKSB7XG4gICAgICBidW5kbGluZ0NvbW1hbmRzLnB1c2goYHB5dGhvbiAtbSBwaXAgaW5zdGFsbCAtciAke0RlcGVuZGVuY2llc0ZpbGUuUElQfSAtdCAke29wdGlvbnMub3V0cHV0RGlyfWApO1xuICAgIH1cbiAgICBidW5kbGluZ0NvbW1hbmRzLnB1c2goLi4ub3B0aW9ucy5jb21tYW5kSG9va3M/LmFmdGVyQnVuZGxpbmcob3B0aW9ucy5pbnB1dERpciwgb3B0aW9ucy5vdXRwdXREaXIpID8/IFtdKTtcbiAgICByZXR1cm4gYnVuZGxpbmdDb21tYW5kcztcbiAgfVxufVxuXG5pbnRlcmZhY2UgQnVuZGxpbmdDb21tYW5kT3B0aW9ucyB7XG4gIHJlYWRvbmx5IGVudHJ5OiBzdHJpbmc7XG4gIHJlYWRvbmx5IGlucHV0RGlyOiBzdHJpbmc7XG4gIHJlYWRvbmx5IG91dHB1dERpcjogc3RyaW5nO1xuICByZWFkb25seSBwb2V0cnlJbmNsdWRlSGFzaGVzPzogYm9vbGVhbjtcbiAgcmVhZG9ubHkgY29tbWFuZEhvb2tzPzogSUNvbW1hbmRIb29rc1xufVxuXG4vKipcbiAqIENoYWluIGNvbW1hbmRzXG4gKi9cbmZ1bmN0aW9uIGNoYWluKGNvbW1hbmRzOiBzdHJpbmdbXSk6IHN0cmluZyB7XG4gIHJldHVybiBjb21tYW5kcy5maWx0ZXIoYyA9PiAhIWMpLmpvaW4oJyAmJiAnKTtcbn1cbiJdfQ==
|
package/lib/function.js
CHANGED
|
@@ -52,5 +52,5 @@ class PythonFunction extends aws_lambda_1.Function {
|
|
|
52
52
|
}
|
|
53
53
|
exports.PythonFunction = PythonFunction;
|
|
54
54
|
_a = JSII_RTTI_SYMBOL_1;
|
|
55
|
-
PythonFunction[_a] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonFunction", version: "2.
|
|
55
|
+
PythonFunction[_a] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonFunction", version: "2.63.0-alpha.0" };
|
|
56
56
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZnVuY3Rpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJmdW5jdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSx5QkFBeUI7QUFDekIsNkJBQTZCO0FBQzdCLHVEQUEyRjtBQUMzRiw2Q0FBb0M7QUFFcEMseUNBQXNDO0FBNEN0Qzs7R0FFRztBQUNILE1BQWEsY0FBZSxTQUFRLHFCQUFRO0lBQzFDLFlBQVksS0FBZ0IsRUFBRSxFQUFVLEVBQUUsS0FBMEI7Ozs7OzsrQ0FEekQsY0FBYzs7OztRQUV2QixNQUFNLEVBQUUsS0FBSyxHQUFHLFVBQVUsRUFBRSxPQUFPLEdBQUcsU0FBUyxFQUFFLE9BQU8sRUFBRSxHQUFHLEtBQUssQ0FBQztRQUNuRSxJQUFJLEtBQUssQ0FBQyxLQUFLLElBQUksQ0FBQyxPQUFPLENBQUMsSUFBSSxDQUFDLEtBQUssQ0FBQyxLQUFLLENBQUMsRUFBRTtZQUM3QyxNQUFNLElBQUksS0FBSyxDQUFDLDhDQUE4QyxDQUFDLENBQUM7U0FDakU7UUFFRCxRQUFRO1FBQ1IsTUFBTSxLQUFLLEdBQUcsSUFBSSxDQUFDLE9BQU8sQ0FBQyxLQUFLLENBQUMsS0FBSyxDQUFDLENBQUM7UUFDeEMsTUFBTSxhQUFhLEdBQUcsSUFBSSxDQUFDLE9BQU8sQ0FBQyxLQUFLLEVBQUUsS0FBSyxDQUFDLENBQUM7UUFDakQsSUFBSSxDQUFDLEVBQUUsQ0FBQyxVQUFVLENBQUMsYUFBYSxDQUFDLEVBQUU7WUFDakMsTUFBTSxJQUFJLEtBQU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9IHBhdGgucmVzb2x2ZShlbnRyeSwgaW5kZXgpO1xuICAgIGlmICghZnMuZXhpc3RzU3luYyhyZXNvbHZlZEluZGV4KSkge1xuICAgICAgdGhyb3cgbmV3IEVycm9yKGBDYW5ub3QgZmluZCBpbmRleCBmaWxlIGF0ICR7cmVzb2x2ZWRJbmRleH1gKTtcbiAgICB9XG5cbiAgICBjb25zdCByZXNvbHZlZEhhbmRsZXIgPWAke2luZGV4LnNsaWNlKDAsIC0zKX0uJHtoYW5kbGVyfWAucmVwbGFjZSgvXFwvL2csICcuJyk7XG5cbiAgICBpZiAocHJvcHMucnVudGltZSAmJiBwcm9wcy5ydW50aW1lLmZhbWlseSAhPT0gUnVudGltZUZhbWlseS5QWVRIT04pIHtcbiAgICAgIHRocm93IG5ldyBFcnJvcignT25seSBgUFlUSE9OYCBydW50aW1lcyBhcmUgc3VwcG9ydGVkLicpO1xuICAgIH1cblxuICAgIHN1cGVyKHNjb3BlLCBpZCwge1xuICAgICAgLi4ucHJvcHMsXG4gICAgICBydW50aW1lLFxuICAgICAgY29kZTogQnVuZGxpbmcuYnVuZGxlKHtcbiAgICAgICAgZW50cnksXG4gICAgICAgIHJ1bnRpbWUsXG4gICAgICAgIHNraXA6ICFTdGFjay5vZihzY29wZSkuYnVuZGxpbmdSZXF1aXJlZCxcbiAgICAgICAgLi4ucHJvcHMuYnVuZGxpbmcsXG4gICAgICB9KSxcbiAgICAgIGhhbmRsZXI6IHJlc29sdmVkSGFuZGxlcixcbiAgICB9KTtcbiAgfVxufVxuIl19
|
package/lib/layer.js
CHANGED
|
@@ -52,5 +52,5 @@ class PythonLayerVersion extends lambda.LayerVersion {
|
|
|
52
52
|
}
|
|
53
53
|
exports.PythonLayerVersion = PythonLayerVersion;
|
|
54
54
|
_a = JSII_RTTI_SYMBOL_1;
|
|
55
|
-
PythonLayerVersion[_a] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonLayerVersion", version: "2.
|
|
55
|
+
PythonLayerVersion[_a] =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WN0dXJlc1swXTtcblxuICAgIHN1cGVyKHNjb3BlLCBpZCwge1xuICAgICAgLi4ucHJvcHMsXG4gICAgICBjb21wYXRpYmxlUnVudGltZXMsXG4gICAgICBjb2RlOiBCdW5kbGluZy5idW5kbGUoe1xuICAgICAgICBlbnRyeSxcbiAgICAgICAgcnVudGltZSxcbiAgICAgICAgYXJjaGl0ZWN0dXJlLFxuICAgICAgICBvdXRwdXRQYXRoU3VmZml4OiAncHl0aG9uJyxcbiAgICAgICAgc2tpcDogIVN0YWNrLm9mKHNjb3BlKS5idW5kbGluZ1JlcXVpcmVkLFxuICAgICAgICAuLi5wcm9wcy5idW5kbGluZyxcbiAgICAgIH0pLFxuICAgIH0pO1xuICB9XG59XG4iXX0=
|
package/lib/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AssetHashType, DockerImage, DockerRunOptions } from 'aws-cdk-lib';
|
|
1
|
+
import { AssetHashType, BundlingFileAccess, DockerImage, DockerRunOptions } from 'aws-cdk-lib';
|
|
2
2
|
/**
|
|
3
3
|
* Options for bundling
|
|
4
4
|
*/
|
|
@@ -78,6 +78,11 @@ export interface BundlingOptions extends DockerRunOptions {
|
|
|
78
78
|
* @default - do not run additional commands
|
|
79
79
|
*/
|
|
80
80
|
readonly commandHooks?: ICommandHooks;
|
|
81
|
+
/**
|
|
82
|
+
* Which option to use to copy the source files to the docker container and output files back
|
|
83
|
+
* @default - BundlingFileAccess.BIND_MOUNT
|
|
84
|
+
*/
|
|
85
|
+
readonly bundlingFileAccess?: BundlingFileAccess;
|
|
81
86
|
}
|
|
82
87
|
/**
|
|
83
88
|
* Command hooks
|
package/lib/types.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
3
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlI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XRoIGAmJmAuXG4gKlxuICogYGBgdGV4dFxuICoge1xuICogICAvLyBSdW4gdGVzdHMgcHJpb3IgdG8gYnVuZGxpbmdcbiAqICAgYmVmb3JlQnVuZGxpbmcoaW5wdXREaXI6IHN0cmluZywgb3V0cHV0RGlyOiBzdHJpbmcpOiBzdHJpbmdbXSB7XG4gKiAgICAgcmV0dXJuIFtgcHl0ZXN0YF07XG4gKiAgIH1cbiAqICAgLy8gLi4uXG4gKiB9XG4gKiBgYGBcbiAqL1xuZXhwb3J0IGludGVyZmFjZSBJQ29tbWFuZEhvb2tzIHtcbiAgLyoqXG4gICAqIFJldHVybnMgY29tbWFuZHMgdG8gcnVuIGJlZm9yZSBidW5kbGluZy5cbiAgICpcbiAgICogQ29tbWFuZHMgYXJlIGNoYWluZWQgd2l0aCBgJiZgLlxuICAgKi9cbiAgYmVmb3JlQnVuZGxpbmcoaW5wdXREaXI6IHN0cmluZywgb3V0cHV0RGlyOiBzdHJpbmcpOiBzdHJpbmdbXTtcblxuICAvKipcbiAgICogUmV0dXJucyBjb21tYW5kcyB0byBydW4gYWZ0ZXIgYnVuZGxpbmcuXG4gICAqXG4gICAqIENvbW1hbmRzIGFyZSBjaGFpbmVkIHdpdGggYCYmYC5cbiAgICovXG4gIGFmdGVyQnVuZGxpbmcoaW5wdXREaXI6IHN0cmluZywgb3V0cHV0RGlyOiBzdHJpbmcpOiBzdHJpbmdbXTtcbn1cbiJdfQ==
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-cdk/aws-lambda-python-alpha",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.63.0-alpha.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The CDK Construct Library for AWS Lambda in Python",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -76,18 +76,18 @@
|
|
|
76
76
|
},
|
|
77
77
|
"license": "Apache-2.0",
|
|
78
78
|
"devDependencies": {
|
|
79
|
-
"@aws-cdk/cdk-build-tools": "2.
|
|
80
|
-
"@aws-cdk/integ-runner": "2.
|
|
81
|
-
"@aws-cdk/pkglint": "2.
|
|
79
|
+
"@aws-cdk/cdk-build-tools": "2.63.0",
|
|
80
|
+
"@aws-cdk/integ-runner": "2.63.0",
|
|
81
|
+
"@aws-cdk/pkglint": "2.63.0",
|
|
82
82
|
"@types/jest": "^27.5.2",
|
|
83
|
-
"aws-cdk-lib": "2.
|
|
83
|
+
"aws-cdk-lib": "2.63.0",
|
|
84
84
|
"constructs": "^10.0.0",
|
|
85
|
-
"@aws-cdk/integ-tests-alpha": "2.
|
|
85
|
+
"@aws-cdk/integ-tests-alpha": "2.63.0-alpha.0"
|
|
86
86
|
},
|
|
87
87
|
"dependencies": {},
|
|
88
88
|
"homepage": "https://github.com/aws/aws-cdk",
|
|
89
89
|
"peerDependencies": {
|
|
90
|
-
"aws-cdk-lib": "^2.
|
|
90
|
+
"aws-cdk-lib": "^2.63.0",
|
|
91
91
|
"constructs": "^10.0.0"
|
|
92
92
|
},
|
|
93
93
|
"engines": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Fixture with packages imported, but nothing else
|
|
2
2
|
import { Construct } from 'constructs';
|
|
3
|
-
import { DockerImage, Stack } from 'aws-cdk-lib';
|
|
3
|
+
import { DockerImage, Stack, BundlingFileAccess } from 'aws-cdk-lib';
|
|
4
4
|
import { Runtime } from 'aws-cdk-lib/aws-lambda';
|
|
5
5
|
import * as python from '@aws-cdk/aws-lambda-python-alpha';
|
|
6
6
|
|