Home > Enterprise >  How to use node LTS version in alpine:3.17 image?
How to use node LTS version in alpine:3.17 image?

Time:12-17

I'm using alpine 3.14 docker image. In the release info it is said, there is node LTS (18) and current (19) included.

How do I use the LTS version of node, which is 18.20?

FROM alpine:3.17@sha256:c0d488a800e4127c334ad20d61d7bc21b4097540327217dfab52262adc02380c

RUN apk --update add bash curl git npm

Using this container, the current node version is used.

CodePudding user response:

The Alpine OS distribution is different from the Alpine docker containers. The alpine container images do not include node. In fact, most of the packages listed on the page you link are not included.

If you want an alpine 3.17 container image that includes the current LTS version of node, you can use node:lts-alpine3.17.

  • Related