forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on mainFiltered to compose.yamlClear filter

2026-09-23

✨ feat: school identity is the uuid; drop the slugAhmet Kaan Gümüş · 2918040
✨ feat: school identity is the uuid; drop the slug

The school slug is gone from every surface: the session cookie prefix,
the /schools/{id} builder routes, FILES_PATH blob dirs, the hab/2 frame
school value, DTOs, and the /limits contract. SchoolId::try_parse is the
one wire parse (hyphenated uuid only); a non-uuid frame school answers
unknown_school. Register gets a public picker via the new unauthenticated
GET /auth/schools returning active [{id, name}]. The control migration
drops school_slug and the slug column, which invalidates every existing
session — old cookie prefixes cannot resolve.
Local-Gate: 3fafffd98aec59c68e2606833b87785d0abf2fee (1510 passed, 425s)

2026-09-14

🔧 chore: underscore names hezarfen_backend_*Ahmet Kaan Gümüş · 6fecf55
🔧 chore: underscore names hezarfen_backend_*

Containers, image, volumes, and the compose user unit follow the crate
name. Hyphenated leftovers (hezarfen.service, hezarfen-compose.service)
are disabled on deploy.
✨ feat: compose-stack deploy plus in-tree schema workAhmet Kaan Gümüş · 57fad2c
✨ feat: compose-stack deploy plus in-tree schema work

Production deploy is podman compose (postgres + backend + openobserve)
instead of a systemd binary. CI stays a throwaway postgres sidecar.
Operator credentials live in ~/hezarfen_backend/hezarfen_backend.env
(0600); the deploy never writes that file.

Also lands the working-tree schema/junction and .sqlx updates that were
already sitting next to this change.
🔧 chore: default HTTP bind port 7656Ahmet Kaan Gümüş · 81ac0fb
🔧 chore: default HTTP bind port 7656

Unset PORT now binds 7656 instead of 8080: parse_port, the
user unit, compose, Containerfile, CI health-gate fallback,
and README.

2026-09-12

2026-09-07

✨ feat: OpenObserve replaces Temps as the telemetry sinkAhmet Kaan Gümüş · 5a1ac42
✨ feat: OpenObserve replaces Temps as the telemetry sink

Temps needed a container socket to even start its console, plus a
TimescaleDB and a ClickHouse of its own — three services, a locally
built image and a socket mount for one dev sink. OpenObserve is one
Rust binary with its own storage: no socket, no sidecars, retention
per stream in days.

compose.yaml drops temps/temps-postgres/temps-clickhouse and their
volumes for a single `openobserve` service on
docker.io/openobserve/openobserve:v1.0.0-rc2, UI + API + OTLP/HTTP on
127.0.0.1:5080 and OTLP/gRPC on 127.0.0.1:5081, ZO_DATA_DIR=/data on
the openobserve-data volume, ZO_COMPACT_DATA_RETENTION_DAYS=90, root
user admin@hezarfen.local (local-dev password, and OpenObserve panics
at boot on anything weaker than upper+lower+digit+special). The
backend's commented OTEL_* block now carries the gRPC form ready to
uncomment and the OTLP/HTTP variant beside it.

Proved end to end against the real backend over OTLP/gRPC: 18 spans
(GET /health ×11, GET /modules/catalog ×5, POST /builder/login,
GET unmatched), the http_server_request_duration metric family and 11
log records, all timestamped 2026-09-07 rather than 1970. Privacy
check over every span and log attribute key found none of the banned
set (url.path, client.address, user_agent.original, user.*, cookie,
email, http.*.header.*); no username and no IP but 127.0.0.1 in any
body.

Claude-Session: https://claude.ai/code/session_018sqvyBCZ9kpQP6vnGomT2s
✨ feat: Temps telemetry sink in composeAhmet Kaan Gümüş · 849155e
✨ feat: Temps telemetry sink in compose

Temps is the only telemetry sink here (no Grafana). It brings its own two
stores: TimescaleDB for metadata and logs, ClickHouse for spans and metrics.
Neither is published; only the dashboard (3000) and the public ingest
listener (9000) are, both on loopback.

The published image cannot run: ghcr.io/gotempsh/temps:* is alpine/musl but
the binary inside is glibc-linked, so it exits with "exec container process
(missing dynamic library?)". Upstream's supported path is a from-source
build of the whole thing; observability/Containerfile.temps rebases the same
pinned artifact onto debian-slim instead, which takes seconds.

Ingest is OTLP/HTTP protobuf only — no gRPC listener — and the path is
/api/otel/v1/{traces,metrics,logs}, authorised by an API key plus the
project id header. Raw signals are pinned to 90 days, because the ClickHouse
span TTL defaults to 90 while the plugin config defaults to 7.

Verified: a trace, a metric and a log record sent with the OTLP exporter all
land and come back out of the query API.

Claude-Session: https://claude.ai/code/session_018sqvyBCZ9kpQP6vnGomT2s

2026-09-05

📝 docs: multi-school model in the README, builder seed in composeAhmet Kaan Gümüş · 78fe8c7
📝 docs: multi-school model in the README, builder seed in compose

New `## Multi-school (SaaS)` section; the auth prose, quick tour, first-admin
bootstrap and layout follow the per-school databases and the builder API.

2026-07-23

📦 chore(compose): enable the AI bridge listenerAhmet Kaan Gümüş · 87c8096
📦 chore(compose): enable the AI bridge listener

The bridge listening with no service connected is a working state, not a
broken one: chat answers 503 until something registers `chat.reply`, and
the port has to be up before a service can dial in at all. QUIC is UDP,
so the mapping needs the /udp suffix — a TCP publish looks correct and
never receives a packet.

AI_SHARED_TOKEN keeps its local-dev value; it is only a real secret once
8090 is reachable from anywhere but the host.
✨ feat(ai): QUIC bridge for out-of-process AI servicesAhmet Kaan Gümüş · dc49954
✨ feat(ai): QUIC bridge for out-of-process AI services

The AI features live in separate projects, so they need a transport. QUIC:
each request rides its own bidirectional stream on the service's single
long-lived connection, which puts multiplexing in the transport — no
correlation-id bookkeeping, no head-of-line blocking between concurrent
requests, one handshake instead of one per request.

The backend listens and the services dial in, so a service can sit behind
NAT, restart without the backend knowing its address, and scale out by
opening a second connection (each connection is an independent worker).

Protocol "hab/1", also the ALPN so an incompatible service is refused at the
TLS handshake rather than one frame later. Frames are length-prefixed JSON
(u32 big-endian) because the services will not be Rust; the length is checked
against an 8 MiB cap before any buffer is allocated. The control stream
carries Hello/Greeting and then stays open — its closure is the goodbye, so
there is no heartbeat frame, and a silent death is caught by the QUIC idle
timeout.

Routing is least-inflight rather than round-robin: AI request costs are
wildly uneven, and taking turns would pile a second long inference onto a
busy worker while an idle one sits next to it. Selection and the in-flight
increment happen under one lock so concurrent dispatches cannot overshoot a
worker's declared max_concurrent, which a Lease releases on drop.

Services authenticate with a shared token (constant-time compare); the
certificate only proves the backend, and is self-signed at boot unless a PEM
pair is configured. Since that regenerates per boot, GET /ai/certificate
publishes it (PEM + sha256) for a service to pin — public because a server
certificate is handed to every peer in the TLS handshake anyway, and 404 when
the bridge is off. A service must re-fetch on every reconnect, not once at
startup.

Off unless AI_QUIC_ADDR is set, so the API is unchanged for deployments
without AI. Set without AI_SHARED_TOKEN it refuses to boot rather than listen
unauthenticated.

2026-07-22

2026-07-21

✨ feat(db)!: swap embedded surrealkv for a SurrealDB serverAhmet Kaan Gümüş · 60b4509
✨ feat(db)!: swap embedded surrealkv for a SurrealDB server

BREAKING CHANGE: the backend no longer opens a database file. DB_PATH
is gone; DB_URL/DB_USER/DB_PASS point at a SurrealDB server over
WebSocket (compose ships one on surrealkv storage in its own volume,
backend waits on its healthcheck). Pre-switch data was wiped on
purpose — fresh volumes seed from scratch. Tests keep the in-memory
engine; persistence.rs re-runs the boot migration on a live handle
instead of reopening a file.

2026-07-15

✨ feat(notes): file attachments with school-set size capAhmet Kaan Gümüş · f1b532b
✨ feat(notes): file attachments with school-set size cap

Blobs live on disk under FILES_PATH (same volume as the DB), named by
the row's ULID so user input never shapes a path; the note_file row
keeps only metadata. DB-blob storage rejected: multi-MB PDFs bloat
surrealkv's LSM tree and buffer whole in RAM on every read.

- POST/GET /notes/{id}/files, GET/DELETE /notes/{id}/files/{file_id};
  owner-only through the owning note, staff included
- max_file_bytes in settings (1 KiB-25 MiB hard cap, default 5 MiB),
  enforced on streamed bytes (413), inside the settings CAS guard;
  option<int> so pre-field volumes boot without a backfill
- 10 files per note; deleting a note removes rows first, blobs after,
  so a crash strands at worst an unreachable blob

2026-07-11

✨ feat(admin): seed an admin account at startupAhmet Kaan Gümüş · ea497d9
✨ feat(admin): seed an admin account at startup

ADMIN_USERNAME and ADMIN_PASSWORD (both-or-neither; half a pair aborts
boot, blank counts as unset) create an admin at startup when the
username doesn't exist. The seed is idempotent and never rewrites
credentials: an existing admin is left as-is, and a non-admin holding
the name is never promoted — that would be a privilege escalation, so
it only logs a warning pointing at the out-of-band paths.

compose.yaml ships local-dev credentials for first boot; .env.example
documents the knob.
📦 chore(docker): two-stage Containerfile and compose stackAhmet Kaan Gümüş · a6d34e6
📦 chore(docker): two-stage Containerfile and compose stack

The Containerfile builds a release binary (with cargo registry + target
cache mounts) on the pinned Rust stable that edition 2024 needs, then
copies it onto a slim Debian runtime that runs as a non-root user. HOST
is forced to 0.0.0.0 so the published port reaches the listener, and
the embedded database lives under /data for a volume mount.

compose.yaml runs the single service (the DB is embedded) with a named
data volume, a curl-based healthcheck on /, and the production knobs
commented out. .dockerignore trims the build context to source +
manifests. Works with both podman and docker compose.