Building & Testing
The shortcuts in Taskfile.yml are the source of truth. CI runs the same
tasks, so a green local run of the ones below predicts a green CI run.
Toolchain
Section titled “Toolchain”- Rust 1.99.1, pinned in
rust-toolchain.tomlwithrustfmtandclippy. The workspace is edition 2024 withrust-version = "1.97". - Task for the shortcuts.
- Docker or Podman, optional. The compose smoke test,
task tla:checkand the Kafka listener tests use one.CONTAINER_ENGINEpicks one; see Docker or Podman. - For the extras only: nightly Rust and
cargo-fuzzfor fuzzing, Java, Docker or Podman fortask tla:check, Node for the docs site, andhelmwith PyYAML fortask chart:check.
Building
Section titled “Building”cargo build --workspace # debugtask build # cargo build --workspace --releasecargo build -p felix-broker-service --bin felix-broker # just the brokercargo build -p felix-controlplane-service # the control plane (felix-controlplane)cargo build -p felix-broker-service --features telemetry # with OpenTelemetry export.cargo/config.toml points every crate at one target/ directory, including
the standalone demo crates, so they reuse the workspace’s dependency builds.
The profiles, all in Cargo.toml except profiling:
| Profile | Settings | Use |
|---|---|---|
dev |
debug = "line-tables-only", dependencies built without debug info |
Everyday builds. Backtraces keep file and line; step-debugging locals needs debug = true |
release |
lto = "fat", codegen-units = 1, panics unwind |
Benchmarks and images |
profiling |
release plus debug = true (in .cargo/config.toml) |
cargo build --profile profiling -p felix-broker-service --bin felix-broker for perf or Instruments |
Testing
Section titled “Testing”task test # what CI runscargo test -p felix-storage --lib disk_log:: # one modulecargo test -p felix-broker --test durable_streams <name> # one integration testcargo test -p felix-broker-service --test quic_subscribe # one QUIC integration testtask test does one thing more than cargo test --workspace:
- It builds
felix-loadgenfirst. A test infelix-clustershells out to that binary, andcargo testwould not build it. - It runs
cargo test --workspace. No database is needed: the control plane’s tests run against its in-memory and Raft stores.
Cluster and distributed tests are covered in How Felix Is Tested.
Two traps
Section titled “Two traps”Four demo crates are outside the workspace. demos/slow-consumer,
demos/state-divergence, demos/rbac-live and demos/cross_tenant_isolation
each declare their own [workspace]. task lint and task test cannot see
them, so deleting a public item that only a demo uses passes both and breaks
the demo. Run task demo:check after changing a public API. It formats, lints,
builds and tests those crates, and runs the queue-semantics demo, which asserts
what it narrates. task lock:refresh re-locks them after a version bump. The
demos in demos/broker/ are binaries of felix-broker-service and are in the
workspace.
The cluster harness runs a prebuilt felix-broker. felix-cluster spawns
target/<profile>/felix-broker and does not rebuild it, so cargo test -p felix-cluster after a broker change tests the old binary. That silently breaks
“revert the fix and watch the test fail”. Rebuild first:
cargo build -p felix-broker-service --bin felix-brokercargo test -p felix-clustertask test is safe, because cargo test --workspace builds the broker binary.
Lint and format
Section titled “Lint and format”task fmt # cargo fmt --alltask lint # fmt check, clippy --workspace --all-targets --all-features -D warnings, # then cargo check -p felix-common on its default featuresThe last step catches a misplaced #[cfg] that workspace feature unification
would hide. The workspace lints (unreachable_pub, clippy’s
mod_module_files) are set in [workspace.lints] and fail under -D warnings.
bash scripts/setup-githooks.sh points git at githooks/. The pre-commit hook
runs cargo fmt -- --check, and the pre-push hook runs task lint. Neither runs
tests.
To lint somewhere else before a push, set FELIX_PRE_PUSH to a command that
exits non-zero when lint fails, for example one that runs task lint on a build
machine. The hook runs that command instead of task lint.
Coverage
Section titled “Coverage”task coverageThis needs cargo-llvm-cov. It builds felix-loadgen into
target/llvm-cov-target and
writes lcov.info for the whole workspace with --all-features. It ignores
demos/ and src/bin/. task coverage:demos covers only the demos.
.github/workflows/coverage.yml runs task coverage on pushes to main and on
pull requests.
What CI runs
Section titled “What CI runs”ci.yml runs on Linux only. test and cluster run on the self-hosted runners
described below for pushes to main; the rest run GitHub-hosted (see Larger runners).
Every push and pull request starts ci.yml and coverage.yml. Their first
job, changes, checks whether anything besides docs and Markdown changed
(the TLA+ specs under docs/formal count as code), and the other jobs skip
when nothing did. Each workflow ends with a job that always runs, CI ok and
Coverage ok. They fail if any job failed or was cancelled, and they are the
checks main requires, so gh pr merge --auto --squash waits for them. A
docs-only change gets both within a minute or two.
A draft pull request skips the heavy jobs in both workflows, and CI ok and
Coverage ok fail with a “draft” message so a draft cannot look mergeable.
Marking the pull request ready starts the jobs.
coverage runs on pushes to main, where it publishes the badge, and on pull
requests, where it fails if line coverage drops by more than 0.3 points. On a
pull request it is also the workspace test run: task coverage runs every
crate’s tests, felix-cluster included, so Coverage ok fails on a failing
test, and the job summary lists the failed tests by name. ci.yml’s test job
then runs only what coverage skips (coverage’s timeout scale is 5, CI’s 3) (task test:residual: doctests, and the
tests that need the telemetry feature off), plus the stress test. Pushes to
main still run the full task test:workspace there.
Its jobs, in ci.yml,
which is the authority for what each one runs:
test: on main, the workspace tests exceptfelix-cluster, then the stress tests. On a pull request, the stress tests and the testscoverage.ymldoes not run (see above).cluster: thefelix-clustersuites, split intorouting,failures,historyand the rest.checks: lint,cargo-deny, publish and toolchain checks,task docs:evidence, the changelog and release-version checks, andtask demo:check.images: builds the broker and control-plane images and checks each starts, serves/readyand does not run as root.compose: brings upcompose.yamlwith those images and does onefelixctlround trip.chart:task chart:check.python,typescript: build each binding and run its client conformance suite.spec-pairing: on pull requests that change code, checks that a change to a modelled area names its spec.formal: the TLA+ checks, whendocs/formal/or the check script changes. A pull request runs the short configurations and any it changes; main runs all of them.fuzz:task fuzzfor 30 seconds per target.
task deny runs cargo-deny check against
deny.toml, then checks
the upstream versions of the crates under vendor/ for advisories.
Other workflows, among others:
coverage.yml:task coverage, the coverage gate, and on pull requests the workspace tests.pages.yml: builds and deploys this docs site.history.yml: the nightly history-checker campaign.fuzz-nightly.yml: the long fuzz campaign.tla-walk.yml: TLC’s simulation mode over long random walks of replica-set changes, one job per family, nightly (task tla:walk).power-loss-nightly.yml: the storage power-loss suite across 110 seeds per scenario from a random base, where pull requests run eight plus the pinned ones.scale-nightly.yml: the lease canary infelix-cluster’sscalesuite at 1500 streams on a release build (pull requests run 600 once the #1760 fixes are on main). A failed night opens an issue labelledscale-nightly. See How Felix Is Tested.soak.yml: a weekly soak and resource-leak run.perf-pr.yml,perf-publish.yml,perf-comprehensive.yml: benchmarks. The PR run is advisory and never fails a check.perf-env-ab.yml: manual. Runs the fast subsets against one build twice, once per environment setting, to price a configuration default.release.yml: builds and publishes a tagged release. See Releases.nightly.yml: builds main throughrelease.ymlevery night and publishes it to GitHub only. See Nightly builds.cla.yml: the CLA Assistant bot.
Releases
Section titled “Releases”Pushing a v* tag runs release.yml. A tag with a - suffix
(v0.6.0-preview) is a GitHub prerelease, and its images are not tagged
latest. The tag has to match every version field in the tree, and every image tag the
docs and compose.yaml pin (scripts/check_release_version.py), and its release notes are its
CHANGELOG.md section. When a release bumps the compose.yaml default,
scripts/check_version_pins.py (part of task docs:evidence) lists the docs
pins to update. The workflow:
- creates the GitHub release with
felix-<tag>-linux-x86_64.tar.gzandfelix-<tag>-linux-aarch64.tar.gz(each with the broker and control plane, the second built on a native Arm runner),SHA256SUMSandSHA256SUMS.sigstore.json, its keyless Sigstore signature (how to check it: Verify a release download); - attaches
felixctl-<tag>-<target>.tar.gz(.zipon Windows) and a.sha256forx86_64-unknown-linux-gnu,aarch64-unknown-linux-gnu,aarch64-apple-darwin,x86_64-apple-darwinandx86_64-pc-windows-msvc. Each holds the binary, its README and LICENSE,completions/andman/; - writes
Formula/felixctl.rbin<owner>/homebrew-tapfrom those archives’.sha256files and pushes it with theHOMEBREW_TAP_DEPLOY_KEYsecret, a deploy key with write access to the tap (PUBLISH_HOMEBREW). A dry run keeps the formula as thehomebrew-formula-<tag>artifact, and a nightly skips it; - builds
ghcr.io/<owner>/felix-broker,felix-controlplaneandfelixctlfor linux/amd64 and linux/arm64, each on a runner of that architecture, and whenPUBLISH_IMAGESistruepushes them as one multi-arch tag and signs it; - after the Python and Node conformance suites pass, attaches the wheels and
Node addons and publishes them to PyPI (
PUBLISH_PYPI) and npm (PUBLISH_NPM); - builds
libfelixnatively on Linux, macOS and Windows, x64 and arm64, packs them into oneFelix.ClientNuGet package (failing if any of the six is missing) and pushes it to nuget.org whenPUBLISH_NUGETistrue, skipping a version already there; - attaches
libfelix-<tag>-<rid>.tar.gz(.zipon Windows) and a.sha256forlinux-x64,linux-arm64,osx-x64,osx-arm64,win-x64andwin-arm64, throughrelease-capi-archives.yml. Each holdslib/(shared and static library, plus the import library on Windows),include/felix.h,LICENSEandLINKING.txtwith the platform’s static-link system libraries and the link commands. Before an archive is kept,scripts/package_libfelix.shcompiles a C program against its header and links and runs it both ways, so a dry run exercises every platform and attaches nothing; - after both conformance suites, packages
felix-transport,felix-wire,felix-client,felix-loadgenandfelixctltogether, then publishes them to crates.io in that order (PUBLISH_CRATES), skipping any version already there; - once those jobs finish, sends
release-publishedto<owner>/getfelix.github.ioso the landing page shows the new version. This needs theSITE_DISPATCH_TOKENsecret: a fine-grained token on that one repository with Contents read and write. Without it the job only leaves a notice, and the site picks the release up on its own schedule; - once those jobs finish, sends a
felix-releasedispatch to each repo in.github/companions.txtso it can open a bump PR (see below).
Before you tag
Section titled “Before you tag”Companion repos run their integration tests against Felix main each night (see
Nightly runs in the companions). Before a
tag, the latest run in each repo that has the workflow should have succeeded,
and none should have an open felix-nightly issue:
for repo in $(sed -e 's/#.*//' .github/companions.txt | awk 'NF {print $1}'); do run=$(gh run list -R "GetFelix/$repo" --workflow felix-nightly.yml --branch main \ --limit 1 --json status,conclusion,createdAt,url \ --jq '.[0] // empty | "\(if .conclusion == "" then "not finished (" + .status + ")" else .conclusion end) \(.createdAt) \(.url)"' \ 2>/dev/null) || { echo "$repo: no nightly yet"; continue; } echo "$repo: ${run:-no run on main yet}" gh issue list -R "GetFelix/$repo" --label felix-nightly --state opendoneOnly success is green. failure, cancelled, startup_failure, “not
finished” and “no run on main yet” are not. A repo that prints “no nightly yet”
has not added the workflow, so the check does not cover it.
A failed run means a change on main broke that companion. Fix Felix, or send the companion a fix, before tagging.
A run only counts if it tested the commit you are tagging. It tests the commit
behind the nightly tag, and that tag moves last in the nightly build, so
after a failed build it can lag main by a day or more. Open the run’s “Find the
Felix commit” step, or the issue, to read the commit it used and compare it with
the one you are tagging. If they differ, build a nightly from the newest green
main commit and run the companions again:
gh workflow run nightly.yml -R GetFelix/felix --ref main -f force=truegh run list -R GetFelix/felix --workflow nightly.yml --limit 1 # wait until it completesgh workflow run felix-nightly.yml -R GetFelix/<repo>Wait for the nightly build to finish before you start a companion’s run. The
nightly tag only moves at the end, and a companion run started earlier tests
the old commit.
Release notes and the upgrade page
Section titled “Release notes and the upgrade page”The docs site’s release notes are generated from
CHANGELOG.md at build time by scripts/gen-release-notes.mjs, so assembling
the changelog fragments is all a release needs for them. The hand-written
Upgrading to 0.7 page is not generated.
Review it before tagging: it should match the assembled changelog, drop the
“not released” notice, and say whether the release adds a fleet feature or
changes INTERNAL_VERSION or FORMAT_VERSION. When the next line starts,
add its page and link it from deployment/upgrades.md.
Backfilling the C archives
Section titled “Backfilling the C archives”A release that predates the archives gets them without rerunning anything else. The workflow builds the tag’s own source, smoke-links the six archives and uploads them to the existing release; it refuses a name that is not a tag or has no published release. It defaults to a dry run:
gh workflow run release-capi-archives.yml -f tag=v0.7.3 # build and smoke onlygh workflow run release-capi-archives.yml -f tag=v0.7.3 -f dry_run=falseUploading again replaces the files already there.
Companion repos
Section titled “Companion repos”The companion-dispatch job runs under the same conditions as the site job.
It sends a repository_dispatch with event type felix-release to every repo
listed in .github/companions.txt. A repo that fails is reported and the rest
still get theirs; the job then fails, and nothing else in the release depends
on it. A prerelease tag (one with a - suffix, such as v0.6.0-preview.9)
only goes to repos whose line ends in prerelease.
The payload a companion workflow can rely on:
{ "version": "0.6.0", "tag": "v0.6.0", "prerelease": false, "release_url": "https://github.com/GetFelix/felix/releases/tag/v0.6.0"}version has no leading v. A companion listens with
on: repository_dispatch: types: [felix-release] and reads
github.event.client_payload.
The job needs a GitHub App, so that the dispatch and the bump PRs are not tied to a person and the PRs trigger CI. Without the two secrets the job only leaves a notice. An org owner sets it up once:
- In the GetFelix org settings, under Developer settings, create a GitHub App. Turn the webhook off.
- Give it repository permissions Contents (read and write), Pull requests (read and write), Workflows (read and write) and Metadata (read).
- Install it on felix and the companion repos. Felix’s nightly build uses it
to move the
nightlytag (see Nightly builds). - Generate a private key for the App.
- Add the App ID as the org secret
FELIX_RELEASE_BOT_APP_IDand the key asFELIX_RELEASE_BOT_PRIVATE_KEY, shared with felix and the companion repos. The companions use the same App to open their PRs.
The receiving side
Section titled “The receiving side”Each companion handles the event with the same reusable workflow,
.github/workflows/felix-bump.yml in
GetFelix/.github. The companion keeps
three files:
.felix-version, akey=valuemanifest:version(the Felix version the repo is on),cargo_dirsandcargo_crates(where to regenerateCargo.lock, and which Felix crates must end up locked at the new version),npm_dirs(where to regeneratepackage-lock.json) andprerelease(trueto also take prereleases)..github/felix-bump.sh <old> <new>, which edits every place the repo pins the Felix version: Cargo and npm dependencies, image tags in compose files and workflows, install lines in the README and docs, and the Felix entry in the CHANGELOG’s unreleased section. It fails if a pin it expects is missing, so a moved pin breaks the bump instead of being skipped..github/workflows/felix-release.yml, which runs on thefelix-releasedispatch and onworkflow_dispatch, and calls the reusable workflow withsecrets: inherit.
The reusable workflow mints a release bot token scoped to the calling repo and
reads .felix-version. It stops with a notice if the repo is already on that
version, if the version is older, or if it is a prerelease the repo has not
opted into. Otherwise it runs the bump script, regenerates the lockfiles
(retrying while crates.io and npm catch up with the release), and pushes
felix/bump-<version> as the bot. It opens or updates the PR
chore: use Felix <version> with that version’s CHANGELOG section, enables
squash auto-merge, and closes any older bump PR still open. The repo’s required
checks decide whether the bump merges.
Running the companion’s workflow by hand with test_pr: true opens a draft PR
titled TEST: felix bump bot that only touches .felix-version. It checks
that the bot can open PRs there and that CI starts on them. Close it without
merging.
To add a companion:
- Add
.felix-version,.github/felix-bump.shand.github/workflows/felix-release.yml, copied from an existing companion such as felix-gateway. Write the bump script’s pins from the repo’s last manual bump. - Turn on “Allow auto-merge” in the repo’s settings.
- Install the release bot on the repo, and share the two
FELIX_RELEASE_BOT_*org secrets with it. - Append the repo’s name to
.github/companions.txthere. - Add the nightly run (see below). Copy
felix-gateway’s
.github/workflows/felix-nightly.ymland.github/felix-nightly.shas the template.
Nightly runs in the companions
Section titled “Nightly runs in the companions”A bump PR shows that a companion works on a release. The nightly run shows that it still works on main, so a change that breaks a companion is found the day it lands. Each companion keeps:
.github/workflows/felix-nightly.yml, which runs on a schedule after the Felix nightly build (04:41 UTC) and onworkflow_dispatch, and calls the reusable workflow of the same name in GetFelix/.github. The calling job must grant bothcontents: readandissues: write. Setting onlyissues: writeleavescontentsat none and the checkout fails. The optionaltimeout_minutesinput limits the script and defaults to 60..github/felix-nightly.sh, which starts Felix from thenightlyimages ($FELIX_IMAGE_TAG) and runs the integration tests the repo’s own CI runs against Felix. It exits non-zero when they fail. It must not runnpm ciorcargo --locked: the workflow rewrites the manifests and lockfiles first, so they no longer match the ones in git..felix-version, the same manifest the bump uses.
The reusable workflow:
- Finds the Felix commit behind the
nightlytag. The images and the tag come from one build, but the tag moves last, so after a failed nightly build the two can be a day apart. The run warns when the broker image’s revision label names another commit, and still uses the tag’s. - For each directory in
cargo_dirs, rewrites every dependency on a crate incargo_cratesinto a git dependency on that commit, keeping features anddefault-features, and runscargo updateon those crates. - For each directory in
npm_dirs, builds the TypeScript client fromcrates/sdk/felix-typescriptat that commit, packs the JavaScript and the built addon into one tarball (the platform packages are not published for a nightly), points everypackage.jsonthat depends onfelix-clientat the tarball, and runsnpm install. - Runs
.github/felix-nightly.shwithFELIX_NIGHTLY_SHAandFELIX_IMAGE_TAG=nightlyset. - On failure, opens an issue titled “Nightly against Felix main fails” with the
label
felix-nightlyin the companion, or comments on the open one. The issue names the run, the Felix commit and the step that failed. A green run closes the issue, with a comment, if one is open. Only runs on the repo’s default branch open or close issues. A run from another branch just passes or fails.
crates.io credentials
Section titled “crates.io credentials”The crates.io job uses the CARGO_REGISTRY_TOKEN secret when it is set, and
trusted publishing otherwise. crates.io only allows a trusted publisher on a
crate that already exists, so a release that adds a crate name publishes it
with the token, which needs the publish-new scope for that name. After that
release you can, optionally:
- On crates.io, add a trusted publisher to each new crate: repository
GetFelix/felix, workflowrelease.yml, environmentcrates-io. - Once every crate has one, run
gh secret delete CARGO_REGISTRY_TOKENand revoke the token. Later releases then publish with no stored credential.
NuGet credentials
Section titled “NuGet credentials”The NuGet job holds no API key. It trades the workflow’s OIDC identity for a short-lived key through nuget.org trusted publishing. To turn it on:
- On nuget.org, under the
GetFelixaccount, add a trusted publishing policy: repositoryGetFelix/felix, workflowrelease.yml, environmentdotnet. While the package is new the policy is pending, and the first push createsFelix.Clientunder that account. - Create the
dotnetenvironment on the repository. - Set the repository variable
PUBLISH_NUGETtotrue, andNUGET_USERto the nuget.org account name if it is notGetFelix.
A dry run packs the nupkg and checks its contents without pushing.
npm has the same limit with no token fallback, so a new npm package name is
published once by hand with scripts/npm_first_publish.sh.
Rehearsing a release
Section titled “Rehearsing a release”dry_run builds everything (binaries, archives, images, wheels, addons and
crate packages) and publishes nothing. ref builds a branch or commit as if
it were tag, so the rehearsal can run before the tag exists:
gh workflow run release.yml --ref main \ -f tag=v0.7.3 -f ref=main -f dry_run=trueref without dry_run fails the run. The felixctl archives are kept as a
workflow artifact named felixctl-<tag>-archives.
Nightly builds
Section titled “Nightly builds”nightly.yml runs at 04:41 UTC. It builds the newest commit on main whose
ci.yml push run passed, and does nothing if the nightly tag already points
at that commit. It calls release.yml with nightly set to the date, which
builds everything a release builds and changes what gets published:
- images go to GHCR as
nightly(moves every night) andnightly-YYYYMMDD, multi-arch and signed like a release’s. Version tags andlatestare not touched; - nothing goes to crates.io, PyPI or npm;
- after
scripts/ci/nightly_smoke.shhas run a publish and subscribe through the pulled images, thenightlytag moves to the commit and thenightlyGitHub pre-release is recreated on it with the broker, control plane and felixctl archives, the wheels, the Node addons and oneSHA256SUMS. Its notes link the commit and the CI run and carry the[Unreleased]section ofCHANGELOG.md. It is never marked latest.
The tag and release move with a token from the release bot App (see
Companion repos), not the workflow’s own token. GitHub
refuses to point a ref at a commit that changes .github/workflows/ unless the
token has the Workflows permission, and the workflow’s own token never has it.
The nightly cannot publish without the App: the first job checks that the
FELIX_RELEASE_BOT_* secrets are set and the App is installed on the repo, so
either one missing fails the run before the build starts.
A last step deletes nightly-YYYYMMDD image tags older than 14 days. It can
only delete versions of a package that grants this repository admin access,
and it does not fail the run when it cannot.
To build one now, or rehearse without publishing:
gh workflow run nightly.yml --ref main -f force=truegh workflow run nightly.yml --ref main -f dry_run=trueA dispatch from any branch other than main is always a dry run. A pull
request that changes nightly.yml or release.yml runs it as a dry run too,
with the smoke test against images built in the runner.
The binaries, wheels and addons carry the version of the last release, so
felix-broker --version does not tell a nightly apart. The GitHub release
title names the commit.
Self-hosted runners
Section titled “Self-hosted runners”Four persistent Azure VMs (8 vCPU each, label felix-azure) take the jobs that
are too slow for a GitHub-hosted runner, but only for pushes to main,
schedules and manual runs:
ci.yml’stestandclusterjobs, andformalwhen the spec changescoverage.ymlhistory.yml, the nightly history campaignpower-loss-nightly.yml
Everything else stays on GitHub-hosted runners. Each fuzz target uses one core, so the nightly fuzz matrix gains little from eight.
Each runner takes one job at a time, so when all four are busy jobs wait in the queue.
Pull requests never run on them. Every pull request, from a branch or a
fork, runs these jobs GitHub-hosted. That keeps PR CI from queueing behind
main and the nightlies, and it keeps fork code off persistent machines: the
repository is public, and a machine that ran a stranger’s code would hand it to
the next job. Each of those jobs picks its runner like this:
runs-on: ${{ github.event_name != 'pull_request' && vars.FELIX_SELF_HOSTED_RUNNERS != 'false' && fromJSON('["self-hosted","felix-azure"]') || vars.FELIX_LARGE_RUNNER || 'ubuntu-latest' }}When the Azure runners are down, set the repository variable
FELIX_SELF_HOSTED_RUNNERS to false and those jobs run GitHub-hosted.
Delete the variable to go back.
On top of that, the repository requires a maintainer to approve workflow runs for every outside contributor’s pull request.
On the self-hosted path the jobs skip swatinem/rust-cache and keep a warm
target directory per job under ~/felix-cache instead, through
.github/actions/warm-target. The coverage job clears old profiles before it
runs, so a warm directory does not skew the numbers.
To rebuild, re-register or tear down the machines, use
scripts/ci/azure-runners/deploy.sh (up, register, status, down).
Its README covers the network rules, what is installed and how registration
tokens are handled. A runner that shows offline after a reboot or a runner
update usually needs only ./deploy.sh register.
Larger runners
Section titled “Larger runners”The repository variable FELIX_LARGE_RUNNER names a GitHub-hosted larger
runner (felix-runner-x64: 8 cores, 32 GB, up to 40 at once). When it is set,
test and coverage (wherever they run GitHub-hosted), the seven TLA+
shards and perf-pr.yml use it instead of the 4-core ubuntu-latest. TLC
runs a worker per core, so the shards gain as much as test does.
perf-pr.yml benchmarks the merge-base and the PR head in one job,
alternating their trials, so its comparison holds on any runner.
perf-publish.yml stays on ubuntu-latest: it adds to a stored history, and a change of machine would show up there as a
regression or a speedup.
Larger runners are billed per minute even on a public repository, up to the
organization’s Actions budget; past it, their jobs are refused. They are fresh
machines for every job, so pull requests can use them. Delete the variable and
every job is back on ubuntu-latest.
Docs site
Section titled “Docs site”cd docs-site && npm ci && npm run buildThe build runs the mermaid, diagram and evidence checks before astro build.
npm run dev serves the site with live reload. Use these scripts rather than
running astro directly: they first generate the release notes pages from
CHANGELOG.md, which the sidebar needs.
Versions
Section titled “Versions”docs.getfelix.dev serves the newest stable release at the root, built from that
release’s tag as it shipped. main is published under /next/, marked
noindex and left out of the sitemap, with a banner pointing back to the stable
docs. Previews are opt-in: the root never recommends one.
A plain npm run build builds main at /. DOCS_BASE=/next/ builds it for
the sub-path, and a small integration (docs-site/plugins/prefix-base-links.mjs)
prefixes the base onto root-relative links in the built HTML, so keep writing
them as /getting-started/.... To build both trees as the site does:
scripts/build-docs-versions.sh "$(scripts/latest-stable-tag.sh)" sitenode scripts/check-docs-links.mjs sitepages.yml runs the first script on a push to main, after the performance
data publishes, and on demand. A stable release ends with a job in release.yml
that dispatches pages.yml on main, which moves the root to the new tag. It
is dispatched rather than triggered by the release event because that event runs
on the tag, and the github-pages environment only deploys from main. A failed build of the tag
fails the deploy; main never fills in at the root. CI runs both scripts on a
docs change, and a link that leaves its own tree fails the check.
Cleaning up
Section titled “Cleaning up”task cleanrunscargo cleanand removes the latency demo’s raw output.task clean-alldeletestarget/and any per-demotarget/directories.task clean:staleusescargo-sweepto prune artifacts from old toolchains and anything untouched for a week, keeping the current build incremental.
