Skip to content

Docs Site

This site is an Astro Starlight static site in its own repository, Level147/docs.level147.net. It builds on every push to main and deploys to docs.level147.net via Cloudflare Pages.

How it works

docs.level147.net repo (Astro project root)
├── astro.config.mjs ← sidebar + site config
├── .woodpecker.yml ← build + deploy pipeline
└── src/
├── content.config.ts
└── content/docs/ ← all .md/.mdx files here auto-build

Starlight’s docsLoader() recursively discovers every .md and .mdx file under src/content/docs/. No registration needed — drop a file in and push.

Adding a page

  1. Create a .md file anywhere under src/content/docs/
  2. Add required frontmatter:
    ---
    title: My Page
    description: Optional description shown in search results.
    ---
  3. Commit and push to main — CI builds and deploys automatically

The sidebar is configured manually in astro.config.mjs. New pages won’t appear in the sidebar until you add an entry there:

astro.config.mjs
sidebar: [
{
label: 'My Section',
items: [
{ label: 'My Page', link: '/my-section/my-page' },
],
},
]

Excluded content

Only files under src/content/docs/ are published. To keep a directory unpublished (e.g. internal notes), place it outside src/content/docs/ — Starlight’s loader will not pick it up.

Deployment

Deploys via Wrangler direct upload from Woodpecker CI — not CF Pages Git integration (CF Pages can’t pull from self-hosted Gitea).

SettingValue
CF Pages projectlevel147-docs
CF accounte564ade2903ed6f18c70a38a5d411f15
Custom domaindocs.level147.net
CI pipeline.woodpecker.yml (repo root)
TriggerPush to main, or manual

The Woodpecker pipeline:

  1. Clones the repo (default authenticated clone — this is a private repo)
  2. Runs npm ci && npm run build
  3. Runs npx wrangler pages deploy dist --project-name=level147-docs

Requires the CLOUDFLARE_API_TOKEN secret in Woodpecker (permission: Account → Cloudflare Pages: Edit).

The pages.dev domain is disabled on the CF Pages project. Access is restricted via Cloudflare Zero Trust → Access — only authenticated staff can reach docs.level147.net.

Theme

The visual theme is a port of the AI Studio control-surface design language:

FilePurpose
src/styles/tokens.cssDesign tokens — colours, shadows, geometry
src/styles/starlight.cssMaps --sl-* Starlight variables to tokens + component overrides

The dark/light scheme is driven by [data-theme="dark"] / [data-theme="light"] on <html>. Section accents (--accent) can be set per-page via data-section="ops|consulting|admin" on the body.

Local development

Terminal window
npm install
npm run dev # dev server at http://localhost:4321
npm run build # production build into dist/
npm run preview # serve the built output locally

v0.1.0 · d0d7a20 · 2026-06-26