muse/Dockerfile

34 lines
411 B
Docker
Raw Normal View History

FROM node:14-alpine AS base
2020-03-17 18:30:27 +01:00
# Install ffmpeg
RUN apk add --no-cache ffmpeg
2020-03-17 18:30:27 +01:00
WORKDIR /usr/app
COPY package* ./
2020-03-17 18:30:27 +01:00
# Dependencies
FROM base AS dependencies
RUN npm install
# Build app
FROM dependencies AS builder
2020-03-17 18:30:27 +01:00
COPY . .
RUN npm run build
RUN ls
# Only copy essentials
FROM base AS prod
RUN ls
COPY --from=builder /usr/app/dist dist
RUN npm i --only=prod
2020-03-17 18:30:27 +01:00
ENV DATA_DIR /data
CMD ["npm", "run", "start"]