# The hub's API. Build from the repository root: docker build -f apps/api/Dockerfile . FROM oven/bun:1.4.4-slim AS deps WORKDIR /app COPY package.json bun.lock ./ COPY apps/api/package.json apps/api/ COPY apps/web/package.json apps/web/ COPY packages/db/package.json packages/db/ # Hoisted, so everything (the workspace packages too) is in the node_modules copied below; Bun's default isolated # layout keeps links in each package's own node_modules. RUN bun install --frozen-lockfile --production --filter @t5de/api --linker hoisted FROM oven/bun:1.4.4-slim WORKDIR /app ENV NODE_ENV=production PORT=4101 COPY --from=deps /app/node_modules ./node_modules COPY packages/db ./packages/db COPY apps/api ./apps/api USER bun EXPOSE 4101 CMD ["bun", "apps/api/src/index.ts"]