Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/openstatusHQ/openstatus. ๐ซ Status page with uptime monitoring & API monitoring as code ๐ซ openstatus.dev
bun drizzle-orm monitoring monitoring-as-code nextjs observability on-call open-source shadcn-ui status-page statuspage synthetic-monitoring tinybird turso uptime uptime-checker uptime-monitor
Something went wrong. Try again.
3.5 kB ยท 122 lines
YAML
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123builders: # Stage 1: collect every workspace manifest (package.json) into a tree that only # changes when a manifest changes. The install stage copies from here, so its # layer cache key depends on manifests + lockfile alone, not on source edits. manifests: fromImage: node:24-slim workdir: /app copy: - . /app/ run: - mkdir -p /out - cp pnpm-workspace.yaml pnpm-lock.yaml package.json /out/ - find apps packages -name package.json -not -path '*/node_modules/*' -exec cp --parents {} /out/ \;
# Stage 2: install the dashboard dependency subgraph (dev deps included โ next build needs them). # Cached across builds as long as no package.json / pnpm-lock.yaml changed. install: fromImage: node:24-slim workdir: /app env: PNPM_HOME: /pnpm PATH: $PNPM_HOME:$PATH copy: - fromBuilder: manifests source: /out/ target: /app/ run: - corepack enable pnpm - pnpm install --frozen-lockfile --filter=@openstatus/dashboard...
# Stage 3: Next.js build with Node.js builder: fromImage: node:24-slim workdir: /app copy: - . /app/ - fromBuilder: install source: /app/node_modules target: /app/node_modules - fromBuilder: install source: /app/apps/dashboard/node_modules target: /app/apps/dashboard/node_modules - fromBuilder: install source: /app/packages target: /app/packages env: NODE_ENV: production PNPM_HOME: /pnpm PATH: $PNPM_HOME:$PATH # Build-time environment variables (placeholder values, overwritten by .env.docker at runtime) DATABASE_URL: http://libsql:8080 DATABASE_AUTH_TOKEN: test NEXT_PUBLIC_OPENPANEL_CLIENT_ID: test NEXT_PUBLIC_URL: http://localhost:3002 TEAM_ID_VERCEL: test PROJECT_ID_VERCEL: test VERCEL_AUTH_BEARER_TOKEN: test OPENPANEL_CLIENT_SECRET: test RESEND_API_KEY: test UPSTASH_REDIS_REST_URL: https://test.upstash.io UPSTASH_REDIS_REST_TOKEN: test UNKEY_TOKEN: test UNKEY_API_ID: test TINY_BIRD_API_KEY: test CRON_SECRET: test STRIPE_SECRET_KEY: test AUTH_SECRET: build-time-placeholder-min-32-chars-long SELF_HOST: "true" NEXT_PUBLIC_SELF_HOST: "true" run: - corepack enable pnpm - pnpm turbo run build --filter=@openstatus/dashboard
# Runtime stagefromImage: node:24-slimworkdir: /app/apps/dashboard
# Copy artifacts from buildercopy: # Copy Next.js standalone output - fromBuilder: builder source: /app/apps/dashboard/.next/standalone/apps/dashboard/ target: ./ chmod: "555" # Copy root node_modules (required for pnpm symlinks) - fromBuilder: builder source: /app/node_modules/ target: /app/node_modules/ # Copy static assets - fromBuilder: builder source: /app/apps/dashboard/.next/static/ target: ./.next/static/ # Copy public directory - fromBuilder: builder source: /app/apps/dashboard/public/ target: ./public/
# Install curl for health checksroot: run: - apt-get update - apt-get install -y --no-install-recommends curl - rm -rf /var/lib/apt/lists/*
# Security: run as non-root useruser: "1000:1000"
# Expose portexpose: "3000"
# Health checkhealthcheck: interval: 30s timeout: 10s start: 45s retries: 3 cmd: curl -f http://localhost:3000/ || exit 1
# Start applicationcmd: - node - server.js