r/golang • u/BrilliantUseful2960 • 12h ago
Kera: a team AI chat as a single static Go binary (stdlib net/http, pgx, no ORM), embedded React app
Sharing a project that has run in production for us for a few weeks. The Go side may interest you:
CGO_ENABLED=0, a distroless image of ~28 MB, ~20 MB idle RSS.HTTP is stdlib
net/httpwith 1.22 route patterns. The database is pgx/v5 with hand-written SQL and goose migrations, so no ORM.Sessions and API keys use small in-repo code (
internal/auth,internal/ids) instead of JWT or UUID libraries.Every feature is its own package under
internal/with aMount(a *app.App)registered frominit(), so adding one is one package plus a blank import.Plugins are plain HTTP services (OpenAPI/MCP) rather than loaded code, which keeps the core small and crash-isolated.
The React/Vite app is built into
web/distand embedded withembed.Postgres is the only required service. Vectors (pgvector), full text and advisory locks do the jobs a queue or vector DB usually would.
Tests run with -race against a real Postgres per test (make testdb), and CI also runs govulncheck and gitleaks.
Code review of the architecture is welcome: https://github.com/cdmx-in/kera