FROM oven/bun:1.3.11

WORKDIR /app

ENV NODE_ENV=production

COPY --from=workspace package.json ./package.json
COPY --from=workspace bun.lock ./bun.lock
COPY --from=workspace tsconfig.base.json ./tsconfig.base.json
COPY --from=services . ./services
COPY --from=packages . ./packages
COPY --from=apps . ./apps

RUN bun install --frozen-lockfile

ENTRYPOINT ["bun"]
