Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workaround for node 18 and using docker? #1688

Closed
OscBacon opened this issue May 4, 2023 · 4 comments
Closed

Workaround for node 18 and using docker? #1688

OscBacon opened this issue May 4, 2023 · 4 comments

Comments

@OscBacon
Copy link

OscBacon commented May 4, 2023

Hi,
Is there any workaround or tipe for using node 18 and testing with useDocker?

@fahimuddin-brillmark
Copy link

fahimuddin-brillmark commented May 4, 2023

@OscBacon Seems like I am having the same issue, cannot use lambda layers in serverless-offline.
Looks like the base image of docker used by serverless-offline for Node 18 is deprecated :
https://github.com/lambci/docker-lambda for https://github.com/aws/aws-lambda-base-images

Hopefully team responds soon with some workarounds.

@davidjb
Copy link

davidjb commented May 12, 2023

serverless-offline is currently using lambci images for Docker, as @fahimuddin-brillmark mentioned, which were abandoned a long while ago and haven't been updated in years. Serverless itself is in the same situation with its serverless invoke local - it is still currently using lambci too. I did a write-up about what it would take to update that codebase to using the latest AWS images and feel it's pretty relevant here too: serverless/serverless#10797 (comment)

Key takeaways are that the mapping a handler to a Lambda runtime container isn't just as simple as a string replacement or templating any longer (requiring a bit of logic), and the internals workings of the containers are understandably different.

My use case was looking at getting Go working under provider.al2 (the current runtime since go1.x is EOL), and as with Serverless itself, some work would be needed to make serverless-offline compatible, although I did start with #1691.

@manfioLP
Copy link

thanks @davidjb - helped me a lot :)

@DorianMazur
Copy link
Collaborator

@OscBacon @davidjb @manfioLP @fahimuddin-brillmark This should now be fixed. I just merged a PR that solves this issue - #1755

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants