awslabs / aws-lambda-powershell-runtime

This new PowerShell custom runtime for AWS Lambda makes it even easier to run Lambda functions written in PowerShell to process events.
Apache License 2.0
59 stars 20 forks source link

provided.al2023' runtime is not supported #31

Closed sholland-bamboohealth closed 6 months ago

sholland-bamboohealth commented 8 months ago

when I run sam build --parallel it fails at

rm -Rf /mnt/c/temp/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam/build/PwshRuntimeLayer/modules/Private
chmod +x /mnt/c/temp/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam/build/PwshRuntimeLayer/bootstrap
Building codeuri: /mnt/c/temp/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/function runtime: provided.al2023 metadata: {'BuildMethod': 'makefile'} architecture: x86_64 functions:
DemoPowerShellFunction

Build Failed
Error: 'provided.al2023' runtime is not supported
julianwood commented 8 months ago

What version of AWS SAM are you running? Looks like the version you have may not support the al.2023 runtime.

sholland-bamboohealth commented 8 months ago
SAM CLI, version 1.107.0

what version works?

julianwood commented 8 months ago

That's certainly up to date enough. I've tried with the same version and get no error: This from the logs

chmod +x /mnt/c/GitProjects/PowerShell/github-awslabs/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam/build/PwshRuntimeLayer/bootstrap
Building codeuri:
/mnt/c/GitProjects/PowerShell/github-awslabs/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/function
runtime: provided.al2023 metadata: {'BuildMethod': 'makefile'} architecture: x86_64 functions: DemoPowerShellFunction
DemoPowerShellFunction: Running CustomMakeBuilder:CopySource
DemoPowerShellFunction: Running CustomMakeBuilder:MakeBuild
DemoPowerShellFunction: Current Artifacts Directory :
/mnt/c/GitProjects/PowerShell/github-awslabs/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam
/build/DemoPowerShellFunction
cp -R . /mnt/c/GitProjects/PowerShell/github-awslabs/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam/build/DemoPowerShellFunction
rm /mnt/c/GitProjects/PowerShell/github-awslabs/aws-lambda-powershell-runtime/examples/demo-runtime-layer-function/.aws-sam/build/DemoPowerShellFunction/Makefile

Build Succeeded
# sam --version
SAM CLI, version 1.107.0
julianwood commented 8 months ago

Can you try sam build --parallel --use-container to try role out some local build environment issue.