Internal documentation wiki. Replaces Confluence / Notion. Markdown-first, page hierarchy with namespaces, full-text search, page history. The wiki you're reading is built on PMA's Wiki.js.
| Field | Value |
|---|---|
| Container | ${CONTAINER_PREFIX}wikijs |
| Image | requarks/wiki |
| Internal port | 3000 |
| External port | ${WIKIJS_PORT} (default 8082) |
| Database | PostgreSQL (shared wikijs-postgres container) |
| Storage | wikijs-data + wikijs-postgres-data volumes |
| Backup type | database + volume |
| Classification | enterprise |
| Profiles | enterprise, development, full |
| Default SSO | wikijs (custom — Wiki.js needs API-key bootstrapping) |
| Recipe | What it does |
|---|---|
just wikijs-status / -logs / -restart |
Lifecycle |
just wikijs-configure |
Regenerate API key + apply theming + Mermaid config |
just wikijs-content-upload |
Push markdown from packages/wikijs/scripts/content/pages/ to the live wiki |
just wikijs-content-pull |
Pull live wiki content back to local markdown |
just wikijs-psql [ARGS] |
Direct DB access |
The custom upload-pages.ts GraphQL uploader is the heart of the
content-as-code flow — markdown files in packages/wikijs/scripts/content/pages/
become wiki pages with path = file path minus .md.
# Edit a markdown page
$EDITOR packages/wikijs/scripts/content/pages/pma/learn/01-install-pma.md
# Upload to live wiki
just wikijs-content-upload
# Or for a single page:
bun packages/wikijs/scripts/upload-pages.ts pma/learn/01-install-pma
This is the workflow that powered the entire /asd, /pma, /essays
sections being added by writing markdown + running the uploader.
just wikijs-configure
# Regenerates ADMIN_API_KEY in .env + applies it inside the running container.
# Fixes the "API key expired" symptom after a long restart cycle.
This is the fix for ticket #3919 (stale API key after restart).
The post_start_init.ts hook now runs wikijs-configure automatically
on every start.
just wikijs-configure --mermaid
# Injects Mermaid 11 CDN + initialiser into the Code Injection slot
# (Wiki.js ships Mermaid 8 which can't render flowcharts well).
This is what release #3901 / #3921 fixed — Mermaid configuration as
a release-driven config-apply step, not a manual UI click.
just backup wikijs # snapshots DB + uploads volume
just restore wikijs latest # restore from most recent backup
# post_restore hook runs wikijs-configure to regenerate API key
PMA's wiki content follows a couple of conventions that make the
multi-author + auto-upload workflow safe:
pages/pma/learn/01.md → https://wiki/pma/learn/01./pma/... not ../pma/...). Wiki.js's relative-link rendering is brittle.~mermaid syntax to bypass Wiki.js's stale renderer; the Code Injection slot loads Mermaid 11 to render them.sso.type: wikijsWiki.js has its own SSO model that doesn't quite fit oauth or oidc.
PMA has a custom wikijs SSO type that:
just sso-check wikijs
just sso-fix wikijs # re-apply if drifted
First login via Authentik auto-provisions the user in Wiki.js with a default
"viewer" role; promote to "editor" or "admin" via the Wiki.js admin UI →
Groups → Add member.
Mermaid version. Wiki.js ships Mermaid 8. Modern Mermaid syntax (sequence diagrams with parallel arrows, etc.) needs Mermaid 11 via Code Injection — just wikijs-configure --mermaid applies it. Reapplied on every release via post_start_init.ts.
API key fragility. Wiki.js's API keys can be invalidated by certain admin UI actions (resetting auth providers, regenerating the master key). The post_start_init.ts hook (added in #3919) detects this and re-issues a fresh key automatically.
Search index lives in PG. Wiki.js full-text search is Postgres tsvector, not Elasticsearch. Index updates are real-time on page edit. Fast for <50K pages.
Page rendering is cached aggressively. After uploading new content, refresh the page in the browser; the cached render can lag by ~30s.
The home page is special. / → loads home.md. Set this in Admin UI → General → Site Title + Default Home Page.
Page hierarchy doesn't auto-generate sidebar. Wiki.js v2 needs explicit section landing pages (.md files at each level) for the menu to navigate into subdirectories. This is the issue solved during the /asd + /pma rebuild — every top-level subfolder has a landing page.
| Symptom | First check |
|---|---|
"Cannot read theming config: Forbidden" on just wikijs-configure |
Stale API key; just wikijs-configure regenerates |
| Pages don't appear in nav after upload | Section landing page missing; create <section>.md at parent level |
| Mermaid blocks render as raw code | Code Injection slot missing Mermaid 11; just wikijs-configure --mermaid |
| Search returns nothing | Postgres tsvector index stale; force reindex via Admin UI |
| 502 from Caddy | Container unhealthy; just wikijs-logs |
/structure — full map of the wiki content (all 139 pages)./pma/cookbook/upgrade-a-service-safely — Wiki.js version bumps./pma/reference/cli/backup — DB + volume backup.