Repository navigation
feat(k8s): speaker deploy, app settings that survive redeploys, and an accurate k8s guide - #357
Merged
AnkushMalaker merged 8 commits intoNov 9, 2026
Conversation
The backend container's start-k8s.sh started a full worker fleet alongside the workers sidecar, so both fleets transcribed every session. When the sidecar is enabled, the backend container now runs only the API, and the separate workers Deployment is not rendered. - Mount defaults.yml and config.yml from chronicle-config; drop the mem0 CA - Use the Recreate strategy for the ReadWriteOnce data volume - Add a production WebUI image built from the repository root - Add a Tailnet ingress for the backend and WebUI - Map speaker image COMPUTE_MODE values to the current uv extras - Write generated secrets owner-only and ignore generated manifests Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The k8s image now carries Node 22.19, Pi 0.85.1 and ripgrep, so Timeline analysis and the memory agents can run. The backend chart accepts hostAliases for Tailnet hosts that cluster DNS cannot resolve. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tenv The backend crashlooped on the cluster because the Mongo URI had no credentials. The URI now takes the password from chronicle-secrets via Kubernetes $(MONGO_ROOT_PASSWORD) expansion, so it never enters Helm values. The config generator targets now use `uv run --with python-dotenv`, because the repo root has no project environment to install it into. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The speaker profile builds amd64 images with a Skaffold custom builder (scripts/k8s/buildx-push.sh) on a configurable buildx builder, so it works from an arm64 build machine. COMPUTE_MODE selects the torch build: cu126 keeps Pascal GPUs, which cu128 drops. make config-k8s now regenerates skaffold.env from config.env, so a stale copy cannot override it. The backend reaches the service at its in-cluster address. The WebUI build context now includes chronicle-espresso-preset.js. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A ConfigMap is read-only, so the Settings page could not save on Kubernetes. The backend and workers now use CONFIG_DIR on the data volume, as the shared bind mount does under Docker Compose. A config-seed init container fills it from the ConfigMap on every pod start: defaults.yml is replaced, and config.yml and plugins.yml keep every live value, gaining only keys that are new in the repository. plugins.yml is added to the ConfigMap for this. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
deploy-apps and up-backend now call deploy-k8s and deploy-docker instead of repeating them. deploy-k8s-full deploys MongoDB and Redis through setup-infrastructure; deploy-infrastructure, which applied every file in k8s-manifests/, is removed. setup-k8s now finds the registry script in scripts/k8s/. The config scripts take their packages from setup-requirements.txt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The guide named scripts and files that no longer exist and an old skaffold.env workflow. It now follows make setup-k8s, make deploy and make deploy-speaker, lists the config.env settings and generated files, explains how app settings survive a redeploy, and records known limitations. config.env.template gains MONGO_ROOT_PASSWORD, which the backend needs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
skaffold.yaml pinned the backend and WebUI to one named node, and the Tailscale ingress was a hand-applied manifest with a fixed hostname and ProxyGroup. Both now come from config.env: - APP_NODE pins the backend, workers and WebUI (a new `node` chart value). - TAILSCALE_HOSTNAME and TAILSCALE_PROXY_GROUP make the backend chart create the Tailscale ingress on make deploy. k8s-manifests/ tailscale-ingress.yaml is removed. - The speaker chart no longer defaults to a named GPU node; SPEAKER_NODE sets it. An empty value turns each one off. The shared-model node list that skaffold.yaml passed to the speaker chart is removed: no template read it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Kubernetes deploy fixes and tooling, used to run Chronicle and speaker recognition on a MicroK8s cluster.
Backend and WebUI
backend/webui/Dockerfile.k8sand served by nginx.hostAliases.root. Kubernetes expands$(MONGO_ROOT_PASSWORD)from the Secret, so the password never enters Helm values.config.env.templatenow listsMONGO_ROOT_PASSWORD.Settings saved in the app survive a redeploy
CONFIG_DIR=/app/data/configon the data volume, as the bind mount does under Docker Compose.config-seedinit container (backend/src/backend/config_seed.py) fills that folder from the ConfigMap on every pod start:defaults.ymlis replaced (code defaults).config.ymlandplugins.ymlkeep every live value and only gain keys that are new in the repository.plugins.ymlis now in the ConfigMap.Speaker recognition
make deploy-speakerbuilds amd64 images on a configurable buildx builder (scripts/k8s/buildx-push.sh,BUILDX_BUILDER), so it works from an arm64 machine.COMPUTE_MODE=cu126keeps Pascal GPUs (GTX 10xx), which cu128 drops.SPEAKER_SERVICE_URL.chronicle-espresso-preset.js.No machine names in the deploy
APP_NODEpins the backend, workers and WebUI (newnodechart value). Before,skaffold.yamlpinned them to one named node.TAILSCALE_HOSTNAMEandTAILSCALE_PROXY_GROUPmake the backend chart create the Tailscale ingress onmake deploy, instead of a hand-applied manifest with a fixed hostname.SPEAKER_NODEsets it. The unused shared-model node list is removed fromskaffold.yaml.Makefile
make config-k8sregeneratesskaffold.envfromconfig.env, and putsconfig/*.ymlinto the ConfigMap. The Secret file is written with mode 600.setup-requirements.txt.deploy-appsandup-backendcalldeploy-k8sanddeploy-dockerinstead of repeating them.deploy-k8s-fullnow deploys MongoDB and Redis viasetup-infrastructure.deploy-infrastructure(which applied every file ink8s-manifests/) is removed.setup-k8snow finds the registry script inscripts/k8s/.Docs
README-K8S.mdis rewritten. The old guide named scripts and files that no longer exist. Known limitations are listed at the end, including theinfrastructureprofile deploying MongoDB without authentication while the backend now logs in asroot.Test plan
uv run --group test pytest tests/test_config_seed.py: 7 passed, on upstreamdevhelm templateof the backend chart: renders with workers as a sidecar, as a separate deployment, and with persistence offhelm templatewith and withoutnode,tailscale.hostnameandnodeSelector.hostname: node pins and the Tailscale ingress appear only when setmake config-k8swrites the new values toskaffold.env, empty when unsetmake -n deploy deploy-speaker deploy-k8s-full: runs the expected stepsmake config-k8sgenerates the ConfigMap with all threeconfig/*.ymlfiles, the Secret andskaffold.envmake deploy-speakerand reached from the backend at its in-cluster addressmake deploy(not yet run on a cluster)🤖 Generated with Claude Code