FROM alpine AS builder
WORKDIR /home/app
RUN apk add --no-cache --update nodejs nodejs-npm
COPY package.json package-lock.json ./
RUN npm install --production
FROM alpine
WORKDIR /home/app
RUN apk add --no-cache --update nodejs nodejs-npm
RUN npm i -g pm2 && node -v && npm -v
COPY --from=builder /home/app/node_modules ./node_modules
COPY . .
# CMD [ "npm", "start" ]
CMD [ "pm2-runtime", "start", "app.js" ]
-
Notifications
You must be signed in to change notification settings - Fork 0
itxishu/docker-node-alpine
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
docker-node-alpine
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published