A pack is a small repository with a fixed shape. Every file has one job. Learning the shape once means you can read anyDocumentation Index
Fetch the complete documentation index at: https://docs.khal.ai/llms.txt
Use this file to discover all available pages before exploring further.
pack-* repo later and know exactly where to look.
The tree
This is the layout you get when you scaffold from the template:
What each directory does
khal-app.json — the manifest
khal-app.json — the manifest
The declarative contract between your pack and the KhalOS platform. It names the pack, lists permissions, declares services and windows, and points the shell at the frontend package to load. The schema is enforced by
@khal-os/types at build time, so a broken manifest fails CI before it can be published.Every field — required and optional — lives in the khal-app.json reference.package/ — the frontend source
package/ — the frontend source
The React surface of your pack.
package/src/index.tsx default-exports a component; tsup.config.ts produces CJS + ESM + .d.ts bundles for the platform build/install path. The app identity is the git repo/ref plus khal-app.json, not a frontend npm package.service/ — the optional backend pod
service/ — the optional backend pod
The long-running process for packs that need one — a Bun HTTP server, a NATS subscriber, a background worker.
service/src/index.ts is the entry; Dockerfile is multi-stage; healthcheck.sh is a TCP probe used by Kubernetes. Delete the whole directory for frontend-only packs — CI will skip the Docker build automatically.helm/ — the service's Helm sub-chart
helm/ — the service's Helm sub-chart
A packaged Helm chart that deploys your
service/ image. Chart.yaml names the chart, values.yaml sets defaults (image repository, ports, resources), and templates/ renders the Kubernetes objects. You don’t hand-roll infrastructure — the chart is parameterized and the platform fills in the blanks..github/workflows/ — CI + release
.github/workflows/ — CI + release
Workflows handle everything from PR validation to release metadata and backend artifacts. Every push or tag triggers the right one automatically:
Full release walk-through in Publish your pack.
| Workflow | Trigger | What it does |
|---|---|---|
ci.yml | Pull request | Lint, typecheck, build, test |
release.yml | Push to main or tag | Tags/releases the reviewed git revision; backend image/chart publishing is repo-specific |
docker-build.yml | Push to dev / main | Builds and pushes the service image (:next / :latest) |
helm-release.yml | Tag v* | Packages the chart and pushes it to oci://ghcr.io/khal-os/charts |
The contract in one sentence
You declare the shape; the platform provides the runtime. You write the manifest, the component, and (optionally) the service. The platform handles NATS connections, secrets, networking, installation, and deployment. That boundary is what keeps packs portable and the platform upgradeable.Next steps
khal-app.json reference
Every manifest field — required and optional — with examples pulled from real packs.
Publish your pack
The git-native path from commit to reviewed install source — branches, tags, dry-runs, and handoff.