attempt docker build with pnpm

This commit is contained in:
Amruth Pillai
2022-03-03 15:33:11 +01:00
parent 58160b2b6e
commit 5fc7a32c67
4 changed files with 14369 additions and 47287 deletions

View File

@ -1,16 +1,26 @@
FROM mcr.microsoft.com/playwright:focal
FROM mcr.microsoft.com/playwright:focal AS build
RUN curl -f https://get.pnpm.io/v6.16.js | node - add --global pnpm
WORKDIR /app
COPY ./package*.json .
COPY .npmrc package.json pnpm-lock.yaml ./
RUN npm ci
RUN pnpm install --frozen-lockfile
COPY . .
RUN npm run build
RUN pnpm run build
FROM mcr.microsoft.com/playwright:focal AS deploy
RUN curl -f https://get.pnpm.io/v6.16.js | node - add --global pnpm
WORKDIR /app
COPY --from=build /app/dist ./dist
# Expose App
EXPOSE 3000
EXPOSE 3100
CMD [ "npm", "start" ]
CMD [ "pnpm", "start" ]