Skip to content

panascais-docker/node

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

712 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

panascais/node

GitHub Workflow Status Docker Pulls Docker Stars Docker Image Size License

Tag: Command: Node Version: Supported: Labels:
lts docker pull panascais/node:lts v22.x.x Docker Image Size
latest docker pull panascais/node v24.x.x Docker Image Size
24 docker pull panascais/node:24 v24.x.x Docker Image Size
23 docker pull panascais/node:23 v23.x.x Docker Image Size
22 docker pull panascais/node:22 v22.x.x Docker Image Size
21 docker pull panascais/node:21 v21.x.x Docker Image Size
20 docker pull panascais/node:20 v20.x.x Docker Image Size
19 docker pull panascais/node:19 v19.x.x × Docker Image Size
18 docker pull panascais/node:18 v18.x.x × Docker Image Size
17 docker pull panascais/node:17 v17.x.x × Docker Image Size
16 docker pull panascais/node:16 v16.x.x × Docker Image Size
15 docker pull panascais/node:15 v15.x.x × Docker Image Size
14 docker pull panascais/node:14 v14.x.x × Docker Image Size
13 docker pull panascais/node:13 v13.x.x × Docker Image Size
12 docker pull panascais/node:12 v12.x.x × Docker Image Size
11 docker pull panascais/node:11 v11.x.x × Docker Image Size
10 docker pull panascais/node:10 v10.x.x × Docker Image Size
9 docker pull panascais/node:9 v9.x.x × Docker Image Size
8 docker pull panascais/node:8 v8.x.x × Docker Image Size
7 docker pull panascais/node:7 v7.x.x × Docker Image Size
6 docker pull panascais/node:6 v6.x.x × Docker Image Size
4 docker pull panascais/node:4 v4.x.x × Docker Image Size

Build

Example for bash and node version 22:

docker build \
    --build-arg BUILD_DATE=`date -u +"%Y-%m-%dT%H:%M:%SZ"` \
    --build-arg VCS_REF=`git rev-parse --short HEAD` \
    --build-arg NODE_VERSION=`cat ./configuration/versions.json | jq '."22"' -r` \
    --build-arg CHECKSUM=`cat ./configuration/checksums.json | jq '."22"' -r` \
    -t panascais/node:22 \
    ./22

Example for fish and node version 22:

docker build \
    --build-arg BUILD_DATE=(date -u +"%Y-%m-%dT%H:%M:%SZ") \
    --build-arg VCS_REF=(git rev-parse --short HEAD) \
    --build-arg NODE_VERSION=(cat ./configuration/versions.json | jq '."22"' -r) \
    --build-arg CHECKSUM=(cat ./configuration/checksums.json | jq '."22"' -r) \
    -t panascais/node:22 \
    ./22

Docker cache mounts

BuildKit cache mounts reuse downloaded apk packages between builds. Only the packager stage (alpine:3.23) uses them:

RUN --mount=type=cache,id=node-apk-${TARGETARCH},sharing=locked,target=/apk/cache \
    apk update --cache-dir /apk/cache \
    && apk add --cache-dir /apk/cache --cache-predownload \
    ...

The builder stage runs on upstream node:X-alpine, which may ship apk-tools 2.x (Alpine 3.22 or older). Flags like --cache-predownload are apk-tools 3.x only, so the builder installs its two build deps with plain apk add --no-cache binutils curl instead.

Alpine 3.23 ships apk-tools 3.x, where --update / -U means --cache-max-age 0 (always refetch). Do not use it with cache mounts on the packager stage.

Cache IDs include ${TARGETARCH} so amd64 and arm64 packages do not mix during multi-platform builds. sharing=locked avoids races when matrix jobs build in parallel.

pnpm

pnpm is installed via get.pnpm.io into /usr/local/bin/pnpm (Alpine-compatible). PNPM_HOME is /root/.local/share/pnpm for optional global installs; PATH prefers /usr/local/bin so the standalone CLI is not affected by store mounts in downstream builds.

This image does not cache-mount pnpm during its own build — it only downloads the standalone CLI (~few MB), so a store cache would add complexity for little gain.

Application Dockerfiles should cache installs at a separate path such as /pnpm/store, not /root/.local/share/pnpm/store. See pnpm Docker docs.

pnpm 11 images ship enableGlobalVirtualStore: false in /root/.config/pnpm/config.yaml so global installs (pnpm add -g) work with BuildKit cache mounts on the store path (see downstream ci-node).

Contributors

Contributing

Interested in contributing to Node? Contributions are welcome, and are accepted via pull requests. Please review these guidelines before submitting any pull requests.

License

Code licensed under MIT, documentation under CC BY 3.0.

About

Panascais Node Image

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors