Files
..
2026-06-10 19:34:50 +09:00
2025-09-29 16:59:55 +09:00
2025-11-26 17:01:48 +09:00
2025-11-26 17:01:48 +09:00
2025-09-29 16:59:55 +09:00
2025-09-29 16:59:55 +09:00
2026-03-09 11:41:24 +00:00
2025-09-29 16:59:55 +09:00

Status Network Website

This is the source for https://status.network a Next.js project with static export.

Prerequisites

From the repo root, install dependencies and submodules:

pnpm install
git submodule update --init --recursive apps/status.network/content/legal-external

Environment

Blog and static export need Ghost Content API credentials.

cd apps/status.network
cp .env.example .env.local
# Fill GHOST_API_KEY and NEXT_PUBLIC_GHOST_API_KEY (same value)

Or pull from Vercel:

cd apps/status.network
vercel env pull .env.local
Variable Required Purpose
GHOST_API_URL yes Server fetch at build/dev
GHOST_API_KEY yes Pre-render /blog pages from live Ghost data
NEXT_PUBLIC_GHOST_API_URL yes (same URL as GHOST_API_URL) Client refresh after deploy
NEXT_PUBLIC_GHOST_API_KEY yes (same value as GHOST_API_KEY) Client refresh after deploy

pnpm env:check validates env vars from .env.local (runs automatically before pnpm build). When Ghost is unavailable at build time, /blog/[slug] routes fall back to the committed slug list in content/network-blog-slugs.json (update that file when new posts ship).

Development (next dev)

Middleware and i18n run normally (no static export in dev).

cd apps/status.network
pnpm dev

Open http://localhost:3002.

Without Ghost env vars, marketing pages work; /blog lists no posts and client refresh is skipped.

Production-like local preview (static export)

Simulates Jenkins self-hosted output: next buildout/ → static file server.

cd apps/status.network
pnpm preview:production

This runs prebuild (env check + legal dates), build, sitemap, locale stripping, copies serve.json into out/, then serves on http://localhost:3002.

Stop pnpm dev first if port 3002 is already in use (otherwise serve picks another port).

Steps separately:

pnpm build   # writes to out/
pnpm start   # serve out/ on port 3002

Deploying

Deployment is handled via Jenkinsfile.website. Jenkins reads the Ghost API key from the status-network-ghost-api-key secret-text credential and passes it via withCredentials / withEnv (not the shell command line) when building status.network.