-
-
Notifications
You must be signed in to change notification settings - Fork 127
Open
Description
https://docker-handbook.farhan.dev/containerizing-a-multi-container-javascript-application
In the Writing The Dockerfile section. The image throws an error when trying to build it. Seems like the node:lts-alpine image now requires the python3 package to work in conjuntion with make and g++
# stage one
FROM node:lts-alpine as builder
**# install dependencies for node-gyp
RUN apk add --no-cache python3 make g++**
WORKDIR /app
COPY ./package.json .
RUN npm install --only=prod
# stage two
FROM node:lts-alpine
EXPOSE 3000
ENV NODE_ENV=production
USER node
RUN mkdir -p /home/node/app
WORKDIR /home/node/app
COPY . .
COPY --from=builder /app/node_modules /home/node/app/node_modules
CMD [ "node", "bin/www" ]
The error im getting is
COPY . .
error: failed to solve: failed to commit z6i7kna5qd6l2zorgsp5gk7gq to s9buxxopyv8imbpet4eetavkd during finalize: failed to stat active key during commit: snapshot z6i7kna5qd6l2zorgsp5gk7gq does not exist: not found
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels