From 7583e3c4ef491da8c083c36708dcd2ab1c800f0a Mon Sep 17 00:00:00 2001 From: Damien Laureaux Date: Tue, 29 Oct 2024 21:44:06 +0100 Subject: [PATCH] fix(docker): fix the Docker copy commands + change the source image to node:18-alpine --- backend.dockerfile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/backend.dockerfile b/backend.dockerfile index 36b23b7..9ac1c4c 100644 --- a/backend.dockerfile +++ b/backend.dockerfile @@ -2,7 +2,7 @@ # Build stage ############################# -FROM node:18-slim AS builder +FROM node:18-alpine AS builder WORKDIR /app @@ -20,7 +20,7 @@ RUN yarn install --frozen-lockfile --network-timeout 600000 && yarn build # Production stage ############################# -FROM node:18-slim +FROM node:18-alpine WORKDIR /app @@ -29,10 +29,10 @@ COPY --chown=node:node --from=builder /app/dist ./dist COPY --chown=node:node --from=builder /app/node_modules ./node_modules # Copy the rest of the application code -COPY --chown=node:node ./drizzle.config.ts ./ -COPY --chown=node:node ./tsconfig.json ./ -COPY --chown=node:node ./src/db/schema.ts ./src/db/schema.ts -COPY --chown=node:node ./package.json ./package.json +COPY --chown=node:node drizzle.config.ts ./ +COPY --chown=node:node tsconfig.json ./ +COPY --chown=node:node src/db/schema.ts ./src/db/schema.ts +COPY --chown=node:node package.json ./package.json # Create data directory & set permissions to node user RUN mkdir /app/data && \