alvis 752d31475c ai: restore the quota probe on Codex, rewrite the footer
The Codex migration left /usage returning 501 and no quota signal for the
governor. Codex does expose one after all — it just isn't an HTTP endpoint.

Probe: `codex app-server` is a JSON-RPC-over-stdio surface whose
`account/rateLimits/read` returns the same snapshot the interactive TUI
shows. Handshake is initialize -> `initialized` NOTIFICATION -> read; without
the notification the read never answers. adolf-llm's /usage now drives that
and normalises the result.

Shape change, and why the consumers had to be rewritten rather than repointed:
Kimi reported fixed buckets (window_5h / weekly / window_7d). Codex reports up
to two plan-defined windows, `primary` (long) and `secondary` (shorter burst,
often null), so the payload is now {plan, pct, primary, secondary,
limit_reached} with each row as {pct, window_mins, window_label, resets}. `pct`
is the max across live windows — the single number a gate can read without
knowing which window binds.

Probing spawns a codex process (~2s), so results are cached in memory and on
the workspace volume with a 5min TTL, concurrent probes are de-duped, and a
failed refresh serves the last good reading tagged stale/as_of/age_s rather
than nothing. ?force=1 bypasses the TTL.

kimi-quota-footer-plugin -> codex-quota-footer-plugin (id, mount path and the
openclaw.json entry key all renamed together — they must agree or the plugin
silently fails to load). It now renders whatever windows the plan actually
has, shortest first, and flags limit_reached and stale readings. quota-command
updated for the same payload.

Verified: /usage returns live data (30d 4%, plan free), warm cache serves in
17ms vs ~2s cold, the gateway reaches the route, adolf loads
codex-quota-footer, and the formatter degrades to no footer on empty/null
payloads instead of breaking the reply.

Note: the account reports planType "free", not a paid ChatGPT plan.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Y5QPagv4iun1ghpwM96Ff
2026-08-01 08:19:35 +00:00
2026-03-05 11:22:34 +00:00
2026-03-17 03:06:18 +00:00
2026-03-05 11:22:34 +00:00

agap_git — Agap Server Configuration

agap_git is the configuration repo for Agap, the self-hosted home server. It holds:

  • docker-compose files for services running on Agap
  • host-level config: Caddy (Caddyfile), backup/install scripts, .env files

Convention: a Dockerfile, application source, or anything you'd build: from an image belongs in the service's own Gitea repo — not here. agap_git keeps the compose file that runs the resulting image, plus whatever config the compose needs. Third-party services (pulling a public image) live here in full, since there's no source to split out.

Self-developed services

Services with source written in-house are meant to be dual: source lives in their own Gitea repo, and the compose that runs them is described here.

Service Own repo Compose in agap_git
matrixbot (Matrix bot, Adolf channel adapter) alvis/matrixbot not present — runs from ~/matrixbot/docker-compose.yml in its own repo
moodtracker alvis/moodtracker not present — runs from ~/moodtracker/docker-compose.yml
marketplace-mcp alvis/marketplace-mcp not present — runs from ~/marketplace-mcp/docker-compose.yml
oO alvis/oO not present — runs from oO/infra/docker/docker-compose.yml; oO was already a fully separate project before this convention existed
mood (mood-archive) none yet fully vendored here (mood/, source + compose) — Kanboard #209 will extract it to its own repo

Known gap: the convention calls for compose to be described in agap_git and source to live in its own repo. For matrixbot / moodtracker / marketplace-mcp / oO, extraction (kb#78) moved the compose file along with the source into each new repo, so agap_git currently has zero footprint for these four — no compose, no config. Not fixed in this doc-only pass; flagged for a follow-up decision: either copy each compose back into agap_git, or formally amend the convention to let self-developed services keep compose in their own repo.

Third-party services (compose lives here in full)

Directory Service Port
immich-app/ Immich — photo management 2283
gitea/ Gitea — git hosting + Postgres 3000, 222
openai/ Adolf (OpenClaw gateway) + LiteLLM + Hindsight + Qdrant + Langfuse + Whisper/TTS stack see openai/docker-compose.yml (adolf-llm on 8010)
adolf/ Adolf config only (openclaw.json, design docs) — the adolf compose service lives in openai/docker-compose.yml; the OpenClaw fork source is a separate tree at ~/adolf
vaultwarden/ Password manager 8041
kanboard/ Kanban board, task orchestration for the claude bot 4800
seafile/ File sync, OnlyOffice, WebDAV (multiple compose files) 8078 (server), 8077 (Caddy)
matrix/ Synapse homeserver + coturn + LiveKit (not the matrixbot bot — see above)
overleaf/ LaTeX editor (ShareLaTeX/Overleaf CE)
linkwarden/ Bookmark manager 3012
vikunja/ Task manager 3457
radicale/ CalDAV/CardDAV server 5232
ntfy/ Push notifications 8840
syncthing/ File sync 8384
qbittorrent/ Torrent client 8085
searxng/ Metasearch engine 11437
ollama/ Local LLM runtime 11436
openwebui/ AI chat UI 3125
anki/ Anki sync server 8180
family/ MediaWiki (family wiki) 8099
freshrss/ RSS reader 8091
iperf3/ Network throughput testing 8095
otter/ OtterWiki 8083
agap-mcp/ MCP tool server for Claude (Node/Express) — vendored source, no separate repo 3100
personal-sensing/ SQLite store + schema for HA/Health Connect data (no compose; library used by an ETL, see kb#207)

Removed / moved out

  • windows/ — removed (kb#82): no VM, no container, dead config.
  • zabbix/, haos/ — moved to alvis/lizacer (kb#81). Zabbix runs on the lizacer server (192.168.1.4:81), not Agap.

Top-level files

  • Caddyfile — reverse proxy / TLS routing for all services
  • nvidia-docker-install.sh, install-cuda.sh — GPU host setup
  • users-backup.sh — host user backup

Quick Start

Each service is standalone; from its directory:

docker compose up -d
docker compose restart
docker compose logs -f
docker compose pull

The root docker-compose.yml is an alias that includes immich-app/docker-compose.yml.

Storage

  • /mnt/media/upload — Immich originals
  • /mnt/ssd1/media/ — Immich thumbnails, encoded video, Postgres
  • /mnt/misc/gitea — Gitea repositories and data

GPU Support

For GPU acceleration (Ollama/Open WebUI, Immich ML):

  1. sudo ./nvidia-docker-install.sh — Docker + NVIDIA Container Toolkit
  2. ./install-cuda.sh — CUDA toolkit

Documentation

See CLAUDE.md for developer instructions, credentials handling, and Gitea/Zabbix/Home Assistant API integration details.

See the Gitea wiki for infrastructure documentation (storage, network, per-service setup).

Description
No description provided
Readme 8.1 MiB
Languages
JavaScript 49%
Python 39.8%
Shell 6.9%
Dockerfile 1.8%
HTML 1.5%
Other 1%