Skip to content

Commit

Permalink
update deps
Browse files Browse the repository at this point in the history
  • Loading branch information
nimarion committed Oct 11, 2024
1 parent 5bb6cea commit e671241
Show file tree
Hide file tree
Showing 10 changed files with 8,730 additions and 12,962 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PhotoFinish Server is a platform designed for real-time publishing of photofinish images to the public. This system utilizes embedded metadata within the images to provide viewers with comprehensive information, including race results, reaction times, and windspeed, all seamlessly integrated with the image.

[Live Demo](https://photofinish.lcrehlingen.de/58.%20Pfingstsportfest_28052023)
[Live Demo](https://photofinish.lcrehlingen.de/pfingsten2024)



Expand Down
41 changes: 15 additions & 26 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,31 +1,20 @@
FROM node:20.11.0-bullseye-slim AS builder

FROM node:20-slim AS base
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable
COPY . /app
WORKDIR /app

COPY package*.json ./
COPY prisma ./prisma/

RUN npm install

COPY . .

RUN npm run build
FROM base AS prod-deps
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --prod --frozen-lockfile

FROM node:20.11.0-bullseye-slim

ARG BRANCH="main"
ARG COMMIT=""
LABEL branch=${BRANCH}
LABEL commit=${COMMIT}

ENV COMMIT_SHA=${COMMIT}
ENV COMMIT_BRANCH=${BRANCH}

COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package*.json ./
COPY --from=builder /app/dist ./dist
COPY --from=builder /app/prisma ./prisma
FROM base AS build
RUN --mount=type=cache,id=pnpm,target=/pnpm/store pnpm install --frozen-lockfile
RUN pnpm run build

FROM base
COPY --from=prod-deps /app/node_modules /app/node_modules
COPY --from=build /app/dist /app/dist
RUN apt-get update -y && apt-get install -y openssl
EXPOSE 3000

CMD [ "npm", "run", "start:migrate:prod" ]
CMD [ "pnpm", "start:migrate:prod" ]
Loading

0 comments on commit e671241

Please sign in to comment.