Change CodeBuild Image for AWS Lambda Applications

0

I created an AWS Lambda Application using the Nodejs template.

https://us-east-2.console.aws.amazon.com/lambda/home?region=us-east-2#/applications

This uses the following image for CodeBuild.

Image: aws/lambda/nodejs:10-1.0

I see this inside the serverlessrepo-APP_NAME-toolchain stack under the template tab

https://us-east-2.console.aws.amazon.com/cloudformation/home?region=us-east-2#/stacks/template

Is there a way to change this image for the stack? I'd like to have java jdk with gradle installed in addition to nodejs. I'm am currently trying to do a workaround where I install java, gradle and set the environment variables during the install phase in the buildspec.yml, but that is a hacky workaround that will slow down the build pipeline. Can I modify the stack image after it's been created? I only saw an option to make a new stack that is a modification of a previous stack, but the previous stack is left unchanged.

Here's the buildspec.yml with the workaround. It's still failing to install java correctly so the build is failing, but I think this is the wrong approach anyway. I should be updating the build image so it's ready to go.

https://github.com/bennebbenneb/sample-app/blob/master/buildspec.yml#L4

답변 없음

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠