mirror of
https://github.com/revoltchat/revite.git
synced 2024-11-22 23:20:58 -05:00
19 lines
416 B
Docker
19 lines
416 B
Docker
FROM node:16-buster AS builder
|
|
|
|
WORKDIR /usr/src/app
|
|
COPY . .
|
|
COPY .env.build .env
|
|
|
|
RUN corepack pnpm install
|
|
RUN pnpm install --frozen-lockfile
|
|
RUN pnpm typecheck
|
|
RUN NODE_OPTIONS='--max-old-space-size=4096' pnpm build:all
|
|
RUN find . -name "node_modules" -type d -prune
|
|
RUN pnpm install --prod
|
|
|
|
FROM node:16-alpine
|
|
WORKDIR /usr/src/app
|
|
COPY --from=builder /usr/src/app .
|
|
|
|
EXPOSE 5000
|
|
CMD [ "pnpm", "start:inject" ]
|