mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-21 17:37:29 -07:00
36 lines
903 B
Docker
36 lines
903 B
Docker
<<<<<<< HEAD
|
|
FROM node:16.15.1-bullseye AS builder
|
|
=======
|
|
FROM node:18.2.0-alpine3.15 AS base
|
|
>>>>>>> thatonecalculator/yarn-3
|
|
|
|
ARG NODE_ENV=production
|
|
|
|
WORKDIR /misskey
|
|
|
|
COPY . ./
|
|
|
|
RUN apt-get update
|
|
RUN apt-get install -y build-essential
|
|
RUN git submodule update --init
|
|
RUN yarn install
|
|
RUN yarn build
|
|
RUN rm -rf .git
|
|
|
|
FROM node:16.15.1-bullseye-slim AS runner
|
|
|
|
WORKDIR /misskey
|
|
|
|
RUN apt-get update
|
|
RUN apt-get install -y ffmpeg tini
|
|
|
|
COPY --from=builder /misskey/node_modules ./node_modules
|
|
COPY --from=builder /misskey/built ./built
|
|
COPY --from=builder /misskey/packages/backend/node_modules ./packages/backend/node_modules
|
|
COPY --from=builder /misskey/packages/backend/built ./packages/backend/built
|
|
COPY --from=builder /misskey/packages/client/node_modules ./packages/client/node_modules
|
|
COPY . ./
|
|
|
|
ENV NODE_ENV=production
|
|
ENTRYPOINT ["/usr/bin/tini", "--"]
|
|
CMD ["npm", "run", "migrateandstart"]
|