You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
sam build on a Java11 Gradle image hello-world app fails. This is affecting me on Windows 10, unsure if it affects other OSes. Definitely does not affect a similar Maven image.
Steps to reproduce:
sam init a Java11 Gradle image hello-world app
cd sam-app
sam build
Observed result:
PS C:\Users\xxxxx\testApps\javamavenonly\lambda-java11\sam-app> sam build
Building codeuri: C:\Users\xxxxx\testApps\javamavenonly\lambda-java11\sam-app runtime: None metadata: {'DockerTag': 'java11-gradle-v1', 'DockerContext': 'C:\\Users\\xxxxx\\testApps\\javamavenonly\\lambda-java11\\sam-app\\HelloWorldFunction', 'Dockerfile': 'Dockerfile'} functions: ['HelloWorldFunction']
Building image for HelloWorldFunction function
Setting DockerBuildArgs: {} for HelloWorldFunction function
---> 65a02b57e7e1
Step 2/16 : ARG SCRATCH_DIR=/var/task/build
---> Using cache
---> d09ff3bbb8a7
Step 3/16 : COPY src/ src/
---> Using cache
---> 4618bee4ba1a
Step 4/16 : COPY gradle/ gradle/
---> Using cache
---> 3f26f691faf9
Step 5/16 : COPY build.gradle gradlew ./
---> Using cache
---> 71a4b474ed5b
Step 6/16 : RUN mkdir build
---> Using cache
---> 44d57749f6b4
Step 7/16 : COPY gradle/lambda-build-init.gradle ./build
---> Using cache
---> a8d10ca5504b
Step 8/16 : RUN ./gradlew --project-cache-dir $SCRATCH_DIR/gradle-cache -Dsoftware.amazon.aws.lambdabuilders.scratch-dir=$SCRATCH_DIR --init-script $SCRATCH_DIR/lambda-build-init.gradle build
---> Running in 9e61aa3d1056
: No such file or directory
Build Failed
Error: HelloWorldFunction failed to build: The command '/bin/sh -c ./gradlew --project-cache-dir $SCRATCH_DIR/gradle-cache -Dsoftware.amazon.aws.lambdabuilders.scratch-dir=$SCRATCH_DIR --init-script $SCRATCH_DIR/lambda-build-init.gradle build' returned a non-zero code: 127
Expected result:
Successfully built SAM app
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
OS: Windows 10
sam --version: SAM CLI, version 1.21.1
AWS region: N/A Add --debug flag to command you are running
The text was updated successfully, but these errors were encountered:
Description:
sam build
on a Java11 Gradle image hello-world app fails. This is affecting me on Windows 10, unsure if it affects other OSes. Definitely does not affect a similar Maven image.Steps to reproduce:
sam init
a Java11 Gradle image hello-world appcd sam-app
sam build
Observed result:
Expected result:
Successfully built SAM app
Additional environment details (Ex: Windows, Mac, Amazon Linux etc)
sam --version
: SAM CLI, version 1.21.1Add --debug flag to command you are running
The text was updated successfully, but these errors were encountered: