-
Notifications
You must be signed in to change notification settings - Fork 55
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
node 16 support #53
Comments
Same interest here |
Same here, no commits since July, last release on 2021, project abandoned? (hope not) |
The current release just crashes with nodejs-16 on alpine linux. Would be great to have a compatible version. |
Same interest here |
Same interest here. I got an email from Amazon telling me to upgrade my lambdas to node 16... and then am met with this. |
image doesn't build with node:16 |
Duplicate. See #41 (comment) |
For what it's worth although it doesn't seem to build with the node:16-buster or node:18-buster images it does seem to build with Node.js installed via the binary archive so, for example I did the following where the first stage build-image differs from the docs in this repo, but the second stage is largely the same:
and for Node.js 18
This was with a trivial echo lambda
One other thing I observed is that with Node 16 and 18 npx seems to launch less "cleanly", there seems to be a sh -c rather than directly execing node, so I observed aws-lambda-ric starts fine, but segfaults (or the launcher does) if its HTTP connection is disconnected. That doesn't happen if aws-lambda-ric is run directly with node, so my lambda-entrypoint.sh looks like this:
Hopefully this is useful and helps give folks an approach that lets them continue to use the official node node:16-buster or node:18-buster images. As has been pointed out elsewhere it's also possible to "kidnap" the aws-lambda-ric from the official AWS base images. That actually appears somewhat different to the aws-lambda-ric in this repo, though that may be superficial/packaging differences. Like others here I think AWS should at least give a heads-up/ETA of when up to date versions of Node.js will be properly supported, especially as the official AWS images are kind of large...... HTH |
@fadams I managed to make the "kidnap" option work (pretty well so far) for Node 18. Given my unique needs, that turned out to be the best option. It's unfortunate AWS support has been so lacking. Anyhow, if it's helpful to anyone else, this was my multi-stage FROM public.ecr.aws/lambda/nodejs:18 as lambda-image
FROM node:18
RUN ln -sf bash /bin/sh
RUN mkdir /var/task
WORKDIR /var/task
RUN apt-get update && \
apt-get install -y \
g++ \
make \
cmake \
unzip \
libcurl4-openssl-dev \
autoconf \
libtool \
libtool-bin
ENV LAMBDA_RUNTIME_DIR=/var/runtime
ENV LAMBDA_TASK_ROOT=/var/task
RUN mkdir /var/lang
RUN ln -s /usr/local/bin /var/lang/bin
COPY --from=lambda-image /lambda-entrypoint.sh /lambda-entrypoint.sh
COPY --from=lambda-image /var/runtime /var/runtime
COPY --from=lambda-image /usr/local/bin/aws-lambda-rie /usr/local/bin/aws-lambda-rie
ADD . .
RUN npm i
ENTRYPOINT ["/lambda-entrypoint.sh"]
CMD ["index.handler"] |
Hi, We investigated the issue and have updated instructions on how to use the RIC with Node16+. Summary of the issue:
|
by when it will support node 16
The text was updated successfully, but these errors were encountered: