Unify trunk on main: initialization → main #3

Merged
jschoubben merged 95 commits from initialization into main 2026-09-05 01:13:46 +00:00
Showing only changes of commit 89b6dd6080 - Show all commits
+11 -3
View File
@@ -1392,10 +1392,18 @@ test("a service is reached by a name under the machine it runs on", {
await mesh("push");
await new Promise((r) => setTimeout(r, 25_000));
// `on`, not `must`: `is-active` exits non-zero for a unit that failed, so `must` would throw
// before the assertion below — taking every diagnostic with it. That happened, and the run said
// only "failed".
for (const machine of ["anchor", "laptop"]) {
assert.match(await must(machine, `systemctl is-active dnsmasq.service`), /^active/,
`the resolver is not running on ${machine}:\n` +
`${(await on(machine, `journalctl -u dnsmasq -n 20 --no-pager`)).out}`);
const state = await on(machine, `systemctl is-active dnsmasq.service`);
if (state.out.trim() === "active") continue;
assert.fail(
`the resolver is not running on ${machine} (${state.out.trim()}):\n\n` +
`journal:\n${(await on(machine, `journalctl -u dnsmasq -n 25 --no-pager`)).out}\n` +
`its config:\n${(await on(machine, `cat /etc/dnsmasq.conf`)).out}\n` +
`what the mesh wrote:\n${(await on(machine, `cat /etc/mesh-resolver/nodes.conf`)).out}\n` +
`resolv.conf:\n${(await on(machine, `cat /etc/resolv.conf`)).out}`);
}
// Through the machine's own resolver, by the path an application actually takes: nsswitch, then