Let a deploy node list several SSH addresses, tried in order, so the broker can reach boxes that move between networks.
Why
A node has one hostname in deploy-rs. A laptop that's sometimes at home and sometimes away is reachable at different addresses: nixfiles' tower lists tower.dyn.<home domain> (on the home network), then tower.ts.<public domain> (Tailscale), in my.deploy.sshHostnames. Only nixfiles' ssh-machine reads that list; deploy-rs and slop-broker use hostname alone, so slop status tower and slop deploy tower fail whenever that address doesn't work from the broker's box.
Proposal
slop-broker
The builder reads an optional sshHostnames list from each node in deploy.nodes (n.sshHostnames or [ ]), next to hostname, sshUser, sshOpts and sudo. Without it, hostname is the only address.
Before connecting to a node (status, logs, failed, ssh, and a deploy's copy, comparison and activation), the broker picks an address once per request:
each address but the last gets a TCP connection to its SSH port (from ssh -G with the node's options, as ssh-machine does), with a short timeout;
the first that answers wins, otherwise the last.
What was picked is visible: a slop: line for the requester, and the address in the audit log. Approvers should see where a command will run; the address can change between requests.
Documented as a generic extension to deploy-rs's node attributes, not as a nixfiles feature.
nixfiles
deploy-rs.nix copies my.deploy.sshHostnames onto each rendered node as sshHostnames. deploy-rs's schema only restricts node and profile names, and its Rust side ignores unknown fields; nix flake check (with deployChecks) should confirm that.
ssh-machine can then read it from the node instead of sshConnections.
Open questions
Pick once per request, or once per connection? A deploy opens several connections; using one address for all of them is simpler and easier to follow.
Containers (<node>.container-<name>) go through their host, so they'd follow the host's choice.
Should --host accept several addresses too? Probably not needed.
Let a deploy node list several SSH addresses, tried in order, so the broker can reach boxes that move between networks.
## Why
A node has one `hostname` in deploy-rs. A laptop that's sometimes at home and sometimes away is reachable at different addresses: nixfiles' `tower` lists `tower.dyn.<home domain>` (on the home network), then `tower.ts.<public domain>` (Tailscale), in `my.deploy.sshHostnames`. Only nixfiles' `ssh-machine` reads that list; deploy-rs and slop-broker use `hostname` alone, so `slop status tower` and `slop deploy tower` fail whenever that address doesn't work from the broker's box.
## Proposal
### slop-broker
- The builder reads an optional `sshHostnames` list from each node in `deploy.nodes` (`n.sshHostnames or [ ]`), next to `hostname`, `sshUser`, `sshOpts` and `sudo`. Without it, `hostname` is the only address.
- Before connecting to a node (`status`, `logs`, `failed`, `ssh`, and a deploy's copy, comparison and activation), the broker picks an address once per request:
- each address but the last gets a TCP connection to its SSH port (from `ssh -G` with the node's options, as `ssh-machine` does), with a short timeout;
- the first that answers wins, otherwise the last.
- What was picked is visible: a `slop:` line for the requester, and the address in the audit log. Approvers should see where a command will run; the address can change between requests.
- Documented as a generic extension to deploy-rs's node attributes, not as a nixfiles feature.
### nixfiles
- `deploy-rs.nix` copies `my.deploy.sshHostnames` onto each rendered node as `sshHostnames`. deploy-rs's schema only restricts node and profile names, and its Rust side ignores unknown fields; `nix flake check` (with `deployChecks`) should confirm that.
- `ssh-machine` can then read it from the node instead of `sshConnections`.
## Open questions
- Pick once per request, or once per connection? A deploy opens several connections; using one address for all of them is simpler and easier to follow.
- Containers (`<node>.container-<name>`) go through their host, so they'd follow the host's choice.
- Should `--host` accept several addresses too? Probably not needed.
Not part of #22.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Let a deploy node list several SSH addresses, tried in order, so the broker can reach boxes that move between networks.
Why
A node has one
hostnamein deploy-rs. A laptop that's sometimes at home and sometimes away is reachable at different addresses: nixfiles'towerliststower.dyn.<home domain>(on the home network), thentower.ts.<public domain>(Tailscale), inmy.deploy.sshHostnames. Only nixfiles'ssh-machinereads that list; deploy-rs and slop-broker usehostnamealone, soslop status towerandslop deploy towerfail whenever that address doesn't work from the broker's box.Proposal
slop-broker
sshHostnameslist from each node indeploy.nodes(n.sshHostnames or [ ]), next tohostname,sshUser,sshOptsandsudo. Without it,hostnameis the only address.status,logs,failed,ssh, and a deploy's copy, comparison and activation), the broker picks an address once per request:ssh -Gwith the node's options, asssh-machinedoes), with a short timeout;slop:line for the requester, and the address in the audit log. Approvers should see where a command will run; the address can change between requests.nixfiles
deploy-rs.nixcopiesmy.deploy.sshHostnamesonto each rendered node assshHostnames. deploy-rs's schema only restricts node and profile names, and its Rust side ignores unknown fields;nix flake check(withdeployChecks) should confirm that.ssh-machinecan then read it from the node instead ofsshConnections.Open questions
<node>.container-<name>) go through their host, so they'd follow the host's choice.--hostaccept several addresses too? Probably not needed.Not part of #22.