Skip to content

System Overview

The site has two moving parts: a static VitePress build, and a Node process that gates access to it and provides a CMS.

Build-time: VitePress

pnpm run docs:build reads every Markdown file under docs/ and produces a static site in docs/.vitepress/dist. This step never talks to a database or a network service.

Content source

All content lives as Markdown files tracked in Git — there is no database backing the page content, even with the CMS in place. See the Users and access section below for what the CMS's database actually stores.

bash
pnpm run docs:build

Run-time: the cms app

A single Node process (managed by PM2 as logicton-docs-cms) does the rest:

PathHandled byPurpose
/admin/**, /api/**PayloadCMS admin panel and REST/GraphQL API
/loginCustom pageSigns in against POST /api/users/login
everything elseCustom route handlerAuth check, then serves docs/.vitepress/dist

TIP

Because the route handler reads docs/.vitepress/dist from disk on every request, a content-only change (edit .md, rebuild) does not require a PM2 restart.

Access control

The Users collection is the only data Payload stores in its own database (SQLite). Document content is never duplicated into that database — the CMS's markdown editor reads and writes the same .md files that Git tracks.

WARNING

Users.access.create only allows an already-authenticated admin to create new accounts. There is no public sign-up — an admin provisions every new account from /admin.

Request flow diagram

See Deployment for the exact commands that build and restart this process.