System Overview
Components
Request flow
- Browser requests
wiki.bincio.org/entries/some-page/.
- nginx serves the pre-built static HTML from
/var/www/bincio-wiki/.
- The page's inline JavaScript calls
GET /api/me on load. nginx proxies this to FastAPI.
- If FastAPI returns 401/403 (no valid session), JS redirects to
/login/.
- On a page edit, the browser
POST /pages/{slug} with new Markdown content. FastAPI writes the file, runs git commit, then POST /rebuild triggers astro build --force.
- nginx serves the rebuilt static output immediately on next request.
Technology stack
| Layer |
Technology |
| Frontend framework |
Astro 6 (static output) |
| CSS |
Tailwind CSS |
| Interactive editor |
Svelte (PageEditor component) |
| Markdown extensions |
remark-wikirefs, remark-caml |
| Wikibonsai integration |
Custom TypeScript (site/src/wikibonsai/) |
| API / sidecar |
FastAPI + uvicorn |
| Python packaging |
uv |
| Database |
SQLite (shared with bincio_activity) |
| Passwords |
bcrypt |
| VCS |
Git (two bare repos on VPS) |
| Web server |
nginx + Let's Encrypt (Certbot) |
| Process manager |
systemd |
| VPS |
Hetzner, Debian 12 |
Port map
| Port |
Service |
| 443 |
nginx (HTTPS, wiki.bincio.org) |
| 4042 |
bincio-wiki FastAPI (production) |
| 8001 |
bincio-wiki FastAPI (local dev) |
| 4321 |
Astro dev server (local dev only) |
| 4041 |
bincio_activity FastAPI |