@aws-cdk/aws-lambda-python-alpha 2.176.0-alpha.0 → 2.177.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 +30 -4
- package/.jsii.tabl.json.gz +0 -0
- package/README.md +2 -2
- package/lib/function.js +3 -3
- package/lib/layer.js +1 -1
- package/lib/packaging.js +1 -1
- package/package.json +7 -7
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.177.0",
|
|
12
12
|
"constructs": "^10.0.0"
|
|
13
13
|
},
|
|
14
14
|
"dependencyClosure": {
|
|
@@ -2567,6 +2567,32 @@
|
|
|
2567
2567
|
}
|
|
2568
2568
|
}
|
|
2569
2569
|
},
|
|
2570
|
+
"aws-cdk-lib.aws_notifications": {
|
|
2571
|
+
"targets": {
|
|
2572
|
+
"dotnet": {
|
|
2573
|
+
"package": "Amazon.CDK.AWS.Notifications"
|
|
2574
|
+
},
|
|
2575
|
+
"java": {
|
|
2576
|
+
"package": "software.amazon.awscdk.services.notifications"
|
|
2577
|
+
},
|
|
2578
|
+
"python": {
|
|
2579
|
+
"module": "aws_cdk.aws_notifications"
|
|
2580
|
+
}
|
|
2581
|
+
}
|
|
2582
|
+
},
|
|
2583
|
+
"aws-cdk-lib.aws_notificationscontacts": {
|
|
2584
|
+
"targets": {
|
|
2585
|
+
"dotnet": {
|
|
2586
|
+
"package": "Amazon.CDK.AWS.NotificationsContacts"
|
|
2587
|
+
},
|
|
2588
|
+
"java": {
|
|
2589
|
+
"package": "software.amazon.awscdk.services.notificationscontacts"
|
|
2590
|
+
},
|
|
2591
|
+
"python": {
|
|
2592
|
+
"module": "aws_cdk.aws_notificationscontacts"
|
|
2593
|
+
}
|
|
2594
|
+
}
|
|
2595
|
+
},
|
|
2570
2596
|
"aws-cdk-lib.aws_oam": {
|
|
2571
2597
|
"targets": {
|
|
2572
2598
|
"dotnet": {
|
|
@@ -3913,7 +3939,7 @@
|
|
|
3913
3939
|
"stability": "experimental"
|
|
3914
3940
|
},
|
|
3915
3941
|
"homepage": "https://github.com/aws/aws-cdk",
|
|
3916
|
-
"jsiiVersion": "5.7.
|
|
3942
|
+
"jsiiVersion": "5.7.4 (build fc2a28e)",
|
|
3917
3943
|
"keywords": [
|
|
3918
3944
|
"aws",
|
|
3919
3945
|
"cdk",
|
|
@@ -3934,7 +3960,7 @@
|
|
|
3934
3960
|
},
|
|
3935
3961
|
"name": "@aws-cdk/aws-lambda-python-alpha",
|
|
3936
3962
|
"readme": {
|
|
3937
|
-
"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/aws-cdk-lib/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**Excluding source files**\n\nYou can exclude files from being copied using the optional bundling string array parameter `assetExcludes`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n // translates to `rsync --exclude='.venv'`\n assetExcludes: ['.venv'],\n },\n});\n```\n\n**Including hashes**\n\nYou can include hashes in `poetry` using the optional boolean parameter `poetryIncludeHashes`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n poetryIncludeHashes: true,\n },\n});\n```\n\n**Excluding URLs**\n\nYou can exclude URLs in `poetry` using the optional boolean parameter `poetryWithoutUrls`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n poetryWithoutUrls: true,\n },\n});\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\n## Troubleshooting\n\n### Containerfile: no such file or directory\n\nIf you are on a Mac, using [Finch](https://github.com/runfinch/finch) instead of Docker, and see an error\nlike this:\n\n```txt\nlstat /private/var/folders/zx/d5wln9n10sn0tcj1v9798f1c0000gr/T/jsii-kernel-9VYgrO/node_modules/@aws-cdk/aws-lambda-python-alpha/lib/Containerfile: no such file or directory\n```\n\nThat is a sign that your temporary directory has not been mapped into the Finch VM. Add the following to `~/.finch/finch.yaml`:\n\n```yaml\nadditional_directories:\n - path: /private/var/folders/\n - path: /var/folders/\n```\n\nThen restart the Finch VM by running `finch vm stop && finch vm start`.\n"
|
|
3963
|
+
"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/aws-cdk-lib/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**Excluding source files**\n\nYou can exclude files from being copied using the optional bundling string array parameter `assetExcludes`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n // translates to `rsync --exclude='.venv'`\n assetExcludes: ['.venv'],\n },\n});\n```\n\n**Including hashes**\n\nYou can include hashes in `poetry` using the optional boolean parameter `poetryIncludeHashes`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n poetryIncludeHashes: true,\n },\n});\n```\n\n**Excluding URLs**\n\nYou can exclude URLs in `poetry` using the optional boolean parameter `poetryWithoutUrls`:\n\n```ts\nnew python.PythonFunction(this, 'function', {\n entry: '/path/to/poetry-function',\n runtime: Runtime.PYTHON_3_8,\n bundling: {\n poetryWithoutUrls: true,\n },\n});\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 accessing 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 situations 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\n## Troubleshooting\n\n### Containerfile: no such file or directory\n\nIf you are on a Mac, using [Finch](https://github.com/runfinch/finch) instead of Docker, and see an error\nlike this:\n\n```txt\nlstat /private/var/folders/zx/d5wln9n10sn0tcj1v9798f1c0000gr/T/jsii-kernel-9VYgrO/node_modules/@aws-cdk/aws-lambda-python-alpha/lib/Containerfile: no such file or directory\n```\n\nThat is a sign that your temporary directory has not been mapped into the Finch VM. Add the following to `~/.finch/finch.yaml`:\n\n```yaml\nadditional_directories:\n - path: /private/var/folders/\n - path: /var/folders/\n```\n\nThen restart the Finch VM by running `finch vm stop && finch vm start`.\n"
|
|
3938
3964
|
},
|
|
3939
3965
|
"repository": {
|
|
3940
3966
|
"directory": "packages/@aws-cdk/aws-lambda-python-alpha",
|
|
@@ -4603,6 +4629,6 @@
|
|
|
4603
4629
|
"symbolId": "lib/layer:PythonLayerVersionProps"
|
|
4604
4630
|
}
|
|
4605
4631
|
},
|
|
4606
|
-
"version": "2.
|
|
4632
|
+
"version": "2.177.0-alpha.0",
|
|
4607
4633
|
"fingerprint": "**********"
|
|
4608
4634
|
}
|
package/.jsii.tabl.json.gz
CHANGED
|
Binary file
|
package/README.md
CHANGED
|
@@ -233,7 +233,7 @@ new python.PythonFunction(this, 'function', {
|
|
|
233
233
|
});
|
|
234
234
|
```
|
|
235
235
|
|
|
236
|
-
The 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
|
|
236
|
+
The 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 accessing private Python repositories with `pip`, `pipenv` and `poetry` based dependencies.
|
|
237
237
|
|
|
238
238
|
If 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:
|
|
239
239
|
|
|
@@ -299,7 +299,7 @@ container for Docker bundling or on the host OS for local bundling.
|
|
|
299
299
|
## Docker based bundling in complex Docker configurations
|
|
300
300
|
|
|
301
301
|
By default the input and output of Docker based bundling is handled via bind mounts.
|
|
302
|
-
In
|
|
302
|
+
In situations 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.
|
|
303
303
|
|
|
304
304
|
```ts
|
|
305
305
|
const entry = '/path/to/function';
|
package/lib/function.js
CHANGED
|
@@ -44,7 +44,7 @@ class PythonFunction extends aws_lambda_1.Function {
|
|
|
44
44
|
entry,
|
|
45
45
|
runtime,
|
|
46
46
|
skip: !core_1.Stack.of(scope).bundlingRequired,
|
|
47
|
-
// define architecture based on the target architecture of the function, possibly
|
|
47
|
+
// define architecture based on the target architecture of the function, possibly overridden in bundling options
|
|
48
48
|
architecture: props.architecture,
|
|
49
49
|
...props.bundling,
|
|
50
50
|
}),
|
|
@@ -54,5 +54,5 @@ class PythonFunction extends aws_lambda_1.Function {
|
|
|
54
54
|
}
|
|
55
55
|
exports.PythonFunction = PythonFunction;
|
|
56
56
|
_a = JSII_RTTI_SYMBOL_1;
|
|
57
|
-
PythonFunction[_a] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonFunction", version: "2.
|
|
58
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
57
|
+
PythonFunction[_a] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonFunction", version: "2.177.0-alpha.0" };
|
|
58
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZnVuY3Rpb24uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJmdW5jdGlvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSx5QkFBeUI7QUFDekIsNkJBQTZCO0FBQzdCLHVEQUEyRjtBQUMzRiwyQ0FBeUM7QUFFekMseUNBQXNDO0FBeUN0Qzs7R0FFRztBQUNILE1BQWEsY0FBZSxTQUFRLHFCQUFRO0lBQzFDLFlBQVksS0FBZ0IsRUFBRSxFQUFVLEVBQUUsS0FBMEI7Ozs7OzsrQ0FEekQsY0FBYzs7OztRQUV2QixNQUFNLEVBQUUsS0FBSyxHQUFHLFVBQVUsRUFBRSxPQUFPLEdBQUcsU0FBUyxFQUFFLE9BQU8sRUFBRSxHQUFHLEtBQUssQ0FBQztRQUNuRSxJQUFJLEtBQUssQ0FBQyxLQUFLLElBQUksQ0FBQyxPQUFPLENBQUMsSUFBSSxDQUFDLEtBQUssQ0FBQyxLQUFLLENBQUMsRUFBRSxDQUFDO1lBQzlDLE1BQU0sSUFBSSxLQUFLLENBQUMsOENBQThDLENBQUMsQ0FBQztRQUNsRSxDQUFDO1FBRUQsUUFBUTtRQUNSLE1BQU0sS0FBSyxHQUFHLElBQUksQ0FBQyxPQUFPLENBQUMsS0FBSyxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQ3hDLE1BQU0sYUFBYSx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ICAgICAgIGFyY2hpdGVjdHVyZTogcHJvcHMuYXJjaGl0ZWN0dXJlLFxuICAgICAgICAuLi5wcm9wcy5idW5kbGluZyxcbiAgICAgIH0pLFxuICAgICAgaGFuZGxlcjogcmVzb2x2ZWRIYW5kbGVyLFxuICAgIH0pO1xuICB9XG59XG4iXX0=
|
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] = { fqn: "@aws-cdk/aws-lambda-python-alpha.PythonLayerVersion", version: "2.177.0-alpha.0" };
|
|
56
56
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibGF5ZXIuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJsYXllci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7QUFBQSw2QkFBNkI7QUFDN0IsaURBQWlEO0FBQ2pELDJDQUF5QztBQUV6Qyx5Q0FBc0M7QUFpQ3RDOzs7R0FHRztBQUNILE1BQWEsa0JBQW1CLFNBQVEsTUFBTSxDQUFDLFlBQVk7SUFDekQsWUFBWSxLQUFnQixFQUFFLEVBQVUsRUFBRSxLQUE4Qjs7Ozs7OytDQUQ3RCxrQkFBa0I7Ozs7UUFFM0IsTUFBTSxrQkFBa0IsR0FBRyxLQUFLLENBQUMsa0JBQWtCLElBQUksQ0FBQyxNQUFNLENBQUMsT0FBTyxDQUFDLFVBQVUsQ0FBQyxDQUFDO1FBQ25GLE1BQU0sdUJBQXVCLEdBQUcsS0FBSyxDQUFDLHVCQUF1QixJQUFJLENBQUMsTUFBTSxDQUFDLFlBQVksQ0FBQ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S5QWVRIT04pIHtcbiAgICAgICAgdGhyb3cgbmV3IEVycm9yKCdPbmx5IGBQWVRIT05gIHJ1bnRpbWVzIGFyZSBzdXBwb3J0ZWQuJyk7XG4gICAgICB9XG4gICAgfVxuXG4gICAgLy8gRW50cnkgYW5kIGRlZmF1bHRzXG4gICAgY29uc3QgZW50cnkgPSBwYXRoLnJlc29sdmUocHJvcHMuZW50cnkpO1xuICAgIC8vIFBpY2sgdGhlIGZpcnN0IGNvbXBhdGlibGVSdW50aW1lIGFuZCBjb21wYXRpYmxlQXJjaGl0ZWN0dXJlcyB0byB1c2UgZm9yIGJ1bmRsaW5nXG4gICAgY29uc3QgcnVudGltZSA9IGNvbXBhdGlibGVSdW50aW1lc1swXTtcbiAgICBjb25zdCBhcmNoaXRlY3R1cmUgPSBjb21wYXRpYmxlQXJjaGl0ZWN0dXJlc1swXTtcblxuICAgIHN1cGVyKHNjb3BlLCBpZCwge1xuICAgICAgLi4ucHJvcHMsXG4gICAgICBjb21wYXRpYmxlUnVudGltZXMsXG4gICAgICBjb2RlOiBCdW5kbGluZy5idW5kbGUoe1xuICAgICAgICBlbnRyeSxcbiAgICAgICAgcnVudGltZSxcbiAgICAgICAgYXJjaGl0ZWN0dXJlLFxuICAgICAgICBvdXRwdXRQYXRoU3VmZml4OiAncHl0aG9uJyxcbiAgICAgICAgc2tpcDogIVN0YWNrLm9mKHNjb3BlKS5idW5kbGluZ1JlcXVpcmVkLFxuICAgICAgICAuLi5wcm9wcy5idW5kbGluZyxcbiAgICAgIH0pLFxuICAgIH0pO1xuICB9XG59XG4iXX0=
|
package/lib/packaging.js
CHANGED
|
@@ -73,4 +73,4 @@ class Packaging {
|
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
75
|
exports.Packaging = Packaging;
|
|
76
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
76
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGFja2FnaW5nLmpzIiwic291cmNl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b2V0cnkoeyBwb2V0cnlJbmNsdWRlSGFzaGVzLCBwb2V0cnlXaXRob3V0VXJscyB9KTtcbiAgICB9IGVsc2UgaWYgKGZzLmV4aXN0c1N5bmMocGF0aC5qb2luKGVudHJ5LCBEZXBlbmRlbmNpZXNGaWxlLlBJUCkpKSB7XG4gICAgICByZXR1cm4gdGhpcy53aXRoUGlwKCk7XG4gICAgfSBlbHNlIHtcbiAgICAgIHJldHVybiB0aGlzLndpdGhOb1BhY2thZ2luZygpO1xuICAgIH1cbiAgfVxuXG4gIHB1YmxpYyByZWFkb25seSBkZXBlbmRlbmNpZXNGaWxlOiBzdHJpbmc7XG4gIHB1YmxpYyByZWFkb25seSBleHBvcnRDb21tYW5kPzogc3RyaW5nO1xuICBjb25zdHJ1Y3Rvcihwcm9wczogUGFja2FnaW5nUHJvcHMpIHtcbiAgICB0aGlzLmRlcGVuZGVuY2llc0ZpbGUgPSBwcm9wcy5kZXBlbmRlbmNpZXNGaWxlO1xuICAgIHRoaXMuZXhwb3J0Q29tbWFuZCA9IHByb3BzLmV4cG9ydENvbW1hbmQ7XG4gIH1cbn1cbiJdfQ==
|
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.177.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.177.0-alpha.0",
|
|
80
|
+
"@aws-cdk/integ-runner": "2.177.0-alpha.0",
|
|
81
|
+
"@aws-cdk/pkglint": "2.177.0-alpha.0",
|
|
82
82
|
"@types/jest": "^29.5.14",
|
|
83
|
-
"aws-cdk-lib": "2.
|
|
83
|
+
"aws-cdk-lib": "2.177.0",
|
|
84
84
|
"constructs": "^10.0.0",
|
|
85
|
-
"@aws-cdk/integ-tests-alpha": "2.
|
|
85
|
+
"@aws-cdk/integ-tests-alpha": "2.177.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.177.0",
|
|
91
91
|
"constructs": "^10.0.0"
|
|
92
92
|
},
|
|
93
93
|
"engines": {
|