mirror of
https://github.com/immich-app/immich.git
synced 2024-12-29 15:11:58 +00:00
33 lines
648 B
Docker
33 lines
648 B
Docker
FROM node:16-alpine3.14 as builder
|
|
|
|
WORKDIR /usr/src/app
|
|
|
|
RUN apk add --update-cache build-base python3 libheif vips-dev ffmpeg
|
|
|
|
COPY package.json package-lock.json ./
|
|
|
|
RUN npm ci
|
|
|
|
COPY . .
|
|
|
|
RUN npm run build
|
|
|
|
# Prod stage
|
|
FROM node:16-alpine3.14
|
|
|
|
WORKDIR /usr/src/app
|
|
|
|
RUN apk add --no-cache libheif vips ffmpeg
|
|
|
|
COPY --from=builder /usr/src/app/node_modules ./node_modules
|
|
COPY --from=builder /usr/src/app/dist ./dist
|
|
COPY --from=builder /usr/src/app/bin ./bin
|
|
|
|
COPY LICENSE /licenses/LICENSE.txt
|
|
COPY LICENSE /LICENSE
|
|
COPY package.json package-lock.json ./
|
|
COPY start-server.sh start-microservices.sh ./
|
|
|
|
VOLUME /usr/src/app/upload
|
|
|
|
EXPOSE 3001
|