aws-codebuild-docker-images icon indicating copy to clipboard operation
aws-codebuild-docker-images copied to clipboard

Add all supported Lambda Runtimes to CodeBuild images

Open rshayman opened this issue 1 year ago • 7 comments

We received communication from AWS that the Ubuntu Standard 4.0 and Ubuntu Standard 5.0 images will be deprecated at the end of March 2023. For various reasons we still depend on older version of Python and NodeJS which are still supported runtime s for Lambda.

In fact, thee Standard 6.0 build image only supports Python 3.10 which is current not a supported Lambda Runtime. This does not make sense. Likewise, NodeJS 12.x, NodeJS 14.x and NodeJS 18 are are all supported lambda runtimes, which will not be supported by ANY supported build images by the end of March 2023. This makes the job of your customer base much more difficult than it needs to be. Please do the heavy lifting for us and link the available runtimes with those support by Lambda

https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html

Addendum: The same set of runtime should be available across all architectures wherever possible.

rshayman avatar Mar 14 '23 11:03 rshayman

Thanks for the feedback. CodeBuild will send an updated communication and extend the support for Ubuntu standard 5.0, until we provide viable alternative for the non-EOL language runtimes supported on this images version.

subinataws avatar Mar 14 '23 13:03 subinataws

We also acknowledge the feedback about having same language runtime versions supported across AWS services, specifically the ones used together for development.

subinataws avatar Mar 14 '23 14:03 subinataws

@subinataws, just to double-check, Ubuntu Standard 4.0 will still be depreciated? For now, I still see it listed at https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-available.html

petreikis avatar Apr 03 '23 09:04 petreikis

Is there anyway the images can support language version overlaps with the previous image or more closely align with language versions that are available in lambda? https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html

Right now, we have teams that use both Python and Node that run in Lambda in their projects. The latest supported Python version in Lambda is Python3.10 and the latest Node is 18 however the Ubuntu standard 6 supports Python3.10 and Node16 but Ubuntu standard 7 only supports Python3.11 and Node18. No matter which standard Ubuntu version my teams want to use, they will have to manually install the version in the prebuild step. This is causing some frustration for my team and leading to a poor user experience.

emcfins avatar Apr 19 '23 14:04 emcfins

The issue described here also presents a challenge for updating image versions and runtimes.

The scenario is:

  • The CodeBuild image is defined via IaaC in a repository which contains all the infra for all the accounts.
  • Each application repository has its buildspec file, in which we define the runtime version for node.
  • We are currently using ubuntu/standard:5.0, which enables the use on both node 12 and node 14 runtimes.
  • We are currently using node 14.
  • ubuntu/standard:6.0 only has node 16 runtime
  • In order to upgrade to ubuntu/standard:6.0 we would need to update both the CodeBuild image and the BuildSpecs of all repositories (50+) at the exact same time in order to avoid Pipeline disruption, as trying to install node 14 on ubuntu/standard:6.0 would error out, since it's not available.

My humble suggestion would be to keep at least 2 versions of each runtime on every image (just like its done in ubuntu/standard:5.0). This would really smooth the update process for people and companies that have a similar scenario.

pliniodng avatar Jun 15 '23 15:06 pliniodng

@pliniodng That's pretty much our exact scenario also, a central repo that manages the IaC for all CodeBuild jobs, with buildspecs managed separately by each other repo. Updating the image via the IaC often creates havoc with behavioral changes, requiring updates across all the repos.

I've occasionally wondered what it might look like if CodeBuild supported setting/overriding the image in the buildspec (which basically every other CI provider supports)...

lorengordon avatar Jun 15 '23 15:06 lorengordon

CodeBuild's latest images for Amazon Linux (e.g.: 5.0) and Ubuntu (e.g. 7.0) support all non-EOL runtime versions and should match up for your development need with Lambda. Do let us know if you face anymore issues with inconsistencies.

subinataws avatar Apr 11 '24 01:04 subinataws