diff --git a/crates/daemon/tests/service.proptest-regressions b/crates/daemon/tests/service.proptest-regressions index 66568b9..5c721a6 100644 --- a/crates/daemon/tests/service.proptest-regressions +++ b/crates/daemon/tests/service.proptest-regressions @@ -9,3 +9,4 @@ cc fb9c128abdd7bdbd0d6fcaae50eebf935ef713ec7e24674758fe5173e00c1813 # shrinks to cc bacbc6c251aa735fc9978902f1f174fb01abc6cc92dbdfd1e645db8baa1b7ccb # shrinks to script = [Up(69), WaitingCancelled, GithubLooks, GithubLooks, Queued(true), SlowBoot(true), Minutes(149), Completed(183, false), RestStale(false), Minutes(67), Up(80), RemovalsFail(false), Cancelled(166, true), Queued(false), Minutes(59), Cancelled(55, true), LostWith(15, Both), Queued(false), RestFails(223), LostWith(7, End), Up(165), Wait(5), LostWith(27, Both), Queued(false)] cc ea010f76c2e880d30ca781918590884ccd3ef4c59678c1da478f430d6ee4fa1c cc 81df8993801b917c71760523b745143086350fbd4a3bd8da5bf6fb90dd5b0b94 # mac-b never ran a job, yet the console heard of one +cc a8f1c1f8125296ffc5aaa0f518886ae98c4fb9791fedbd341c16b6a3397d9f53 # sessions opened [1, 3] times, with cause for [2, 2] diff --git a/crates/daemon/tests/service.rs b/crates/daemon/tests/service.rs index 04fbc95..d867ad8 100644 --- a/crates/daemon/tests/service.rs +++ b/crates/daemon/tests/service.rs @@ -291,8 +291,11 @@ impl Rig { /// The new Runner of [`Rig::restart_after`], not yet doing its rounds. async fn start_again(&mut self, edit: impl FnOnce(&Rig)) { - // From this moment nothing the dying Runner asks reaches GitHub: an answer it got is the last it gets. + // From this moment nothing the dying Runner asks reaches GitHub, itself or through the console: an answer it + // got is the last it gets. self.github.set_down(true); + let console_down = self.console.is_down(); + self.console.down(true); self.stop_pump().await; self.service.kill(); if self.store.crashed() { @@ -300,9 +303,13 @@ impl Rig { tokio::time::sleep(Duration::from_millis(50)).await; self.parts.vms.freeze(false); } + // A call the console took from the dying Runner, a session it opens at GitHub say, ends while GitHub is down: + // it does not land once the next Runner started. + self.console.quiet().await; self.store.revive(); edit(self); self.dead.store(false, Ordering::Relaxed); + self.console.down(console_down); self.github.set_down(false); let host = self.machines.with_host(|host| host.clone()); self.parts.roster = Arc::new(Roster::new()); @@ -2777,6 +2784,45 @@ fn running(rig: &Rig, jobs: &[i64]) -> Vec { .collect() } +/// A session the Runner asked the console for just before it died, which the console opens at GitHub only once the +/// next Runner started, would be the dead Runner's: GitHub refuses the next one's while it lasts. The rig's Runner that +/// starts again waits for the console to end what the dying one asked, against a GitHub that is down. +#[tokio::test(flavor = "multi_thread", worker_threads = 2)] +async fn a_session_the_dying_runner_asked_the_console_for_is_not_opened_once_the_next_one_started() { + let mut rig = Rig::new(2).await; + rig.service.discover().await; + until("the scale set's session", || { + rig.github.scale_sets().iter().any(|set| set.has_session) + }) + .await; + let set = rig.github.scale_sets()[0].id; + rig.console.slow_next("session/open", Duration::from_millis(300)); + rig.github.lose_session(set); + until("the listener's open waits at the console", || { + rig.console.slowed() == 1 + }) + .await; + let before = session_opens(&rig)[0]; + rig.restart().await; + // The dying Runner's open is over, whatever the console made of it. + rig.console.quiet().await; + rig.service.discover().await; + until("the next Runner's session", || { + rig.github + .scale_sets() + .iter() + .any(|s| s.id == set && s.has_session) + }) + .await; + // A session that was there first would have the open refused, and tried again every 20 to 100 ms. + tokio::time::sleep(Duration::from_millis(400)).await; + assert_eq!( + session_opens(&rig)[0] - before, + 1, + "the next Runner opened its session once, and nothing else did" + ); +} + proptest! { #![proptest_config(ProptestConfig { cases: 32, ..ProptestConfig::default() })] diff --git a/crates/fake-console/Cargo.toml b/crates/fake-console/Cargo.toml index e0e06f0..30140a9 100644 --- a/crates/fake-console/Cargo.toml +++ b/crates/fake-console/Cargo.toml @@ -11,6 +11,7 @@ cf-fake-github = { path = "../fake-github" } rand = "0.9" reqwest = { version = "0.13", default-features = false } serde_json.workspace = true +tokio = { version = "1", features = ["time"] } [dev-dependencies] tokio = { version = "1", features = ["macros", "rt-multi-thread", "time"] } diff --git a/crates/fake-console/src/lib.rs b/crates/fake-console/src/lib.rs index 3e61651..e07faee 100644 --- a/crates/fake-console/src/lib.rs +++ b/crates/fake-console/src/lib.rs @@ -4,7 +4,7 @@ //! order, with the same statuses and bounds. //! //! Tests drive it ([`FakeConsole::add_code`], [`FakeConsole::pause`], [`FakeConsole::queue_command`]), make it -//! misbehave ([`FakeConsole::down`], [`FakeConsole::fail_next`], [`FakeConsole::accept_then_drop_next`], +//! misbehave ([`FakeConsole::down`], [`FakeConsole::slow_next`], [`FakeConsole::fail_next`], [`FakeConsole::accept_then_drop_next`], //! [`FakeConsole::answer_next`]) and read what it saw ([`FakeConsole::reports`], [`FakeConsole::job_events`], //! [`FakeConsole::github_calls`]). It is written from the console's code and not //! from the client's types, so the client's wire format is checked against the contract and not against itself. @@ -24,6 +24,7 @@ pub use scaleset::{ use std::collections::HashSet; use std::sync::{Arc, Mutex, MutexGuard}; +use std::time::Duration; use cf_fake_github::FakeGithub; use cf_fake_github::httpd::{Handler, Reply, Request, Server}; @@ -75,6 +76,8 @@ struct Faults { drop_after_reports: u32, /// What every scale set call is answered instead, while set. scaleset: Option, + /// The next scale set call to this route, and how long the console takes before it asks GitHub. + slow: Option<(String, Duration)>, } #[derive(Default)] @@ -91,6 +94,10 @@ struct State { /// Commands the console stopped sending (a test run that ended or was cancelled), by id. withdrawn: HashSet, calls: usize, + /// Calls taken and not yet answered. + in_flight: usize, + /// Scale set calls [`Faults::slow`] held. + slowed: usize, paused: bool, /// The size the answers name the Mac to make room for. make_room_for: Option, @@ -126,6 +133,22 @@ fn coded(status: u16, message: &str, code: &str) -> Reply { Reply::status_json(status, &json!({ "error": message, "code": code })) } +/// A call the console took, counted until it is answered or its caller went away. +struct InFlight(Arc>); + +impl InFlight { + fn new(state: &Arc>) -> InFlight { + state.lock().unwrap_or_else(|e| e.into_inner()).in_flight += 1; + InFlight(state.clone()) + } +} + +impl Drop for InFlight { + fn drop(&mut self) { + self.0.lock().unwrap_or_else(|e| e.into_inner()).in_flight -= 1; + } +} + fn take(counter: &mut u32) -> bool { if *counter == 0 { return false; @@ -362,7 +385,9 @@ impl FakeConsole { } async fn handle(state: &Arc>, request: Request) -> Reply { + let _flying = InFlight::new(state); let github_route = request.path.starts_with(&format!("{PREFIX}github/")); + let mut slow = None; let step = { let mut state = state.lock().unwrap_or_else(|e| e.into_inner()); state.calls += 1; @@ -386,14 +411,30 @@ impl FakeConsole { return reply.clone(); } match request.path.strip_prefix(scaleset::PREFIX) { - Some(route) if request.method == "POST" => state.scaleset_begin(route, &request), + Some(route) if request.method == "POST" => { + if state + .faults + .slow + .as_ref() + .is_some_and(|(slowed, _)| slowed == route) + { + slow = state.faults.slow.take().map(|(_, wait)| wait); + state.slowed += 1; + } + state.scaleset_begin(route, &request) + } _ => scaleset::Step::Done(state.route(&request)), } }; // GitHub is asked with no lock held. let reply = match step { scaleset::Step::Done(reply) => reply, - scaleset::Step::Call(call) => scaleset::run(state, *call).await, + scaleset::Step::Call(call) => { + if let Some(wait) = slow { + tokio::time::sleep(wait).await; + } + scaleset::run(state, *call).await + } }; let mut state = state.lock().unwrap_or_else(|e| e.into_inner()); let taken = matches!(&reply, Reply::Response { status: 200, .. }); @@ -439,6 +480,11 @@ impl FakeConsole { self.lock().faults.down = down; } + /// Whether [`FakeConsole::down`] has the console down. + pub fn is_down(&self) -> bool { + self.lock().faults.down + } + /// While down, every call but a `github/…` one is answered 503: reports and job events wait while the console /// still gives the host its GitHub tokens and makes its scale set calls. pub fn reports_down(&self, down: bool) { @@ -452,6 +498,31 @@ impl FakeConsole { self.lock().faults.scaleset = answer; } + /// The next scale set call to `route` (such as `session/open`) waits `wait` before the console asks GitHub: a + /// console that is slow while the Runner that asked dies and the next one starts. + pub fn slow_next(&self, route: &str, wait: Duration) { + self.lock().faults.slow = Some((route.to_string(), wait)); + } + + /// How many scale set calls [`FakeConsole::slow_next`] held so far. + pub fn slowed(&self) -> usize { + self.lock().slowed + } + + /// Waits until the console answered every call it took: what it still asks GitHub for a caller ends first. + /// Panics after a minute, as a console that never ends a call would hang the test. + pub async fn quiet(&self) { + let began = std::time::Instant::now(); + while self.lock().in_flight > 0 { + assert!( + began.elapsed() < Duration::from_secs(60), + "the console still answers {} calls after a minute", + self.lock().in_flight + ); + tokio::time::sleep(Duration::from_millis(5)).await; + } + } + /// What a console from before the scale set calls answers them: the 404 of a route it does not know, with no /// code (agent.ts `handleAgent`). pub fn no_scaleset_calls() -> Reply { diff --git a/docs/MAP.md b/docs/MAP.md index 9d4f6e9..97d8bf1 100644 --- a/docs/MAP.md +++ b/docs/MAP.md @@ -27,7 +27,7 @@ | `crates/fake-github` (`cf-fake-github`) | A stateful fake GitHub over real sockets, for tests only: App JWT checks (`test_key`), installation tokens, repositories, scale sets, sessions, long poll, acquire, JIT configs, with `Options::auto_assign` (no kinder than the real service, each rule beside its evidence in `docs/github-protocol.md`: jobs go out only when a job is queued, ends, is cancelled or taken, or a test says GitHub looks (`github_looks`) or an Actions runner registered outside any scale set comes online (`runner_online`; `plain_runners` lists them, and `start_job` gives one the oldest queued job of its repository whose labels it has), against the smaller room of a scale set's last two polls; an opening hands out nothing; the counts never name a held job; a session that ends takes its pending messages; `offers_room` says when a job of a repository queued now goes out at once, `offers_room_for` when a job that waits goes out at GitHub's next look; only a session's newest poll is served), an assignment no Actions runner took is taken back after `TAKE_BACK_AFTER` on the queue's clock (`pass`), with faults (`fail`, `before`, `lose_answer`, `lose_session`, `expire_session_token`, `revoke_admin_tokens`, `send_the_service_to`, `send_the_queue_to`, clock offset, `set_rest_stale`: the REST view of an Actions runner one read behind, `set_down`: every request dropped, as for a client that died), and `assignments`, the hand-outs so far. What the console does with its own App's key, for `cf-fake-console`: `mint_read_token` (a token GitHub refuses every write, 403), `mint_registration_token`, `mint_plain_jit`, `revoke_token`, `token_works`, `revoke_installation_tokens`. `TestClock` is the wall clock and the monotonic one. `queue_job_at` queues a job at a ref, which its message's `jobWorkflowRef` and `eventName` show; `queue_run` the jobs of one run; `end_job` ends one as its run shows it; `from_fork` makes a job's run a pull request's from a fork. The REST view of runs and their jobs (`/actions/runs?status=`, `/actions/runs/{id}/jobs`) answers with an ETag and 304 to a request that names it (`not_modified` counts them). | | `crates/harness` (`cf-harness`) | What every crate's tests start from (dev-dependency only): `cf-fake-github` behind `cf-fake-console`, with the real clients in front of them as a machine has them (`enrolled`, `app`, `app_on`: `ConsoleTokens` and `ScaleSetClient`), `TestClock`, `fast` retries, `until`, `elsewhere` (a host no token may reach), and what a test asserts no machine did: `registrations` (requests for a registration token or traded one) and `admin_requests_from_machines` (service calls not made by the console, `CONSOLE_MARK`); `key_tokens` and `key_app` for a host that still holds the test key. | | `crates/console-client` (`cf-console-client`) | The client of the CodeFusion Console's runner protocol 1 (`/agent/runners/{enroll,report,leave}`): the wire types (`Enroll` and `Report` with the system they run on (`Os`, `macos` or `linux`, left out when none), `Status` with `commands` (the console's commands this Runner does: `pause` and `resume` (the answer's `paused`) on every system, `update` and `update-to` only with somewhere to update from, `test-run` with a console), `memoryForJobsBytes` (the cap of the limits in force), `idleWithJobsWaitingSeconds` and its reason, `heldJobs` (`HeldJobs`: per repository and label set, the jobs GitHub holds back from a scale set with room and the oldest one's wait, left out when none), `appKeyFile` (a GitHub App key file the host still holds, which `app_key::take_out` could not delete or found linked, or the one it signs with, left out when none), `appKeyKept` (why it still signs with it), `docker` (`DockerStatus`: the last Docker check, `ok`, `checkedAt`, `why`, left out before the first) and `sizes`, what one more machine of each size meets: `free` (-1 for a size the host never runs), `why`, `needBytes`, `shortBytes`, `JobLimits`, the report's `limits` that the `settings` command changes, `RunnerStatus` with its machine's `size` and `countedBytes` (the size the budget's cap counts it with; the vm-hosts' overhead is taken out of the cap), `JobEvent`, `Answer` (with `makeRoomFor`, the size the console names a pool host to make room for), `Command` ...), `enroll`, `Client` (`report`, `deliver`, `leave`; the token is a `Secret`), `Error` (`Unauthorized`, `Refused`, `GithubOff`, `Busy`, `Unavailable`, `Protocol`), GitHub through the console (`github.rs`: `github_read`, `github_jit`, each answer checked: tokens of visible ASCII, lifetimes of at least `MIN_TOKEN_LIFE` and held at most `MAX_TOKEN_LIFE`, unique installation IDs; what the console would refuse is refused unsent; a JIT runner is asked for once and never again by itself; `github_read` names at most `REFUSED_MAX` refused tokens; a 403 with the code `BROKER_OFF` is `Error::GithubOff`, a 429 or 5xx with Retry-After `Error::Busy`, held to `RETRY_AFTER_MAX`), `ConsoleTokens` (`tokens.rs`, the `TokenSource` of the App client: one read for all installations, renewed at half its life and not used `END_MARGIN` before its end on the monotonic clock, concurrent callers sharing one request; a console that fails is asked again after `FAILED_WAIT` doubling to `FAILED_WAIT_MAX` while the last token serves to its end, then every call fails at once with the reason, never asking sooner than the console's Retry-After; a token GitHub refuses is named in the next read so the console replaces it while the other installations' tokens serve, and one handed out again all the same, or new ones GitHub refuses too, are asked for again after a doubling wait; a runner the console answered with a wait is not asked for that repository until it passes (a 429 unsent); only the 403 `broker_off` (the owner's switch for the machine off) fails every call with the console's words for `GATE_RECHECK_ALONE`, and any other 403 is an error with the console's words; installation IDs are mapped by repository, and looked up again after a 404), the scale set calls (`scaleset.rs`: `scaleset_list`, `scaleset_create`, `scaleset_delete`, `scaleset_session_open`, `scaleset_session_refresh`, `scaleset_session_close`, `scaleset_jit`, `scaleset_remove`, each answer checked, the console's refusals by their codes: `not_yours`, `session_exists`, `session_lost`, `name_taken`, `runner_busy`, `rate_limited`; a 503 `github_busy` with its Retry-After is `Error::Busy`) and `Outbox`, the job events that wait for the console in one 0600 file: ids dedup (waiting, and the last 1000 sent), at most 500 kept with the oldest dropped and counted, 100 a report, marked sent only when a valid answer came. A report the console would refuse is refused here without sending. Tests: `tests/contract.rs` (every bound of the protocol against the fake), `client.rs`, `outbox.rs`, `delivery.rs`, `properties.rs`, `tokens.rs` (GitHub through the console end to end, with both fakes). | -| `crates/fake-console` (`cf-fake-console`) | A fake CodeFusion Console for tests (dev-dependency only), over `cf_fake_github::httpd`: the checks of the console's `agent.ts` and `protocol.ts` in the same order with the same statuses and bounds (`schema.rs` is protocol.ts field by field), codes, tokens, commands, pause. `withdraw_command` (the console stops sending one). GitHub through the console (`github.rs`, the console's `github.ts`): `serve_github` attaches a `FakeGithub` that makes the tokens, `set_broker` is the owner's switch per machine (off at first; off forgets the kept tokens and revokes the read ones), `scaleset_answer` answers every scale set call with one reply (`no_scaleset_calls`: a console from before them), `set_installations` gives the console's App other installation IDs; kept tokens handed out again while more than `REUSE_MIN_S` is left, a read token named `refused` replaced and revoked (`ignore_refused`: a console that does not read the names), the switch's 403 with the code `broker_off`, `JIT_PER_REPO` and `JIT_PER_MACHINE` runners in `JIT_WINDOW_S` then 429 with Retry-After, a runner name not the machine's 403 without a code, before the Runners App is looked for. The scale set routes (`scaleset.rs`, `github/scaleset/{list,create,delete,session/open,session/refresh,session/close,jit,remove}`): the admin token made in-process and kept while more than `ADMIN_REUSE_S` is left (`forget_admin_tokens`), each call scoped to the machine's own scale sets and Actions runners (403 `not_yours`), rate limits per machine in `RATE_WINDOW_S`, GitHub's 5xx, 429, a drop or a timeout (`GITHUB_DEADLINE`) a 503 `github_busy` with Retry-After (30 s, or `github_busy_wait` for tests), and an audit row per call (`scaleset_audit`). Faults: `down`, `reports_down` (everything but `github/…`), `fail_next`, `fail_next_waiting` (with Retry-After), `drop_before_next`, `accept_then_drop_next`, `accept_then_drop_next_report`, `answer_next` (any answer to the next `github/…` call). What it saw: `reports`, `job_events`, `enrollments`, `tokens`, `calls`, `github_calls`, and `os_of`, the system the console keeps for a machine (`macos`, `linux`, none for anything else, which is never refused). Written from the console's code and not from the client's types. | +| `crates/fake-console` (`cf-fake-console`) | A fake CodeFusion Console for tests (dev-dependency only), over `cf_fake_github::httpd`: the checks of the console's `agent.ts` and `protocol.ts` in the same order with the same statuses and bounds (`schema.rs` is protocol.ts field by field), codes, tokens, commands, pause. `withdraw_command` (the console stops sending one). GitHub through the console (`github.rs`, the console's `github.ts`): `serve_github` attaches a `FakeGithub` that makes the tokens, `set_broker` is the owner's switch per machine (off at first; off forgets the kept tokens and revokes the read ones), `scaleset_answer` answers every scale set call with one reply (`no_scaleset_calls`: a console from before them), `set_installations` gives the console's App other installation IDs; kept tokens handed out again while more than `REUSE_MIN_S` is left, a read token named `refused` replaced and revoked (`ignore_refused`: a console that does not read the names), the switch's 403 with the code `broker_off`, `JIT_PER_REPO` and `JIT_PER_MACHINE` runners in `JIT_WINDOW_S` then 429 with Retry-After, a runner name not the machine's 403 without a code, before the Runners App is looked for. The scale set routes (`scaleset.rs`, `github/scaleset/{list,create,delete,session/open,session/refresh,session/close,jit,remove}`): the admin token made in-process and kept while more than `ADMIN_REUSE_S` is left (`forget_admin_tokens`), each call scoped to the machine's own scale sets and Actions runners (403 `not_yours`), rate limits per machine in `RATE_WINDOW_S`, GitHub's 5xx, 429, a drop or a timeout (`GITHUB_DEADLINE`) a 503 `github_busy` with Retry-After (30 s, or `github_busy_wait` for tests), and an audit row per call (`scaleset_audit`). Faults: `down` (`is_down`), `reports_down` (everything but `github/…`), `slow_next` (the next scale set call to a route waits before the console asks GitHub; `slowed` counts them), `fail_next`, `fail_next_waiting` (with Retry-After), `drop_before_next`, `accept_then_drop_next`, `accept_then_drop_next_report`, `answer_next` (any answer to the next `github/…` call). What it saw: `reports`, `job_events`, `enrollments`, `tokens`, `calls`, `github_calls`, `quiet` (waits until every call it took is answered), and `os_of`, the system the console keeps for a machine (`macos`, `linux`, none for anything else, which is never refused). Written from the console's code and not from the client's types. | | `scripts` | `host-setup.sh`: a Linux host made a Runner of the console, unattended, as root, with no App key: `install` (packages, the Runner's user, user namespaces, the Runner built from its checkout or brought as `--binary`/`--version` with its `--sha256`, the newest image, the configuration with `--settings`; needs no code, runs any number of times, ends on `host-setup: changed` or `unchanged`, `--dry-run` says each change and a diff of the configuration; a new Runner on an enrolled host goes in under the hold `host-setup` once running jobs end, exit 75 when they outlast the wait), `enroll --code-file` (the enrolment and the service), or both at once as a cloud VM's startup script does; `merged_config` keeps the keys the Runner and the console set and takes out the ones a last `--settings` set and this one leaves out; `--class trusted` writes `"class": "trusted"` and no rules, so the Runner's defaults apply; `--sandbox container` needs no KVM, sets up the Runner user's rootless Podman (`place_engine`: subordinate ids, `podman.socket`), installs the newest container-image release into it and writes `sandbox` and `engine`; a `--version` is a minimum: `runs_newer` and `release_stays` keep an enrolled host's Runner that runs a newer commit of main (GitHub's compare), and fail the run, changing nothing, when GitHub cannot say; its reads of GitHub's API (`github_get`) send `GITHUB_TOKEN` when set and wait out a rate limit, a 5xx or no answer (`xtask/tests/host_setup.rs`, with the merge and the refusal of each option a step does not take); CI's `fresh-host` job runs it against the fakes, both at once from the source and `install`, again, `--dry-run` and `enroll` with a build brought along. `release-gate.sh`: whether "Runner release" may put out a commit: on main, its push's newest CI, Image (when there is one) and Runner build runs green, read in one list of the push's runs; it uses `github_get`, `main_head` and `compare_status` of `host-setup.sh`; `publish `, `wait`, `skip`, or a failure when GitHub cannot say (tests in `xtask/tests/host_setup.rs`). `docker-rollout-mac.sh`: on one Mac, installs an image release and names it and the Docker repositories in the Runner's configuration file, then waits for the Runner to start again on it (or says why it did not). | | `xtask` | `cargo xtask keygen | guest | release | build | it | fakes serve | kernel check | cloud-hypervisor [check]`. `fakes serve` (`xtask/src/fakes.rs`) runs the fake GitHub and console for `scripts/host-setup.sh` and ends once the host it set up serves. `it` (`xtask/src/it.rs`) runs the vm-host against real machines on this host, one small machine at a time, and writes its numbers to `target/it/report.txt`. Its scenarios: `boot`, `lifecycle`, `exit-code`, `oom`, `timeout`, `stop`, `sigterm`, `sigkill`, `firewall` (what a job reaches), `inside` (what a job's root tries against its own machine), `docker` (a `cf-docker` job: Compose, a build, a published port, and what its containers reach, privileged ones too, with a port open on the host as the target that shows the firewall at work), `docker-oom` (a container that takes all the job's memory ends the job `oom`; one stopped at its own limit, in `docker`, does not), `launchd`, `timers`, `full-memory` (what a machine whose job holds all its memory costs the host, against `Settings::VM_HOST_OVERHEAD`, and that its vm-host reads what its machine holds), and in `it/service.rs` `service` (three jobs through the whole service against the fake GitHub and console: to its end, across a Runner that dies, into an uninstall) and `commands` (the binary's `enroll`, `check --github` and `daemon`). A scenario that needs more memory than the host has free says `SKIPPED` and why. Kernel package pinned by version, size and SHA-256 in `xtask/src/kernel.rs`, read from our copy (the release `kernel-linux-virt-`) and from Alpine only when that is missing; `kernel check` goes red when our copy does not give the pinned bytes and warns when Alpine has a newer kernel. How to move the pin is at the top of `kernel.rs`. `cloud_hypervisor.rs` does the same for the Linux monitor pinned in `crates/vmm-ch/src/pins.rs` (our copy: the release `cloud-hypervisor-`), and `pinned.rs` is what both share: the HTTPS download that checks each redirect's host and the bytes, the check of our copy, and `newest`, the version a release or index names. | | `image/Dockerfile` | The root filesystem a job runs in: GitHub's Actions runner image plus tools, for arm64 and amd64 (`TARGETARCH`, each download pinned for each). For Docker jobs: iptables, pasta and the Compose plugin (the engine, CLI and buildx come with the Actions runner image). Packed by `.github/workflows/image.yml`. |