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.4 kB · 43 lines
Dockerfile
at main
1234567891011121314151617181920212223242526272829303132333435363738394041424344# Build from monorepo root: docker build -f apps/webhook-service/Dockerfile .
# Stage 1: Install dependencies and compile binaryFROM 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/webhook-service ./apps/webhook-serviceCOPY 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.json
# Install dependenciesRUN bun install --frozen-lockfile
# Compile to a single binaryRUN NODE_ENV=production bun build --compile --minify apps/webhook-service/src/index.ts --outfile /app/webhook
# Stage 2: Minimal runtimeFROM alpine:3.22
RUN apk add --no-cache libstdc++ libgcc ca-certificates
COPY --from=builder /app/webhook /usr/local/bin/webhook
ENV NODE_ENV=production# The service itself defaults to loopback. Containers opt in to an unspecified# bind address so an orchestrator can reach the single bounded health endpoint.ENV HEALTH_HOST=0.0.0.0ENV HEALTH_PORT=3003
EXPOSE 3003
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:3003/health || exit 1
CMD ["webhook"]