From fefee10b10563d5e1e42dbec5d01597b8a04f3fa Mon Sep 17 00:00:00 2001 From: Lucas <12496191+lucashuy@users.noreply.github.com> Date: Tue, 6 Feb 2024 16:47:39 -0800 Subject: [PATCH 1/2] chore(deps-dev): Update pytest, pytest-metadata, and changed to pytest-json-report-wip (#6648) * chore(deps-dev): bump pytest-metadata in /requirements Bumps [pytest-metadata](https://github.com/pytest-dev/pytest-metadata) from 2.0.4 to 3.1.0. - [Changelog](https://github.com/pytest-dev/pytest-metadata/blob/master/CHANGES.rst) - [Commits](https://github.com/pytest-dev/pytest-metadata/compare/v2.0.4...3.1.0) --- updated-dependencies: - dependency-name: pytest-metadata dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] * Bump pytest to v8 and switch json-report to fork * Added comment --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- requirements/dev.txt | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/requirements/dev.txt b/requirements/dev.txt index 05585cb879..b6000c165f 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -24,15 +24,16 @@ types-requests==2.31.0.6 types-urllib3==1.26.25.14 # Test requirements -pytest~=7.4.4 +pytest~=8.0.0 parameterized==0.9.0 pytest-xdist==3.5.0 pytest-forked==1.6.0 pytest-timeout==2.2.0 pytest-rerunfailures==13.0 # NOTE (hawflau): DO NOT upgrade pytest-metadata and pytest-json-report unless pytest-json-report addresses https://github.com/numirias/pytest-json-report/issues/89 -pytest-metadata==2.0.4 -pytest-json-report==1.5.0 +pytest-metadata==3.1.0 +# NOTE (lucashuy): `pytest-json-report` was updated to `pytest-json-report-wip` as the original repository does not seem to be maintained anymore, if `-wip` is updated, validate the changes +pytest-json-report-wip==1.5.1 filelock==3.13.1 # formatter From 06502930837677227f7975c93402039821d1f0ea Mon Sep 17 00:00:00 2001 From: Daniel Mil <84205762+mildaniel@users.noreply.github.com> Date: Thu, 8 Feb 2024 10:04:28 -0800 Subject: [PATCH 2/2] chore: Deprecate Nodejs12 and Nodejs14 (#6664) * chore: Deprecate Nodejs12 and Nodejs14 * Make Windows container tests Node18 --- designs/build_for_provided_runtimes.md | 2 +- samcli/commands/_utils/options.py | 3 +- samcli/commands/local/cli_common/options.py | 4 +- samcli/lib/build/workflow_config.py | 6 +- samcli/lib/init/local_manifest.json | 14 +- .../cookiecutter.json | 2 +- samcli/lib/utils/architecture.py | 2 - samcli/local/common/runtime_template.py | 6 +- samcli/local/docker/lambda_debug_settings.py | 28 ---- samcli/local/docker/lambda_image.py | 4 +- schema/samcli.json | 30 ++-- .../function_with_image_in_metadata.yaml | 2 +- tests/integration/buildcmd/test_build_cmd.py | 34 ++-- .../buildcmd/test_build_cmd_arm64.py | 12 +- .../validate/default_json/template.json | 2 +- .../validate/multiple_files/template.json | 2 +- .../with_build/.aws-sam/build/template.yaml | 2 +- .../validate/with_build/template.json | 2 +- .../validate/test_validate_command.py | 1 - tests/unit/commands/init/test_cli.py | 52 +++--- tests/unit/commands/init/test_manifest.json | 4 +- .../unit/commands/samconfig/test_samconfig.py | 4 +- .../terraform/hooks/prepare/prepare_base.py | 4 +- .../terraform/hooks/prepare/test_hook.py | 8 +- .../hooks/prepare/test_resource_linking.py | 2 +- .../unit/lib/build_module/test_build_graph.py | 2 +- .../lib/build_module/test_build_strategy.py | 8 +- .../lib/build_module/test_workflow_config.py | 4 +- .../test_image_repository_validation.py | 152 +++++++++--------- tests/unit/lib/utils/test_architecture.py | 2 +- tests/unit/lib/utils/test_lambda_builders.py | 2 +- .../docker/test_lambda_build_container.py | 2 +- .../local/docker/test_lambda_container.py | 4 +- .../docker/test_lambda_debug_settings.py | 2 - tests/unit/local/docker/test_lambda_image.py | 4 +- 35 files changed, 181 insertions(+), 233 deletions(-) diff --git a/designs/build_for_provided_runtimes.md b/designs/build_for_provided_runtimes.md index e031af20ca..605cc33209 100644 --- a/designs/build_for_provided_runtimes.md +++ b/designs/build_for_provided_runtimes.md @@ -7,7 +7,7 @@ What will be changed? --------------------- Serverless Function resources can now have a Metadata Resource Attribute which specifies a `BuildMethod`. -`BuildMethod` will either be the official lambda runtime identifiers such as `python3.8`, `nodejs12.x` etc or `makefile`. +`BuildMethod` will either be the official lambda runtime identifiers such as `python3.8`, `nodejs20.x` etc or `makefile`. If `BuildMethod` is specified to be `makefile`, the build targets that are present in the `Makefile` which take the form of `build-{resource_logical_id}` will be executed. diff --git a/samcli/commands/_utils/options.py b/samcli/commands/_utils/options.py index e2a599979a..c81db4fefc 100644 --- a/samcli/commands/_utils/options.py +++ b/samcli/commands/_utils/options.py @@ -39,10 +39,9 @@ _TEMPLATE_OPTION_DEFAULT_VALUE = "template.[yaml|yml|json]" SUPPORTED_BUILD_IN_SOURCE_WORKFLOWS = [ - Runtime.nodejs12x.value, - Runtime.nodejs14x.value, Runtime.nodejs16x.value, Runtime.nodejs18x.value, + Runtime.nodejs20x.value, "Makefile", "esbuild", ] diff --git a/samcli/commands/local/cli_common/options.py b/samcli/commands/local/cli_common/options.py index 8550a8ba95..939eafd3a3 100644 --- a/samcli/commands/local/cli_common/options.py +++ b/samcli/commands/local/cli_common/options.py @@ -92,9 +92,9 @@ def local_common_options(f): multiple=True, help="Container image URIs for invoking functions or starting api and function. " "One can specify the image URI used for the local function invocation " - "(--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). " + "(--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). " "One can also specify for each individual function with " - "(--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). " + "(--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). " "If a function does not have invoke image specified, the default AWS SAM CLI " "emulation image will be used.", ), diff --git a/samcli/lib/build/workflow_config.py b/samcli/lib/build/workflow_config.py index f13d02a3e6..ab40140f20 100644 --- a/samcli/lib/build/workflow_config.py +++ b/samcli/lib/build/workflow_config.py @@ -94,8 +94,6 @@ def get_layer_subfolder(build_workflow: str) -> str: "nodejs4.3": "nodejs", "nodejs6.10": "nodejs", "nodejs8.10": "nodejs", - "nodejs12.x": "nodejs", - "nodejs14.x": "nodejs", "nodejs16.x": "nodejs", "nodejs18.x": "nodejs", "nodejs20.x": "nodejs", @@ -139,7 +137,7 @@ def get_workflow_config( specified_workflow str Workflow to be used, if directly specified. They are currently scoped to "makefile" and the official runtime - identifier names themselves, eg: nodejs14.x. If a workflow is not directly specified, + identifier names themselves, eg: nodejs20.x. If a workflow is not directly specified, it is calculated by the current method based on the runtime. Returns @@ -161,8 +159,6 @@ def get_workflow_config( "python3.10": BasicWorkflowSelector(PYTHON_PIP_CONFIG), "python3.11": BasicWorkflowSelector(PYTHON_PIP_CONFIG), "python3.12": BasicWorkflowSelector(PYTHON_PIP_CONFIG), - "nodejs12.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG), - "nodejs14.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG), "nodejs16.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG), "nodejs18.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG), "nodejs20.x": BasicWorkflowSelector(NODEJS_NPM_CONFIG), diff --git a/samcli/lib/init/local_manifest.json b/samcli/lib/init/local_manifest.json index 462d8d4a8f..de154ab38d 100644 --- a/samcli/lib/init/local_manifest.json +++ b/samcli/lib/init/local_manifest.json @@ -73,7 +73,7 @@ "useCaseName": "Hello World Example" } ], - "nodejs14.x": [ + "nodejs20.x": [ { "directory": "template/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", @@ -83,7 +83,17 @@ "useCaseName": "Hello World Example" } ], - "nodejs12.x": [ + "nodejs18.x": [ + { + "directory": "template/cookiecutter-aws-sam-hello-nodejs", + "displayName": "Hello World Example", + "dependencyManager": "npm", + "appTemplate": "hello-world", + "packageType": "Zip", + "useCaseName": "Hello World Example" + } + ], + "nodejs16.x": [ { "directory": "template/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", diff --git a/samcli/lib/init/templates/cookiecutter-aws-sam-hello-nodejs/cookiecutter.json b/samcli/lib/init/templates/cookiecutter-aws-sam-hello-nodejs/cookiecutter.json index 2ece06eb4b..9f290d416e 100644 --- a/samcli/lib/init/templates/cookiecutter-aws-sam-hello-nodejs/cookiecutter.json +++ b/samcli/lib/init/templates/cookiecutter-aws-sam-hello-nodejs/cookiecutter.json @@ -1,6 +1,6 @@ { "project_name": "Name of the project", - "runtime": "nodejs12.x", + "runtime": "nodejs20.x", "architectures": { "value": [ "x86_64" diff --git a/samcli/lib/utils/architecture.py b/samcli/lib/utils/architecture.py index 25cff8888a..1a3a03b689 100644 --- a/samcli/lib/utils/architecture.py +++ b/samcli/lib/utils/architecture.py @@ -15,8 +15,6 @@ ARM64 = "arm64" SUPPORTED_RUNTIMES: Dict[str, List[str]] = { - "nodejs12.x": [ARM64, X86_64], - "nodejs14.x": [ARM64, X86_64], "nodejs16.x": [ARM64, X86_64], "nodejs18.x": [ARM64, X86_64], "nodejs20.x": [ARM64, X86_64], diff --git a/samcli/local/common/runtime_template.py b/samcli/local/common/runtime_template.py index 94fe22d754..45924bb93a 100644 --- a/samcli/local/common/runtime_template.py +++ b/samcli/local/common/runtime_template.py @@ -32,7 +32,7 @@ ], "nodejs": [ { - "runtimes": ["nodejs20.x", "nodejs18.x", "nodejs16.x", "nodejs14.x", "nodejs12.x"], + "runtimes": ["nodejs20.x", "nodejs18.x", "nodejs16.x"], "dependency_manager": "npm", "init_location": os.path.join(_templates, "cookiecutter-aws-sam-hello-nodejs"), "build": True, @@ -111,8 +111,6 @@ def get_local_lambda_images_location(mapping, runtime): "nodejs20.x", "nodejs18.x", "nodejs16.x", - "nodejs14.x", - "nodejs12.x", # custom runtime in descending order "provided.al2023", "provided.al2", @@ -143,8 +141,6 @@ def get_local_lambda_images_location(mapping, runtime): "nodejs20.x": "amazon/nodejs20.x-base", "nodejs18.x": "amazon/nodejs18.x-base", "nodejs16.x": "amazon/nodejs16.x-base", - "nodejs14.x": "amazon/nodejs14.x-base", - "nodejs12.x": "amazon/nodejs12.x-base", "python3.12": "amazon/python3.12-base", "python3.11": "amazon/python3.11-base", "python3.10": "amazon/python3.10-base", diff --git a/samcli/local/docker/lambda_debug_settings.py b/samcli/local/docker/lambda_debug_settings.py index 05956e0eac..44ce87c2e1 100644 --- a/samcli/local/docker/lambda_debug_settings.py +++ b/samcli/local/docker/lambda_debug_settings.py @@ -117,34 +117,6 @@ def get_debug_settings(debug_port, debug_args_list, _container_env_vars, runtime **_container_env_vars, }, ), - Runtime.nodejs12x.value: lambda: DebugSettings( - entry - + ["/var/lang/bin/node"] - + debug_args_list - + ["--no-lazy", "--expose-gc"] - + ["/var/runtime/index.js"], - container_env_vars={ - "NODE_PATH": "/opt/nodejs/node_modules:/opt/nodejs/node12/node_modules:/var/runtime/node_modules:" - "/var/runtime:/var/task", - "NODE_OPTIONS": f"--inspect-brk=0.0.0.0:{str(debug_port)} --max-http-header-size 81920", - "AWS_EXECUTION_ENV": "AWS_Lambda_nodejs12.x", - **_container_env_vars, - }, - ), - Runtime.nodejs14x.value: lambda: DebugSettings( - entry - + ["/var/lang/bin/node"] - + debug_args_list - + ["--no-lazy", "--expose-gc"] - + ["/var/runtime/index.js"], - container_env_vars={ - "NODE_PATH": "/opt/nodejs/node_modules:/opt/nodejs/node14/node_modules:/var/runtime/node_modules:" - "/var/runtime:/var/task", - "NODE_OPTIONS": f"--inspect-brk=0.0.0.0:{str(debug_port)} --max-http-header-size 81920", - "AWS_EXECUTION_ENV": "AWS_Lambda_nodejs14.x", - **_container_env_vars, - }, - ), Runtime.nodejs16x.value: lambda: DebugSettings( entry + ["/var/lang/bin/node"] diff --git a/samcli/local/docker/lambda_image.py b/samcli/local/docker/lambda_image.py index b2546de7a3..6568ec4522 100644 --- a/samcli/local/docker/lambda_image.py +++ b/samcli/local/docker/lambda_image.py @@ -33,8 +33,6 @@ class Runtime(Enum): - nodejs12x = "nodejs12.x" - nodejs14x = "nodejs14.x" nodejs16x = "nodejs16.x" nodejs18x = "nodejs18.x" nodejs20x = "nodejs20.x" @@ -97,7 +95,7 @@ def get_image_name_tag(cls, runtime: str, architecture: str) -> str: else: # This fits most runtimes format: `nameN.M` becomes `name:N.M` (python3.9 -> python:3.9) runtime_image_tag = re.sub(r"^([a-z]+)([0-9][a-z0-9\.]*)$", r"\1:\2", runtime) - # nodejs14.x, go1.x, etc don't have the `.x` part. + # nodejs20.x, go1.x, etc don't have the `.x` part. runtime_image_tag = runtime_image_tag.replace(".x", "") # Runtime image tags contain the architecture only if more than one is supported for that runtime diff --git a/schema/samcli.json b/schema/samcli.json index 3dca17f259..acef452725 100644 --- a/schema/samcli.json +++ b/schema/samcli.json @@ -23,7 +23,7 @@ "properties": { "parameters": { "title": "Parameters for the init command", - "description": "Available parameters for the init command:\n* no_interactive:\nDisable interactive prompting for init parameters. (fail if any required values are missing)\n* architecture:\nArchitectures for Lambda functions.\n\nArchitectures: ['arm64', 'x86_64']\n* location:\nTemplate location (git, mercurial, http(s), zip, path).\n* runtime:\nLambda runtime for application.\n\nRuntimes: dotnet6, go1.x, java21, java17, java11, java8.al2, java8, nodejs20.x, nodejs18.x, nodejs16.x, nodejs14.x, nodejs12.x, provided, provided.al2, provided.al2023, python3.9, python3.8, python3.7, python3.12, python3.11, python3.10, ruby3.2, ruby2.7\n* package_type:\nLambda deployment package type.\n\nPackage Types: Zip, Image\n* base_image:\nLambda base image for deploying IMAGE based package type.\n\nBase images: amazon/dotnet6-base, amazon/go-provided.al2-base, amazon/go-provided.al2023-base, amazon/go1.x-base, amazon/java11-base, amazon/java17-base, amazon/java21-base, amazon/java8-base, amazon/java8.al2-base, amazon/nodejs12.x-base, amazon/nodejs14.x-base, amazon/nodejs16.x-base, amazon/nodejs18.x-base, amazon/nodejs20.x-base, amazon/python3.10-base, amazon/python3.11-base, amazon/python3.12-base, amazon/python3.7-base, amazon/python3.8-base, amazon/python3.9-base, amazon/ruby2.7-base, amazon/ruby3.2-base\n* dependency_manager:\nDependency manager for Lambda runtime.\n\nDependency managers: bundler, cli-package, gradle, maven, mod, npm, pip\n* output_dir:\nDirectory to initialize AWS SAM application.\n* name:\nName of AWS SAM Application.\n* app_template:\nIdentifier of the managed application template to be used. Alternatively, run '$sam init' without options for an interactive workflow.\n* no_input:\nDisable Cookiecutter prompting and accept default values defined in the cookiecutter config.\n* extra_context:\nOverride custom parameters in the template's cookiecutter.json configuration e.g. {\"customParam1\": \"customValue1\", \"customParam2\":\"customValue2\"}\n* tracing:\nEnable AWS X-Ray tracing for application.\n* application_insights:\nEnable CloudWatch Application Insights monitoring for application.\n* structured_logging:\nEnable Structured Logging for application.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the init command:\n* no_interactive:\nDisable interactive prompting for init parameters. (fail if any required values are missing)\n* architecture:\nArchitectures for Lambda functions.\n\nArchitectures: ['arm64', 'x86_64']\n* location:\nTemplate location (git, mercurial, http(s), zip, path).\n* runtime:\nLambda runtime for application.\n\nRuntimes: dotnet6, go1.x, java21, java17, java11, java8.al2, java8, nodejs20.x, nodejs18.x, nodejs16.x, provided, provided.al2, provided.al2023, python3.9, python3.8, python3.7, python3.12, python3.11, python3.10, ruby3.2, ruby2.7\n* package_type:\nLambda deployment package type.\n\nPackage Types: Zip, Image\n* base_image:\nLambda base image for deploying IMAGE based package type.\n\nBase images: amazon/dotnet6-base, amazon/go-provided.al2-base, amazon/go-provided.al2023-base, amazon/go1.x-base, amazon/java11-base, amazon/java17-base, amazon/java21-base, amazon/java8-base, amazon/java8.al2-base, amazon/nodejs16.x-base, amazon/nodejs18.x-base, amazon/nodejs20.x-base, amazon/python3.10-base, amazon/python3.11-base, amazon/python3.12-base, amazon/python3.7-base, amazon/python3.8-base, amazon/python3.9-base, amazon/ruby2.7-base, amazon/ruby3.2-base\n* dependency_manager:\nDependency manager for Lambda runtime.\n\nDependency managers: bundler, cli-package, gradle, maven, mod, npm, pip\n* output_dir:\nDirectory to initialize AWS SAM application.\n* name:\nName of AWS SAM Application.\n* app_template:\nIdentifier of the managed application template to be used. Alternatively, run '$sam init' without options for an interactive workflow.\n* no_input:\nDisable Cookiecutter prompting and accept default values defined in the cookiecutter config.\n* extra_context:\nOverride custom parameters in the template's cookiecutter.json configuration e.g. {\"customParam1\": \"customValue1\", \"customParam2\":\"customValue2\"}\n* tracing:\nEnable AWS X-Ray tracing for application.\n* application_insights:\nEnable CloudWatch Application Insights monitoring for application.\n* structured_logging:\nEnable Structured Logging for application.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "no_interactive": { @@ -48,7 +48,7 @@ "runtime": { "title": "runtime", "type": "string", - "description": "Lambda runtime for application.\n\nRuntimes: dotnet6, go1.x, java21, java17, java11, java8.al2, java8, nodejs20.x, nodejs18.x, nodejs16.x, nodejs14.x, nodejs12.x, provided, provided.al2, provided.al2023, python3.9, python3.8, python3.7, python3.12, python3.11, python3.10, ruby3.2, ruby2.7", + "description": "Lambda runtime for application.\n\nRuntimes: dotnet6, go1.x, java21, java17, java11, java8.al2, java8, nodejs20.x, nodejs18.x, nodejs16.x, provided, provided.al2, provided.al2023, python3.9, python3.8, python3.7, python3.12, python3.11, python3.10, ruby3.2, ruby2.7", "enum": [ "dotnet6", "go1.x", @@ -57,8 +57,6 @@ "java21", "java8", "java8.al2", - "nodejs12.x", - "nodejs14.x", "nodejs16.x", "nodejs18.x", "nodejs20.x", @@ -87,7 +85,7 @@ "base_image": { "title": "base_image", "type": "string", - "description": "Lambda base image for deploying IMAGE based package type.\n\nBase images: amazon/dotnet6-base, amazon/go-provided.al2-base, amazon/go-provided.al2023-base, amazon/go1.x-base, amazon/java11-base, amazon/java17-base, amazon/java21-base, amazon/java8-base, amazon/java8.al2-base, amazon/nodejs12.x-base, amazon/nodejs14.x-base, amazon/nodejs16.x-base, amazon/nodejs18.x-base, amazon/nodejs20.x-base, amazon/python3.10-base, amazon/python3.11-base, amazon/python3.12-base, amazon/python3.7-base, amazon/python3.8-base, amazon/python3.9-base, amazon/ruby2.7-base, amazon/ruby3.2-base", + "description": "Lambda base image for deploying IMAGE based package type.\n\nBase images: amazon/dotnet6-base, amazon/go-provided.al2-base, amazon/go-provided.al2023-base, amazon/go1.x-base, amazon/java11-base, amazon/java17-base, amazon/java21-base, amazon/java8-base, amazon/java8.al2-base, amazon/nodejs16.x-base, amazon/nodejs18.x-base, amazon/nodejs20.x-base, amazon/python3.10-base, amazon/python3.11-base, amazon/python3.12-base, amazon/python3.7-base, amazon/python3.8-base, amazon/python3.9-base, amazon/ruby2.7-base, amazon/ruby3.2-base", "enum": [ "amazon/dotnet6-base", "amazon/go-provided.al2-base", @@ -98,8 +96,6 @@ "amazon/java21-base", "amazon/java8-base", "amazon/java8.al2-base", - "amazon/nodejs12.x-base", - "amazon/nodejs14.x-base", "amazon/nodejs16.x-base", "amazon/nodejs18.x-base", "amazon/nodejs20.x-base", @@ -248,7 +244,7 @@ "properties": { "parameters": { "title": "Parameters for the build command", - "description": "Available parameters for the build command:\n* terraform_project_root_path:\nUsed for passing the Terraform project root directory path. Current directory will be used as a default value, if this parameter is not provided.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* use_container:\nBuild functions within an AWS Lambda-like container.\n* build_in_source:\nOpts in to build project in the source folder. The following workflows support building in source: ['nodejs12.x', 'nodejs14.x', 'nodejs16.x', 'nodejs18.x', 'Makefile', 'esbuild']\n* container_env_var:\nEnvironment variables to be passed into build containers\nResource format (FuncName.VarName=Value) or Global format (VarName=Value).\n\n Example: --container-env-var Func1.VAR1=value1 --container-env-var VAR2=value2\n* container_env_var_file:\nEnvironment variables json file (e.g., env_vars.json) to be passed to build containers.\n* build_image:\nContainer image URIs for building functions/layers. You can specify for all functions/layers with just the image URI (--build-image public.ecr.aws/sam/build-nodejs18.x:latest). You can specify for each individual function with (--build-image FunctionLogicalID=public.ecr.aws/sam/build-nodejs18.x:latest). A combination of the two can be used. If a function does not have build image specified or an image URI for all functions, the default SAM CLI build images will be used.\n* exclude:\nName of the resource(s) to exclude from AWS SAM CLI build.\n* parallel:\nEnable parallel builds for AWS SAM template's functions and layers.\n* mount_with:\nSpecify mount mode for building functions/layers inside container. If it is mounted with write permissions, some files in source code directory may be changed/added by the build process. By default the source code directory is read only.\n* build_dir:\nDirectory to store build artifacts.Note: This directory will be first removed before starting a build.\n* cache_dir:\nDirectory to store cached artifacts. The default cache directory is .aws-sam/cache\n* base_dir:\nResolve relative paths to function's source code with respect to this directory. Use this if SAM template and source code are not in same enclosing folder. By default, relative paths are resolved with respect to the SAM template's location.\n* manifest:\nPath to a custom dependency manifest. Example: custom-package.json\n* cached:\nEnable cached builds.Reuse build artifacts that have not changed from previous builds. \n\nAWS SAM CLI evaluates if files in your project directory have changed. \n\nNote: AWS SAM CLI does not evaluate changes made to third party modules that the project depends on.Example: Python function includes a requirements.txt file with the following entry requests=1.x and the latest request module version changes from 1.1 to 1.2, AWS SAM CLI will not pull the latest version until a non-cached build is run.\n* template_file:\nAWS SAM template file.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the build command:\n* terraform_project_root_path:\nUsed for passing the Terraform project root directory path. Current directory will be used as a default value, if this parameter is not provided.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* use_container:\nBuild functions within an AWS Lambda-like container.\n* build_in_source:\nOpts in to build project in the source folder. The following workflows support building in source: ['nodejs16.x', 'nodejs18.x', 'nodejs20.x', 'Makefile', 'esbuild']\n* container_env_var:\nEnvironment variables to be passed into build containers\nResource format (FuncName.VarName=Value) or Global format (VarName=Value).\n\n Example: --container-env-var Func1.VAR1=value1 --container-env-var VAR2=value2\n* container_env_var_file:\nEnvironment variables json file (e.g., env_vars.json) to be passed to build containers.\n* build_image:\nContainer image URIs for building functions/layers. You can specify for all functions/layers with just the image URI (--build-image public.ecr.aws/sam/build-nodejs18.x:latest). You can specify for each individual function with (--build-image FunctionLogicalID=public.ecr.aws/sam/build-nodejs18.x:latest). A combination of the two can be used. If a function does not have build image specified or an image URI for all functions, the default SAM CLI build images will be used.\n* exclude:\nName of the resource(s) to exclude from AWS SAM CLI build.\n* parallel:\nEnable parallel builds for AWS SAM template's functions and layers.\n* mount_with:\nSpecify mount mode for building functions/layers inside container. If it is mounted with write permissions, some files in source code directory may be changed/added by the build process. By default the source code directory is read only.\n* build_dir:\nDirectory to store build artifacts.Note: This directory will be first removed before starting a build.\n* cache_dir:\nDirectory to store cached artifacts. The default cache directory is .aws-sam/cache\n* base_dir:\nResolve relative paths to function's source code with respect to this directory. Use this if SAM template and source code are not in same enclosing folder. By default, relative paths are resolved with respect to the SAM template's location.\n* manifest:\nPath to a custom dependency manifest. Example: custom-package.json\n* cached:\nEnable cached builds.Reuse build artifacts that have not changed from previous builds. \n\nAWS SAM CLI evaluates if files in your project directory have changed. \n\nNote: AWS SAM CLI does not evaluate changes made to third party modules that the project depends on.Example: Python function includes a requirements.txt file with the following entry requests=1.x and the latest request module version changes from 1.1 to 1.2, AWS SAM CLI will not pull the latest version until a non-cached build is run.\n* template_file:\nAWS SAM template file.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "terraform_project_root_path": { @@ -274,7 +270,7 @@ "build_in_source": { "title": "build_in_source", "type": "boolean", - "description": "Opts in to build project in the source folder. The following workflows support building in source: ['nodejs12.x', 'nodejs14.x', 'nodejs16.x', 'nodejs18.x', 'Makefile', 'esbuild']" + "description": "Opts in to build project in the source folder. The following workflows support building in source: ['nodejs16.x', 'nodejs18.x', 'nodejs20.x', 'Makefile', 'esbuild']" }, "container_env_var": { "title": "container_env_var", @@ -403,7 +399,7 @@ "properties": { "parameters": { "title": "Parameters for the local invoke command", - "description": "Available parameters for the local invoke command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* event:\nJSON file containing event data passed to the Lambda function during invoke. If this option is not specified, no event is assumed. Pass in the value '-' to input JSON via stdin\n* no_event:\nDEPRECATED: By default no event is assumed.\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the local invoke command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* event:\nJSON file containing event data passed to the Lambda function during invoke. If this option is not specified, no event is assumed. Pass in the value '-' to input JSON via stdin\n* no_event:\nDEPRECATED: By default no event is assumed.\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "terraform_plan_file": { @@ -532,7 +528,7 @@ "invoke_image": { "title": "invoke_image", "type": "string", - "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." + "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." }, "beta_features": { "title": "beta_features", @@ -572,7 +568,7 @@ "properties": { "parameters": { "title": "Parameters for the local start api command", - "description": "Available parameters for the local start api command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* host:\nLocal hostname or IP address to bind to (default: '127.0.0.1')\n* port:\nLocal port number to listen on (default: '3000')\n* static_dir:\nAny static assets (e.g. CSS/Javascript/HTML) files located in this directory will be presented at /\n* disable_authorizer:\nDisable custom Lambda Authorizers from being parsed and invoked.\n* ssl_cert_file:\nPath to SSL certificate file (default: None)\n* ssl_key_file:\nPath to SSL key file (default: None)\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* warm_containers:\nOptional. Specifies how AWS SAM CLI manages \ncontainers for each function.\nTwo modes are available:\nEAGER: Containers for all functions are \nloaded at startup and persist between \ninvocations.\nLAZY: Containers are only loaded when each \nfunction is first invoked. Those containers \npersist for additional invocations.\n* debug_function:\nOptional. Specifies the Lambda Function logicalId to apply debug options to when --warm-containers is specified. This parameter applies to --debug-port, --debugger-path, and --debug-args.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the local start api command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* host:\nLocal hostname or IP address to bind to (default: '127.0.0.1')\n* port:\nLocal port number to listen on (default: '3000')\n* static_dir:\nAny static assets (e.g. CSS/Javascript/HTML) files located in this directory will be presented at /\n* disable_authorizer:\nDisable custom Lambda Authorizers from being parsed and invoked.\n* ssl_cert_file:\nPath to SSL certificate file (default: None)\n* ssl_key_file:\nPath to SSL key file (default: None)\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* warm_containers:\nOptional. Specifies how AWS SAM CLI manages \ncontainers for each function.\nTwo modes are available:\nEAGER: Containers for all functions are \nloaded at startup and persist between \ninvocations.\nLAZY: Containers are only loaded when each \nfunction is first invoked. Those containers \npersist for additional invocations.\n* debug_function:\nOptional. Specifies the Lambda Function logicalId to apply debug options to when --warm-containers is specified. This parameter applies to --debug-port, --debugger-path, and --debug-args.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "terraform_plan_file": { @@ -737,7 +733,7 @@ "invoke_image": { "title": "invoke_image", "type": "string", - "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." + "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." }, "beta_features": { "title": "beta_features", @@ -792,7 +788,7 @@ "properties": { "parameters": { "title": "Parameters for the local start lambda command", - "description": "Available parameters for the local start lambda command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* host:\nLocal hostname or IP address to bind to (default: '127.0.0.1')\n* port:\nLocal port number to listen on (default: '3001')\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* warm_containers:\nOptional. Specifies how AWS SAM CLI manages \ncontainers for each function.\nTwo modes are available:\nEAGER: Containers for all functions are \nloaded at startup and persist between \ninvocations.\nLAZY: Containers are only loaded when each \nfunction is first invoked. Those containers \npersist for additional invocations.\n* debug_function:\nOptional. Specifies the Lambda Function logicalId to apply debug options to when --warm-containers is specified. This parameter applies to --debug-port, --debugger-path, and --debug-args.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the local start lambda command:\n* terraform_plan_file:\nUsed for passing a custom plan file when executing the Terraform hook.\n* hook_name:\nHook package id to extend AWS SAM CLI commands functionality. \n\nExample: `terraform` to extend AWS SAM CLI commands functionality to support terraform applications. \n\nAvailable Hook Names: ['terraform']\n* skip_prepare_infra:\nSkip preparation stage when there are no infrastructure changes. Only used in conjunction with --hook-name.\n* host:\nLocal hostname or IP address to bind to (default: '127.0.0.1')\n* port:\nLocal port number to listen on (default: '3001')\n* template_file:\nAWS SAM template which references built artifacts for resources in the template. (if applicable)\n* env_vars:\nJSON file containing values for Lambda function's environment variables.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* debug_port:\nWhen specified, Lambda function container will start in debug mode and will expose this port on localhost.\n* debugger_path:\nHost path to a debugger that will be mounted into the Lambda container.\n* debug_args:\nAdditional arguments to be passed to the debugger.\n* container_env_vars:\nJSON file containing additional environment variables to be set within the container when used in a debugging session locally.\n* docker_volume_basedir:\nSpecify the location basedir where the SAM template exists. If Docker is running on a remote machine, Path of the SAM template must be mounted on the Docker machine and modified to match the remote machine.\n* log_file:\nFile to capture output logs.\n* layer_cache_basedir:\nSpecify the location basedir where the lambda layers used by the template will be downloaded to.\n* skip_pull_image:\nSkip pulling down the latest Docker image for Lambda runtime.\n* docker_network:\nName or ID of an existing docker network for AWS Lambda docker containers to connect to, along with the default bridge network. If not specified, the Lambda containers will only connect to the default bridge docker network.\n* force_image_build:\nForce rebuilding the image used for invoking functions with layers.\n* warm_containers:\nOptional. Specifies how AWS SAM CLI manages \ncontainers for each function.\nTwo modes are available:\nEAGER: Containers for all functions are \nloaded at startup and persist between \ninvocations.\nLAZY: Containers are only loaded when each \nfunction is first invoked. Those containers \npersist for additional invocations.\n* debug_function:\nOptional. Specifies the Lambda Function logicalId to apply debug options to when --warm-containers is specified. This parameter applies to --debug-port, --debugger-path, and --debug-args.\n* shutdown:\nEmulate a shutdown event after invoke completes, to test extension handling of shutdown behavior.\n* container_host:\nHost of locally emulated Lambda container. This option is useful when the container runs on a different host than AWS SAM CLI. For example, if one wants to run AWS SAM CLI in a Docker container on macOS, this option could specify `host.docker.internal`\n* container_host_interface:\nIP address of the host network interface that container ports should bind to. Use 0.0.0.0 to bind to all interfaces.\n* add_host:\nPasses a hostname to IP address mapping to the Docker container's host file. This parameter can be passed multiple times.Example:--add-host example.com:127.0.0.1\n* invoke_image:\nContainer image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "terraform_plan_file": { @@ -936,7 +932,7 @@ "invoke_image": { "title": "invoke_image", "type": "string", - "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs14.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs14.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." + "description": "Container image URIs for invoking functions or starting api and function. One can specify the image URI used for the local function invocation (--invoke-image public.ecr.aws/sam/build-nodejs20.x:latest). One can also specify for each individual function with (--invoke-image Function1=public.ecr.aws/sam/build-nodejs20.x:latest). If a function does not have invoke image specified, the default AWS SAM CLI emulation image will be used." }, "beta_features": { "title": "beta_features", @@ -1564,7 +1560,7 @@ "properties": { "parameters": { "title": "Parameters for the sync command", - "description": "Available parameters for the sync command:\n* template_file:\nAWS SAM template file.\n* code:\nSync ONLY code resources. This includes Lambda Functions, API Gateway, and Step Functions.\n* watch:\nWatch local files and automatically sync with cloud.\n* resource_id:\nSync code for all the resources with the ID. To sync a resource within a nested stack, use the following pattern {ChildStack}/{logicalId}.\n* resource:\nSync code for all resources of the given resource type. Accepted values are ['AWS::Serverless::Function', 'AWS::Lambda::Function', 'AWS::Serverless::LayerVersion', 'AWS::Lambda::LayerVersion', 'AWS::Serverless::Api', 'AWS::ApiGateway::RestApi', 'AWS::Serverless::HttpApi', 'AWS::ApiGatewayV2::Api', 'AWS::Serverless::StateMachine', 'AWS::StepFunctions::StateMachine']\n* dependency_layer:\nSeparate dependencies of individual function into a Lambda layer for improved performance.\n* skip_deploy_sync:\nThis option will skip the initial infrastructure deployment if it is not required by comparing the local template with the template deployed in cloud.\n* watch_exclude:\nExcludes a file or folder from being observed for file changes. Files and folders that are excluded will not trigger a sync workflow. This option can be provided multiple times.\n\nExamples:\n\nHelloWorldFunction=package-lock.json\n\nChildStackA/FunctionName=database.sqlite3\n* stack_name:\nName of the AWS CloudFormation stack.\n* base_dir:\nResolve relative paths to function's source code with respect to this directory. Use this if SAM template and source code are not in same enclosing folder. By default, relative paths are resolved with respect to the SAM template's location.\n* use_container:\nBuild functions within an AWS Lambda-like container.\n* build_in_source:\nOpts in to build project in the source folder. The following workflows support building in source: ['nodejs12.x', 'nodejs14.x', 'nodejs16.x', 'nodejs18.x', 'Makefile', 'esbuild']\n* build_image:\nContainer image URIs for building functions/layers. You can specify for all functions/layers with just the image URI (--build-image public.ecr.aws/sam/build-nodejs18.x:latest). You can specify for each individual function with (--build-image FunctionLogicalID=public.ecr.aws/sam/build-nodejs18.x:latest). A combination of the two can be used. If a function does not have build image specified or an image URI for all functions, the default SAM CLI build images will be used.\n* image_repository:\nAWS ECR repository URI where artifacts referenced in the template are uploaded.\n* image_repositories:\nMapping of Function Logical ID to AWS ECR Repository URI.\n\nExample: Function_Logical_ID=ECR_Repo_Uri\nThis option can be specified multiple times.\n* s3_bucket:\nAWS S3 bucket where artifacts referenced in the template are uploaded.\n* s3_prefix:\nPrefix name that is added to the artifact's name when it is uploaded to the AWS S3 bucket.\n* kms_key_id:\nThe ID of an AWS KMS key that is used to encrypt artifacts that are at rest in the AWS S3 bucket.\n* role_arn:\nARN of an IAM role that AWS Cloudformation assumes when executing a deployment change set.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* metadata:\nMap of metadata to attach to ALL the artifacts that are referenced in the template.\n* notification_arns:\nARNs of SNS topics that AWS Cloudformation associates with the stack.\n* tags:\nList of tags to associate with the stack.\n* capabilities:\nList of capabilities that one must specify before AWS Cloudformation can create certain stacks.\n\nAccepted Values: CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_RESOURCE_POLICY, CAPABILITY_AUTO_EXPAND.\n\nLearn more at: https://docs.aws.amazon.com/serverlessrepo/latest/devguide/acknowledging-application-capabilities.html\n* save_params:\nSave the parameters provided via the command line to the configuration file.", + "description": "Available parameters for the sync command:\n* template_file:\nAWS SAM template file.\n* code:\nSync ONLY code resources. This includes Lambda Functions, API Gateway, and Step Functions.\n* watch:\nWatch local files and automatically sync with cloud.\n* resource_id:\nSync code for all the resources with the ID. To sync a resource within a nested stack, use the following pattern {ChildStack}/{logicalId}.\n* resource:\nSync code for all resources of the given resource type. Accepted values are ['AWS::Serverless::Function', 'AWS::Lambda::Function', 'AWS::Serverless::LayerVersion', 'AWS::Lambda::LayerVersion', 'AWS::Serverless::Api', 'AWS::ApiGateway::RestApi', 'AWS::Serverless::HttpApi', 'AWS::ApiGatewayV2::Api', 'AWS::Serverless::StateMachine', 'AWS::StepFunctions::StateMachine']\n* dependency_layer:\nSeparate dependencies of individual function into a Lambda layer for improved performance.\n* skip_deploy_sync:\nThis option will skip the initial infrastructure deployment if it is not required by comparing the local template with the template deployed in cloud.\n* watch_exclude:\nExcludes a file or folder from being observed for file changes. Files and folders that are excluded will not trigger a sync workflow. This option can be provided multiple times.\n\nExamples:\n\nHelloWorldFunction=package-lock.json\n\nChildStackA/FunctionName=database.sqlite3\n* stack_name:\nName of the AWS CloudFormation stack.\n* base_dir:\nResolve relative paths to function's source code with respect to this directory. Use this if SAM template and source code are not in same enclosing folder. By default, relative paths are resolved with respect to the SAM template's location.\n* use_container:\nBuild functions within an AWS Lambda-like container.\n* build_in_source:\nOpts in to build project in the source folder. The following workflows support building in source: ['nodejs16.x', 'nodejs18.x', 'nodejs20.x', 'Makefile', 'esbuild']\n* build_image:\nContainer image URIs for building functions/layers. You can specify for all functions/layers with just the image URI (--build-image public.ecr.aws/sam/build-nodejs18.x:latest). You can specify for each individual function with (--build-image FunctionLogicalID=public.ecr.aws/sam/build-nodejs18.x:latest). A combination of the two can be used. If a function does not have build image specified or an image URI for all functions, the default SAM CLI build images will be used.\n* image_repository:\nAWS ECR repository URI where artifacts referenced in the template are uploaded.\n* image_repositories:\nMapping of Function Logical ID to AWS ECR Repository URI.\n\nExample: Function_Logical_ID=ECR_Repo_Uri\nThis option can be specified multiple times.\n* s3_bucket:\nAWS S3 bucket where artifacts referenced in the template are uploaded.\n* s3_prefix:\nPrefix name that is added to the artifact's name when it is uploaded to the AWS S3 bucket.\n* kms_key_id:\nThe ID of an AWS KMS key that is used to encrypt artifacts that are at rest in the AWS S3 bucket.\n* role_arn:\nARN of an IAM role that AWS Cloudformation assumes when executing a deployment change set.\n* parameter_overrides:\nString that contains AWS CloudFormation parameter overrides encoded as key=value pairs.\n* beta_features:\nEnable/Disable beta features.\n* debug:\nTurn on debug logging to print debug message generated by AWS SAM CLI and display timestamps.\n* profile:\nSelect a specific profile from your credential file to get AWS credentials.\n* region:\nSet the AWS Region of the service. (e.g. us-east-1)\n* metadata:\nMap of metadata to attach to ALL the artifacts that are referenced in the template.\n* notification_arns:\nARNs of SNS topics that AWS Cloudformation associates with the stack.\n* tags:\nList of tags to associate with the stack.\n* capabilities:\nList of capabilities that one must specify before AWS Cloudformation can create certain stacks.\n\nAccepted Values: CAPABILITY_IAM, CAPABILITY_NAMED_IAM, CAPABILITY_RESOURCE_POLICY, CAPABILITY_AUTO_EXPAND.\n\nLearn more at: https://docs.aws.amazon.com/serverlessrepo/latest/devguide/acknowledging-application-capabilities.html\n* save_params:\nSave the parameters provided via the command line to the configuration file.", "type": "object", "properties": { "template_file": { @@ -1643,7 +1639,7 @@ "build_in_source": { "title": "build_in_source", "type": "boolean", - "description": "Opts in to build project in the source folder. The following workflows support building in source: ['nodejs12.x', 'nodejs14.x', 'nodejs16.x', 'nodejs18.x', 'Makefile', 'esbuild']" + "description": "Opts in to build project in the source folder. The following workflows support building in source: ['nodejs16.x', 'nodejs18.x', 'nodejs20.x', 'Makefile', 'esbuild']" }, "build_image": { "title": "build_image", diff --git a/tests/functional/commands/validate/lib/models/function_with_image_in_metadata.yaml b/tests/functional/commands/validate/lib/models/function_with_image_in_metadata.yaml index 81bc940308..b385eb0639 100644 --- a/tests/functional/commands/validate/lib/models/function_with_image_in_metadata.yaml +++ b/tests/functional/commands/validate/lib/models/function_with_image_in_metadata.yaml @@ -6,6 +6,6 @@ Resources: Properties: PackageType: Image Metadata: - DockerTag: nodejs14.x-v1 + DockerTag: nodejs20.x-v1 DockerContext: ./hello-world Dockerfile: Dockerfile diff --git a/tests/integration/buildcmd/test_build_cmd.py b/tests/integration/buildcmd/test_build_cmd.py index 6edfe8abd6..9f7b7319f9 100644 --- a/tests/integration/buildcmd/test_build_cmd.py +++ b/tests/integration/buildcmd/test_build_cmd.py @@ -659,13 +659,9 @@ def test_unsupported_runtime(self): class TestBuildCommand_NodeFunctions(BuildIntegNodeBase): @parameterized.expand( [ - ("nodejs12.x", False), - ("nodejs14.x", False), ("nodejs16.x", False), ("nodejs18.x", False), ("nodejs20.x", False), - ("nodejs12.x", "use_container"), - ("nodejs14.x", "use_container"), ("nodejs16.x", "use_container"), ("nodejs18.x", "use_container"), ("nodejs20.x", "use_container"), @@ -687,7 +683,6 @@ class TestBuildCommand_NodeFunctions_With_External_Manifest(BuildIntegNodeBase): @parameterized.expand( [ - ("nodejs14.x",), ("nodejs16.x",), ("nodejs18.x",), ("nodejs20.x",), @@ -702,11 +697,12 @@ class TestBuildCommand_EsbuildFunctions(BuildIntegEsbuildBase): @parameterized.expand( [ - ("nodejs14.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", False, "x86_64"), - ("nodejs14.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", False, "x86_64"), - ("nodejs14.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", "use_container", "x86_64"), + ("nodejs20.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", False, "x86_64"), + ("nodejs20.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", False, "x86_64"), + # Keeping container tests as Node.js18 until our CI platform can run Node.js20 container tests + ("nodejs18.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", "use_container", "x86_64"), ( - "nodejs14.x", + "nodejs18.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", @@ -728,7 +724,7 @@ class TestBuildCommand_EsbuildFunctions_With_External_Manifest(BuildIntegEsbuild @parameterized.expand( [ ( - "nodejs14.x", + "nodejs20.x", "Esbuild/Node_without_manifest", {"main.js", "main.js.map"}, "main.lambdaHandler", @@ -736,7 +732,7 @@ class TestBuildCommand_EsbuildFunctions_With_External_Manifest(BuildIntegEsbuild "x86_64", ), ( - "nodejs14.x", + "nodejs20.x", "Esbuild/TypeScript_without_manifest", {"app.js", "app.js.map"}, "app.lambdaHandler", @@ -788,13 +784,9 @@ class TestBuildCommand_NodeFunctions_With_Specified_Architecture(BuildIntegNodeB @parameterized.expand( [ - ("nodejs12.x", False, "x86_64"), - ("nodejs14.x", False, "x86_64"), ("nodejs16.x", False, "x86_64"), ("nodejs18.x", False, "x86_64"), ("nodejs20.x", False, "x86_64"), - ("nodejs12.x", "use_container", "x86_64"), - ("nodejs14.x", "use_container", "x86_64"), ("nodejs16.x", "use_container", "x86_64"), ("nodejs18.x", "use_container", "x86_64"), ] @@ -2136,12 +2128,12 @@ class TestBuildWithDedupBuilds(DedupBuildIntegBase): "dotnet6", ), (False, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (False, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (False, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), # container (True, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (True, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (True, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), ] @@ -2255,12 +2247,12 @@ class TestBuildWithCacheBuilds(CachedBuildIntegBase): "dotnet6", ), (False, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (False, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (False, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), # container (True, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (True, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (True, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), ] @@ -2434,12 +2426,12 @@ class TestParallelBuilds(DedupBuildIntegBase): "dotnet6", ), (False, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (False, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (False, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (False, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), # container (True, "Java/gradlew/8", "aws.example.Hello::myHandler", "aws.example.SecondFunction::myHandler", "java8"), - (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs14.x"), + (True, "Node", "main.lambdaHandler", "main.secondLambdaHandler", "nodejs20.x"), (True, "Python", "main.first_function_handler", "main.second_function_handler", "python3.9"), (True, "Ruby", "app.lambda_handler", "app.second_lambda_handler", "ruby2.7"), ] diff --git a/tests/integration/buildcmd/test_build_cmd_arm64.py b/tests/integration/buildcmd/test_build_cmd_arm64.py index 6bdccd6846..c2064c2798 100644 --- a/tests/integration/buildcmd/test_build_cmd_arm64.py +++ b/tests/integration/buildcmd/test_build_cmd_arm64.py @@ -60,11 +60,11 @@ class TestBuildCommand_EsbuildFunctions_arm64(BuildIntegEsbuildBase): @parameterized.expand( [ - ("nodejs12.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", False), - ("nodejs12.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", False), - ("nodejs12.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", "use_container"), + ("nodejs20.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", False), + ("nodejs20.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", False), + ("nodejs20.x", "Esbuild/Node", {"main.js", "main.js.map"}, "main.lambdaHandler", "use_container"), ( - "nodejs12.x", + "nodejs20.x", "Esbuild/TypeScript", {"app.js", "app.js.map"}, "app.lambdaHandler", @@ -137,13 +137,9 @@ class TestBuildCommand_NodeFunctions_With_Specified_Architecture_arm64(BuildInte @parameterized.expand( [ - ("nodejs12.x", False), - ("nodejs14.x", False), ("nodejs16.x", False), ("nodejs18.x", False), ("nodejs20.x", False), - ("nodejs12.x", "use_container"), - ("nodejs14.x", "use_container"), ("nodejs16.x", "use_container"), ("nodejs18.x", "use_container"), ("nodejs20.x", "use_container"), diff --git a/tests/integration/testdata/validate/default_json/template.json b/tests/integration/testdata/validate/default_json/template.json index f9da3fc2d3..4945b4ef41 100644 --- a/tests/integration/testdata/validate/default_json/template.json +++ b/tests/integration/testdata/validate/default_json/template.json @@ -8,7 +8,7 @@ "Properties": { "CodeUri": "hello-world/", "Handler": "app.lambdaHandler", - "Runtime": "nodejs14.x" + "Runtime": "nodejs20.x" } } } diff --git a/tests/integration/testdata/validate/multiple_files/template.json b/tests/integration/testdata/validate/multiple_files/template.json index f9da3fc2d3..4945b4ef41 100644 --- a/tests/integration/testdata/validate/multiple_files/template.json +++ b/tests/integration/testdata/validate/multiple_files/template.json @@ -8,7 +8,7 @@ "Properties": { "CodeUri": "hello-world/", "Handler": "app.lambdaHandler", - "Runtime": "nodejs14.x" + "Runtime": "nodejs20.x" } } } diff --git a/tests/integration/testdata/validate/with_build/.aws-sam/build/template.yaml b/tests/integration/testdata/validate/with_build/.aws-sam/build/template.yaml index acb6a8cf26..ccab4ba47c 100644 --- a/tests/integration/testdata/validate/with_build/.aws-sam/build/template.yaml +++ b/tests/integration/testdata/validate/with_build/.aws-sam/build/template.yaml @@ -7,4 +7,4 @@ Resources: Properties: CodeUri: HelloWorldFunction Handler: app.lambdaHandler - Runtime: nodejs14.x + Runtime: nodejs20.x diff --git a/tests/integration/testdata/validate/with_build/template.json b/tests/integration/testdata/validate/with_build/template.json index f9da3fc2d3..4945b4ef41 100644 --- a/tests/integration/testdata/validate/with_build/template.json +++ b/tests/integration/testdata/validate/with_build/template.json @@ -8,7 +8,7 @@ "Properties": { "CodeUri": "hello-world/", "Handler": "app.lambdaHandler", - "Runtime": "nodejs14.x" + "Runtime": "nodejs20.x" } } } diff --git a/tests/integration/validate/test_validate_command.py b/tests/integration/validate/test_validate_command.py index 53a36b3472..677d27706e 100644 --- a/tests/integration/validate/test_validate_command.py +++ b/tests/integration/validate/test_validate_command.py @@ -139,7 +139,6 @@ def test_lint_supported_runtimes(self): "java11", "java8", "java8.al2", - "nodejs14.x", "nodejs16.x", "nodejs18.x", "nodejs20.x", diff --git a/tests/unit/commands/init/test_cli.py b/tests/unit/commands/init/test_cli.py index d6518927ed..95f09b0431 100644 --- a/tests/unit/commands/init/test_cli.py +++ b/tests/unit/commands/init/test_cli.py @@ -192,7 +192,7 @@ def test_init_image_cli(self, generate_project_patch, git_repo_clone_mock): package_type=IMAGE, runtime=None, architecture=ARM64, - base_image="amazon/nodejs12.x-base", + base_image="amazon/nodejs20.x-base", dependency_manager="npm", output_dir=None, name=self.name, @@ -209,12 +209,12 @@ def test_init_image_cli(self, generate_project_patch, git_repo_clone_mock): # need to change the location validation check ANY, IMAGE, - "nodejs12.x", + "nodejs20.x", "npm", self.output_dir, self.name, True, - {"runtime": "nodejs12.x", "project_name": "testing project", "architectures": {"value": [ARM64]}}, + {"runtime": "nodejs20.x", "project_name": "testing project", "architectures": {"value": [ARM64]}}, False, False, False, @@ -2094,7 +2094,7 @@ def test_init_cli_must_not_generate_default_hello_world_app( ): init_options_from_manifest_mock.return_value = [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2114,10 +2114,10 @@ def test_init_cli_must_not_generate_default_hello_world_app( get_preprocessed_manifest_mock.return_value = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Zip": [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2181,7 +2181,7 @@ def test_must_return_runtime_from_base_image_name(self): "amazon/dotnet6-base", "amazon/go1.x-base", "amazon/java11-base", - "amazon/nodejs14.x-base", + "amazon/nodejs20.x-base", "amazon/python3.8-base", "amazon/ruby2.7-base", "amazon/go-provided.al2-base", @@ -2192,7 +2192,7 @@ def test_must_return_runtime_from_base_image_name(self): "dotnet6", "go1.x", "java11", - "nodejs14.x", + "nodejs20.x", "python3.8", "ruby2.7", "go (provided.al2)", @@ -2235,10 +2235,10 @@ def test_must_process_manifest(self, _get_manifest_mock): } ] }, - "nodejs14.x": { + "nodejs20.x": { "Image": [ { - "directory": "nodejs14.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", + "directory": "nodejs20.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", "displayName": "Hello World Image Example", "dependencyManager": "npm", "appTemplate": "hello-world-lambda-image", @@ -2292,15 +2292,15 @@ def test_must_process_manifest_with_runtime_as_filter_value(self, _get_manifest_ @patch.object(InitTemplates, "__init__", MockInitTemplates.__init__) def test_must_process_manifest_with_image_as_filter_value(self, _get_manifest_mock): template = InitTemplates() - filter_value = "amazon/nodejs14.x-base" + filter_value = "amazon/nodejs20.x-base" _get_manifest_mock.return_value = self.data preprocess_manifest = template.get_preprocessed_manifest(filter_value) expected_result = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Image": [ { - "directory": "nodejs14.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", + "directory": "nodejs20.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", "displayName": "Hello World Image Example", "dependencyManager": "npm", "appTemplate": "hello-world-lambda-image", @@ -2591,7 +2591,7 @@ def test_init_cli_generate_hello_world_app_without_default_prompt( ): init_options_from_manifest_mock.return_value = [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2611,10 +2611,10 @@ def test_init_cli_generate_hello_world_app_without_default_prompt( get_preprocessed_manifest_mock.return_value = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Zip": [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2686,7 +2686,7 @@ def test_init_cli_generate_app_template_provide_via_options( ): init_options_from_manifest_mock.return_value = [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2706,10 +2706,10 @@ def test_init_cli_generate_app_template_provide_via_options( get_preprocessed_manifest_mock.return_value = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Zip": [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -2765,7 +2765,7 @@ def test_init_cli_generate_app_template_provide_via_options( def does_template_meet_filter_criteria(self): template1 = { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -3031,7 +3031,7 @@ def test_init_cli_generate_app_template_provide_via_tracing_options( ): init_options_from_manifest_mock.return_value = [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -3051,10 +3051,10 @@ def test_init_cli_generate_app_template_provide_via_tracing_options( get_preprocessed_manifest_mock.return_value = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Zip": [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -3118,7 +3118,7 @@ def test_init_cli_generate_app_template_provide_via_application_insights_options ): init_options_from_manifest_mock.return_value = [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", @@ -3138,10 +3138,10 @@ def test_init_cli_generate_app_template_provide_via_application_insights_options get_preprocessed_manifest_mock.return_value = { "Hello World Example": { - "nodejs14.x": { + "nodejs20.x": { "Zip": [ { - "directory": "nodejs14.x/cookiecutter-aws-sam-hello-nodejs", + "directory": "nodejs20.x/cookiecutter-aws-sam-hello-nodejs", "displayName": "Hello World Example", "dependencyManager": "npm", "appTemplate": "hello-world", diff --git a/tests/unit/commands/init/test_manifest.json b/tests/unit/commands/init/test_manifest.json index 7ae51a146b..05a3938dda 100644 --- a/tests/unit/commands/init/test_manifest.json +++ b/tests/unit/commands/init/test_manifest.json @@ -19,9 +19,9 @@ "useCaseName": "Hello World Example" } ], - "amazon/nodejs14.x-base": [ + "amazon/nodejs20.x-base": [ { - "directory": "nodejs14.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", + "directory": "nodejs20.x-image/cookiecutter-aws-sam-hello-nodejs-lambda-image", "displayName": "Hello World Image Example", "dependencyManager": "npm", "appTemplate": "hello-world-lambda-image", diff --git a/tests/unit/commands/samconfig/test_samconfig.py b/tests/unit/commands/samconfig/test_samconfig.py index 04597bcb5f..9573b8beff 100644 --- a/tests/unit/commands/samconfig/test_samconfig.py +++ b/tests/unit/commands/samconfig/test_samconfig.py @@ -42,7 +42,7 @@ def test_init(self, do_cli_mock): config_values = { "no_interactive": True, "location": "github.com", - "runtime": "nodejs14.x", + "runtime": "nodejs20.x", "dependency_manager": "maven", "output_dir": "myoutput", "name": "myname", @@ -70,7 +70,7 @@ def test_init(self, do_cli_mock): "github.com", False, ZIP, - "nodejs14.x", + "nodejs20.x", None, None, "maven", diff --git a/tests/unit/hook_packages/terraform/hooks/prepare/prepare_base.py b/tests/unit/hook_packages/terraform/hooks/prepare/prepare_base.py index a65a9c3e61..a204684208 100644 --- a/tests/unit/hook_packages/terraform/hooks/prepare/prepare_base.py +++ b/tests/unit/hook_packages/terraform/hooks/prepare/prepare_base.py @@ -108,12 +108,12 @@ def setUp(self) -> None: self.tf_layer_common_properties: dict = { "layer_name": self.lambda_layer_name, - "compatible_runtimes": ["nodejs14.x", "nodejs16.x"], + "compatible_runtimes": ["nodejs18.x", "nodejs20.x"], "compatible_architectures": ["arm64"], } self.expected_cfn_layer_common_properties: dict = { "LayerName": self.lambda_layer_name, - "CompatibleRuntimes": ["nodejs14.x", "nodejs16.x"], + "CompatibleRuntimes": ["nodejs18.x", "nodejs20.x"], "CompatibleArchitectures": ["arm64"], } diff --git a/tests/unit/hook_packages/terraform/hooks/prepare/test_hook.py b/tests/unit/hook_packages/terraform/hooks/prepare/test_hook.py index ef56f14df8..4aa3b72528 100644 --- a/tests/unit/hook_packages/terraform/hooks/prepare/test_hook.py +++ b/tests/unit/hook_packages/terraform/hooks/prepare/test_hook.py @@ -390,7 +390,7 @@ def side_effect_func(value): "S3Bucket": "s3_bucket_name", "S3Key": "s3_key_name", }, - "CompatibleRuntimes": ["nodejs14.x", "nodejs16.x"], + "CompatibleRuntimes": ["nodejs20.x", "nodejs16.x"], "CompatibleArchitectures": ["arm64"], }, }, @@ -398,7 +398,7 @@ def side_effect_func(value): "Type": "AWS::Lambda::LayerVersion", "Properties": { "Content": relative_path, - "CompatibleRuntimes": ["nodejs14.x", "nodejs16.x"], + "CompatibleRuntimes": ["nodejs20.x", "nodejs16.x"], "CompatibleArchitectures": ["arm64"], }, }, @@ -435,7 +435,7 @@ def side_effect_func(value): "S3Bucket": "s3_bucket_name", "S3Key": "s3_key_name", }, - "CompatibleRuntimes": ["nodejs14.x", "nodejs16.x"], + "CompatibleRuntimes": ["nodejs20.x", "nodejs16.x"], "CompatibleArchitectures": ["arm64"], }, }, @@ -443,7 +443,7 @@ def side_effect_func(value): "Type": "AWS::Lambda::LayerVersion", "Properties": { "Content": updated_relative_path, - "CompatibleRuntimes": ["nodejs14.x", "nodejs16.x"], + "CompatibleRuntimes": ["nodejs20.x", "nodejs16.x"], "CompatibleArchitectures": ["arm64"], }, }, diff --git a/tests/unit/hook_packages/terraform/hooks/prepare/test_resource_linking.py b/tests/unit/hook_packages/terraform/hooks/prepare/test_resource_linking.py index dc80b6cbb6..6dd94545d8 100644 --- a/tests/unit/hook_packages/terraform/hooks/prepare/test_resource_linking.py +++ b/tests/unit/hook_packages/terraform/hooks/prepare/test_resource_linking.py @@ -1637,7 +1637,7 @@ def test_link_lambda_functions_to_layers( "schema_version": 0, "values": { "compatible_architectures": ["arm64"], - "compatible_runtimes": ["nodejs14.x", "nodejs16.x"], + "compatible_runtimes": ["nodejs20.x", "nodejs16.x"], "description": None, "filename": None, "layer_name": "lambda_layer_name", diff --git a/tests/unit/lib/build_module/test_build_graph.py b/tests/unit/lib/build_module/test_build_graph.py index f6959d61a7..06f01fe35e 100644 --- a/tests/unit/lib/build_module/test_build_graph.py +++ b/tests/unit/lib/build_module/test_build_graph.py @@ -288,7 +288,7 @@ class TestBuildGraph(TestCase): LAYER_NAME = "SumLayer" ZIP = ZIP RUNTIME = "python3.8" - LAYER_RUNTIME = "nodejs12.x" + LAYER_RUNTIME = "nodejs20.x" METADATA = {"Test": "hello", "Test2": "world"} UUID = "3c1c254e-cd4b-4d94-8c74-7ab870b36063" LAYER_UUID = "7dnc257e-cd4b-4d94-8c74-7ab870b3abc3" diff --git a/tests/unit/lib/build_module/test_build_strategy.py b/tests/unit/lib/build_module/test_build_strategy.py index 086a67bd78..05c99437bf 100644 --- a/tests/unit/lib/build_module/test_build_strategy.py +++ b/tests/unit/lib/build_module/test_build_strategy.py @@ -343,7 +343,7 @@ class CachedBuildStrategyTest(BuildStrategyBaseTest): FUNCTION_UUID = "3c1c254e-cd4b-4d94-8c74-7ab870b36063" SOURCE_HASH = "cae49aa393d669e850bd49869905099d" LAYER_UUID = "761ce752-d1c8-4e07-86a0-f64778cdd108" - LAYER_METHOD = "nodejs12.x" + LAYER_METHOD = "nodejs20.x" BUILD_GRAPH_CONTENTS = f""" [function_build_definitions] @@ -358,8 +358,8 @@ class CachedBuildStrategyTest(BuildStrategyBaseTest): [layer_build_definitions.{LAYER_UUID}] layer_name = "SumLayer" codeuri = "sum_layer/" - build_method = "nodejs12.x" - compatible_runtimes = ["nodejs12.x"] + build_method = "nodejs20.x" + compatible_runtimes = ["nodejs20.x"] source_hash = "{SOURCE_HASH}" layer = "SumLayer" """ @@ -733,7 +733,7 @@ def setUp(self) -> None: @parameterized.expand( [ "python3.7", - "nodejs12.x", + "nodejs20.x", "ruby2.7", ] ) diff --git a/tests/unit/lib/build_module/test_workflow_config.py b/tests/unit/lib/build_module/test_workflow_config.py index 8aa5279764..c284655414 100644 --- a/tests/unit/lib/build_module/test_workflow_config.py +++ b/tests/unit/lib/build_module/test_workflow_config.py @@ -28,7 +28,7 @@ def test_must_work_for_python(self, runtime): self.assertIn(Event("BuildWorkflowUsed", "python-pip"), EventTracker.get_tracked_events()) self.assertFalse(result.must_mount_with_write_in_container) - @parameterized.expand([("nodejs12.x",), ("nodejs14.x",), ("nodejs16.x",), ("nodejs18.x",), ("nodejs20.x",)]) + @parameterized.expand([("nodejs16.x",), ("nodejs18.x",), ("nodejs20.x",)]) def test_must_work_for_nodejs(self, runtime): result = get_workflow_config(runtime, self.code_dir, self.project_dir) self.assertEqual(result.language, "nodejs") @@ -135,7 +135,7 @@ def test_must_work_for_java(self, runtime, build_file, dep_manager, os_mock): self.assertIn(Event("BuildWorkflowUsed", "java-maven"), EventTracker.get_tracked_events()) def test_must_get_workflow_for_esbuild(self): - runtime = "nodejs12.x" + runtime = "nodejs20.x" result = get_workflow_config(runtime, self.code_dir, self.project_dir, specified_workflow="esbuild") self.assertEqual(result.language, "nodejs") self.assertEqual(result.dependency_manager, "npm-esbuild") diff --git a/tests/unit/lib/cli_validation/test_image_repository_validation.py b/tests/unit/lib/cli_validation/test_image_repository_validation.py index 37f00b1f87..800fa75d9e 100644 --- a/tests/unit/lib/cli_validation/test_image_repository_validation.py +++ b/tests/unit/lib/cli_validation/test_image_repository_validation.py @@ -207,13 +207,13 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, } }, @@ -236,13 +236,13 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, } }, @@ -265,13 +265,13 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, } }, @@ -294,19 +294,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -315,7 +315,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -344,19 +344,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -365,7 +365,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -391,19 +391,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -412,7 +412,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -440,19 +440,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -461,7 +461,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -491,19 +491,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -512,7 +512,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -531,19 +531,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunctionInChild": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFuncInChild": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -552,7 +552,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -583,19 +583,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -604,7 +604,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -623,19 +623,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunctionInChild": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFuncInChild": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -644,7 +644,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -679,19 +679,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunction": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFunc": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -700,7 +700,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -719,19 +719,19 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "CodeUri": ".", }, }, "LambdaFunctionInChild": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, }, "ServerlessImageFuncInChild": { "Type": "AWS::Serverless::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "ImageUri": ".", "PackageType": "Image", }, @@ -740,7 +740,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Type": "AWS::Lambda::Function", "Properties": { "Handler": "lambda.handler", - "Runtime": "nodejs14.x", + "Runtime": "nodejs20.x", "Code": {"ImageUri": "."}, "PackageType": "Image", }, @@ -772,7 +772,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -782,7 +782,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -809,7 +809,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -819,7 +819,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -846,7 +846,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -856,7 +856,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -883,7 +883,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -893,7 +893,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -953,7 +953,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -963,7 +963,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1023,7 +1023,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1033,7 +1033,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1093,7 +1093,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1103,7 +1103,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1160,7 +1160,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1170,7 +1170,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1220,7 +1220,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunctionInChild1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild1", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild1/Resource", @@ -1230,7 +1230,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunctionInChild2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild2", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild2/Resource", @@ -1292,7 +1292,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1302,7 +1302,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1352,7 +1352,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunctionInChild1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild1", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild1/Resource", @@ -1362,7 +1362,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunctionInChild2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild2", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild2/Resource", @@ -1424,7 +1424,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1434,7 +1434,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1484,7 +1484,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunctionInChild1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild1", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild1/Resource", @@ -1494,7 +1494,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunctionInChild2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild2", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild2/Resource", @@ -1560,7 +1560,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunction1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction1", "aws:cdk:path": "Stack/CDKLambdaFunction1/Resource", @@ -1570,7 +1570,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunction2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunction2", "aws:cdk:path": "Stack/CDKLambdaFunction2/Resource", @@ -1620,7 +1620,7 @@ class TestIsAllImageFunctionsProvided(TestCase): "Resources": { "LambdaFunctionInChild1": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild1", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild1/Resource", @@ -1630,7 +1630,7 @@ class TestIsAllImageFunctionsProvided(TestCase): }, "LambdaFunctionInChild2": { "Type": "AWS::Lambda::Function", - "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs14.x", "Code": "."}, + "Properties": {"Handler": "lambda.handler", "Runtime": "nodejs20.x", "Code": "."}, "Metadata": { "SamResource": "CDKLambdaFunctionInChild2", "aws:cdk:path": "Stack/CDKLambdaFunctionInChild2/Resource", diff --git a/tests/unit/lib/utils/test_architecture.py b/tests/unit/lib/utils/test_architecture.py index 860c513a07..fbf52e5901 100644 --- a/tests/unit/lib/utils/test_architecture.py +++ b/tests/unit/lib/utils/test_architecture.py @@ -42,7 +42,7 @@ def test_validate_architecture_errors(self, value): @parameterized.expand( [ - ("nodejs14.x", X86_64, ZIP), + ("nodejs20.x", X86_64, ZIP), ("java8.al2", ARM64, ZIP), ("dotnet6", ARM64, ZIP), (None, X86_64, IMAGE), diff --git a/tests/unit/lib/utils/test_lambda_builders.py b/tests/unit/lib/utils/test_lambda_builders.py index d0fc170ea3..88746e3492 100644 --- a/tests/unit/lib/utils/test_lambda_builders.py +++ b/tests/unit/lib/utils/test_lambda_builders.py @@ -9,7 +9,7 @@ class TestPatchRuntime(TestCase): @parameterized.expand( [ - ("nodejs14.x", "nodejs14.x"), + ("nodejs20.x", "nodejs20.x"), ("java8.al2", "java8"), ("dotnet6", "dotnet6"), ("provided", "provided"), diff --git a/tests/unit/local/docker/test_lambda_build_container.py b/tests/unit/local/docker/test_lambda_build_container.py index d62c52e893..d788b8ee2e 100644 --- a/tests/unit/local/docker/test_lambda_build_container.py +++ b/tests/unit/local/docker/test_lambda_build_container.py @@ -182,7 +182,7 @@ class TestLambdaBuildContainer_get_image(TestCase): @parameterized.expand( [ ("myruntime", ARM64, "public.ecr.aws/sam/build-myruntime:latest-arm64"), - ("nodejs14.x", X86_64, "public.ecr.aws/sam/build-nodejs14.x:latest-x86_64"), + ("nodejs20.x", X86_64, "public.ecr.aws/sam/build-nodejs20.x:latest-x86_64"), ] ) def test_must_get_image_name(self, runtime, architecture, expected_image_name): diff --git a/tests/unit/local/docker/test_lambda_container.py b/tests/unit/local/docker/test_lambda_container.py index acce6a5ca7..681931402d 100644 --- a/tests/unit/local/docker/test_lambda_container.py +++ b/tests/unit/local/docker/test_lambda_container.py @@ -16,8 +16,6 @@ RUNTIMES_WITH_ENTRYPOINT = [Runtime.dotnet6.value, Runtime.go1x.value] RUNTIMES_WITH_BOOTSTRAP_ENTRYPOINT = [ - Runtime.nodejs12x.value, - Runtime.nodejs14x.value, Runtime.nodejs16x.value, Runtime.nodejs18x.value, Runtime.nodejs20x.value, @@ -47,7 +45,7 @@ class TestLambdaContainer_init(TestCase): def setUp(self): - self.runtime = "nodejs12.x" + self.runtime = "nodejs20.x" self.handler = "handler" self.code_dir = "codedir" self.image_config = None diff --git a/tests/unit/local/docker/test_lambda_debug_settings.py b/tests/unit/local/docker/test_lambda_debug_settings.py index c05b8cd04e..d9501f4e7b 100644 --- a/tests/unit/local/docker/test_lambda_debug_settings.py +++ b/tests/unit/local/docker/test_lambda_debug_settings.py @@ -13,8 +13,6 @@ Runtime.java21, Runtime.dotnet6, Runtime.go1x, - Runtime.nodejs12x, - Runtime.nodejs14x, Runtime.nodejs16x, Runtime.nodejs18x, Runtime.nodejs20x, diff --git a/tests/unit/local/docker/test_lambda_image.py b/tests/unit/local/docker/test_lambda_image.py index b56c13798c..91ba339b5e 100644 --- a/tests/unit/local/docker/test_lambda_image.py +++ b/tests/unit/local/docker/test_lambda_image.py @@ -18,9 +18,9 @@ class TestRuntime(TestCase): @parameterized.expand( [ - ("nodejs12.x", "nodejs:12-x86_64"), - ("nodejs14.x", "nodejs:14-x86_64"), ("nodejs16.x", "nodejs:16-x86_64"), + ("nodejs18.x", "nodejs:18-x86_64"), + ("nodejs20.x", "nodejs:20-x86_64"), ("python2.7", "python:2.7"), ("python3.7", "python:3.7"), ("python3.8", "python:3.8-x86_64"),