- Ruby 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| Formula | ||
| README.md | ||
Homebrew packaging (macOS solo install)
The macOS "solo" distribution of Kibur is a Homebrew formula
(kibur.rb) served from a self-hosted Forgejo tap. See
ADR 0028
for the why, and ADR 0102
for the binary-only delivery this README describes.
brew tap kibur/kibur https://git.urkilden.no/Kibur/homebrew-kibur
brew install kibur
kibur up
kibur.rb here is the canonical source; the release CI syncs it into
the tap repo's Formula/kibur.rb. Edit it here and let a tagged release
propagate it.
What the formula delivers
- A prebuilt binary tarball —
brew install kiburdownloadskibur-X.Y.Z-arm64-macos.tar.gzand copies the four binaries into place. No source is distributed and no compiler runs on the user's Mac (no Rust/Zig/Node). The binaries:kibur,kibur-server,kibur-runner, and the cross-compiledaarch64-unknown-linux-muslkibur-guest-agent. They install intolibexec/bin; onlykiburis symlinked intobin, andkibur upfinds the others as siblings of the running binary. depends_on "slp/krun/libkrun"— the macOS VMM (the only macOS backend), pulled as an arm64 bottle (withlibkrunfw). A runtime dependency: the runnerdlopens libkrun, nothing links it.depends_on "apko"— the kibox wolfi engine subprocessesapko buildto bake every wolfi workspace rootfs. Also a runtime dependency (the runner execs it); without it a workspace create fails with "no engine in registry could handle the request". From homebrew-core.depends_on "e2fsprogs"—mkfs.ext4for the workspace disks (ADR 0015); keg-only, discovered under the keg.installad-hoc-codesignskibur-runnerwith thecom.apple.security.hypervisorentitlement — libkrun uses Hypervisor.framework, which without it failskrun_start_enterwithEINVAL. The entitlement needs no Apple Developer identity, and brew-installed binaries aren't Gatekeeper-quarantined. The signing runs at install time, on the user's machine.
There is no bottle do block and no source tarball — the formula's
url is the binary artifact (ADR 0102). This suits an open-core split
(only binaries leave the build host) and keeps source to a single home.
One-time: create the tap repo
The tap is an ordinary Forgejo repo named homebrew-kibur (the
homebrew- prefix is what lets brew tap kibur/kibur resolve it):
# On git.urkilden.no, create Kibur/homebrew-kibur, then:
git clone ssh://git@git.urkilden.no/Kibur/homebrew-kibur.git
mkdir -p homebrew-kibur/Formula
cp packaging/homebrew/kibur.rb homebrew-kibur/Formula/kibur.rb
cd homebrew-kibur && git add Formula/kibur.rb && git commit -m "Add kibur formula" && git push
Because the tap isn't on GitHub, users tap it by full URL (the form in
the install snippet above). After this first seed, the release CI keeps
Formula/kibur.rb up to date via the Forgejo contents API.
Per release (what the CI does, and how to do it by hand)
A tagged release (vX.Y.Z) drives
.forgejo/workflows/release-macos.yml,
which, on the self-hosted Apple-Silicon runner:
- Builds the solo frontend (
pnpm build→frontend/dist/solo, whichkibur-serverembeds) and cross-compiles the guest-agent (cargo zigbuild --target aarch64-unknown-linux-musl -p kibur-guest-agent). - Builds the three host binaries (
cargo build --release: solokibur-server, krun-onlykibur-runner, thekiburCLI). - Assembles the binary tarball
kibur-X.Y.Z-arm64-macos.tar.gz(the four binaries at the tarball root) and uploads it to the tap repo'skibur-X.Y.Zrelease as an asset. - Stamps
packaging/homebrew/kibur.rb(theurlversion,version, andsha256) and pushes it to the tap repo'sFormula/kibur.rbvia the Forgejo contents API.
The placeholders in kibur.rb marked RELEASE-CI (the url version,
version, and the sha256) are what steps 3–4 fill. Until the first
release runs, the formula points at a tag/asset that must exist.
Local check
brew style packaging/homebrew/kibur.rb # rubocop lint
brew audit --formula packaging/homebrew/kibur.rb
To smoke the install end-to-end before wiring up a real tag, build the
tarball by hand, point url at it, and set sha256:
# from a repo checkout, after `cargo build --release` of the three host
# bins + the zigbuild'd guest-agent (see the workflow steps above):
tar -czf /tmp/kibur-0.0.0-arm64-macos.tar.gz -C /tmp/stage \
kibur-server kibur-runner kibur kibur-guest-agent
shasum -a 256 /tmp/kibur-0.0.0-arm64-macos.tar.gz
# edit kibur.rb: url "file:///tmp/kibur-0.0.0-arm64-macos.tar.gz", matching sha256
brew install --formula packaging/homebrew/kibur.rb