mirror of
https://github.com/immich-app/immich.git
synced 2024-12-25 10:43:13 +02:00
70a0f4ae48
* chore: update to node 18 and alpine 3.17 Signed-off-by: martin <martin.labat92@gmail.com> * chore: fix sharp version Signed-off-by: martin <martin.labat92@gmail.com> * chore(server): use vips-dev Signed-off-by: martin <martin.labat92@gmail.com> * update checkDiskUsage Signed-off-by: martin <martin.labat92@gmail.com> * fix: use vips-heif instead of libheif Signed-off-by: martin <martin.labat92@gmail.com> * fix: use vips instead of vips-cpp Signed-off-by: martin <martin.labat92@gmail.com> * fix: ensure vips installation Signed-off-by: martin <martin.labat92@gmail.com> --------- Signed-off-by: martin <martin.labat92@gmail.com>
41 lines
647 B
Docker
41 lines
647 B
Docker
# Our Node base image
|
|
FROM node:18-alpine3.17 as base
|
|
|
|
WORKDIR /usr/src/app
|
|
EXPOSE 3000
|
|
RUN apk add --no-cache setpriv
|
|
|
|
FROM base as builder
|
|
|
|
RUN chown node:node /usr/src/app
|
|
|
|
COPY --chown=node:node package*.json ./
|
|
|
|
RUN npm ci
|
|
|
|
COPY --chown=node:node . .
|
|
|
|
EXPOSE 3000
|
|
|
|
FROM builder AS dev
|
|
ENV CHOKIDAR_USEPOLLING=true
|
|
EXPOSE 24678
|
|
CMD ["npm", "run", "dev"]
|
|
|
|
FROM builder AS prod
|
|
|
|
RUN npm run build
|
|
RUN npm prune --omit=dev
|
|
|
|
FROM base
|
|
|
|
ENV NODE_ENV=production
|
|
|
|
WORKDIR /usr/src/app
|
|
|
|
COPY --from=prod /usr/src/app/node_modules ./node_modules
|
|
COPY --from=prod /usr/src/app/build ./build
|
|
|
|
COPY package.json package-lock.json ./
|
|
COPY entrypoint.sh ./
|