Public documentation site for the AEGIS Orchestrator, built with Fumadocs on Next.js and deployed to Cloudflare Pages as a static export.
Install dependencies and start the dev server:
npm install
npm run devOpen http://localhost:3000 to view the site. Content lives in content/docs/ as .mdx files.
The site is exported as a fully static site (output: 'export' in next.config.ts). The build writes to the out/ directory:
npm run buildTo validate TypeScript and MDX types before building:
npm run types:checkRequires Wrangler v3+ and a Cloudflare account with Pages access.
# Install Wrangler globally if not already installed
npm install -g wrangler
# Authenticate with Cloudflare
wrangler login
# Build then deploy
npm run build
wrangler pages deploywrangler.toml is already configured:
name = "aegis-docs"
compatibility_date = "2025-01-01"
pages_build_output_dir = "out"Wrangler reads these values automatically — no extra flags needed.
-
In the Cloudflare Dashboard, go to Workers & Pages → Create → Pages → Connect to Git.
-
Select the
aegis-docsrepository. -
Set the following build settings:
Setting Value Framework preset Next.js (Static HTML Export) Build command npm run buildBuild output directory outNode.js version 20(set in Environment Variables asNODE_VERSION=20) -
Click Save and Deploy.
Subsequent pushes to main trigger automatic deployments.
Example workflow (.github/workflows/deploy.yml):
name: Deploy to Cloudflare Pages
on:
push:
branches: [main]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- run: npm ci
- run: npm run build
- uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
command: pages deploy out --project-name=aegis-docsAdd CLOUDFLARE_API_TOKEN (with Cloudflare Pages: Edit permission) to the repository secrets.
| Path | Description |
|---|---|
content/docs/ |
All MDX documentation content |
content/docs/meta.json |
Top-level navigation order |
app/docs/ |
Next.js documentation layout and page routes |
app/(home)/ |
Landing page route group |
lib/source.ts |
Fumadocs content source adapter |
source.config.ts |
Fumadocs MDX configuration and frontmatter schema |
wrangler.toml |
Cloudflare Pages deployment configuration |