-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
21 lines (17 loc) · 793 Bytes
/
Dockerfile
File metadata and controls
21 lines (17 loc) · 793 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
FROM docker.io/node:24-alpine
LABEL org.opencontainers.image.source="https://github.com/cloud-cli/image-node"
RUN sed -i -e 's/^root::/root:!:/' /etc/shadow && \
set -xe && apk add --no-cache bash git openssh nano python3 py3-pip curl gcc g++ make libc-dev && \
git config --global --add safe.directory /home/app
ENV HOME=/home/node
COPY node /home/node
RUN mkdir -p /home/app
RUN chown -R 1000:1000 /home && chmod -R a+r /home
RUN npm i -g npm@latest pnpm@latest
RUN cd /home/node && npm i --no-audit --no-fund superstatic@latest
RUN chown -R 1000:1000 /home/node/.npm
USER 1000
WORKDIR /home/app
ENTRYPOINT ["/bin/bash", "/home/node/entrypoint.sh"]
ENV PATH="$PATH:/home/node/npm/bin:/home/app/node_modules/.bin"
ENV NODE_OPTIONS="--no-warnings --import file:///home/node/hooks.mjs"