Something went wrong. Try again.
Monorepo for wisp.place. A static site hosting service built on top of the AT Protocol.
Something went wrong. Try again.
1.2 kB · 38 lines
Dockerfile
at main
123456789101112131415161718192021222324252627282930313233343536373839# Build from monorepo root: docker build -f apps/preview-bot/Dockerfile .
# Stage 1: Install dependencies and compile binaryFROM docker.io/oven/bun:1.4.2-alpine AS builder
WORKDIR /app
# Copy workspace configuration filesCOPY package.json bun.lock tsconfig.json ./COPY patches ./patches
# Copy all workspace packages (needed for workspace: dependencies)COPY packages ./packagesCOPY apps/preview-bot ./apps/preview-botCOPY apps/main-app/package.json ./apps/main-app/package.jsonCOPY apps/hosting-service/package.json ./apps/hosting-service/package.jsonCOPY apps/firehose-service/package.json ./apps/firehose-service/package.jsonCOPY apps/webhook-service/package.json ./apps/webhook-service/package.json
# Install dependenciesRUN bun install --frozen-lockfile
# Compile to a single binaryRUN NODE_ENV=production bun build --compile --minify apps/preview-bot/src/index.ts --outfile /app/preview-bot
# Stage 2: Minimal runtimeFROM docker.io/alpine:3.22
RUN apk add --no-cache libstdc++ libgcc ca-certificates
COPY --from=builder /app/preview-bot /usr/local/bin/preview-bot
ENV NODE_ENV=productionENV PORT=3004
EXPOSE 3004
CMD ["preview-bot"]