Skip to content

feat(runner): deliver the agent socket and config by path on the host backend (RIG-3512) - #1135

Merged
trunk-io[bot] merged 4 commits into
compass-service-owner/rig-3512-host-uidfrom
compass-service-owner/rig-3512-host-transport
Sep 13, 2026
Merged

feat(runner): deliver the agent socket and config by path on the host backend (RIG-3512)#1135
trunk-io[bot] merged 4 commits into
compass-service-owner/rig-3512-host-uidfrom
compass-service-owner/rig-3512-host-transport

Conversation

@rigel-mintaka

@rigel-mintaka rigel-mintaka commented Sep 12, 2026

Copy link
Copy Markdown
Contributor

This PR is part of a stack containing 10 PRs:

  1. main
  2. feat(runtime): add the host-process WorkloadRuntime backend (RIG-3512) #1120
  3. feat(runner): derive the agent uid from the Runner's euid on the host backend (RIG-3512) #1125
  4. "feat(runner): deliver the agent socket and config by path on the host backend (RIG-3512)" (this PR)
  5. feat(runtime): distinguish a configured egress policy from an unset one #1142
  6. feat(runtime): refuse an egress policy the host tier cannot enforce #1143
  7. feat(runner): carry no egress policy on a backend that cannot enforce one #1145
  8. feat(runner): report the runtime tier and egress posture per session #1148
  9. feat(cli): show the runtime tier and egress posture per session #1153
  10. feat(ui): mark each agent's runtime tier and egress posture #1154
  11. feat(runner): declare the runtime tier and egress posture at enrollment #1156

A host process has no bind mounts, so the leg that hands the agent its
gateway socket and config tree cannot work the way the container tiers
do. The host leg serves the socket and materializes config inside the
handle's own private state dir, appends no mounts, and threads both
paths to the agent as environment variables on the exec that starts it.

Backend selection is an interface probe on the engine, matching the
vsock leg, so every backend without the capability keeps its existing
path byte-identically.

The two agent-side paths become overridable, still defaulting to the
frozen literals when unset. A blank value reads as unset, matching every
other resolver in the agent, because the Runner omits an unset field
entirely and an empty path is not something the agent can dial or read.
The tests that pin the defaults keep pinning them and each gain an
override case.

Co-authored-by: Matt Wilkinson matt@rigel.build

@linear-code

linear-code Bot commented Sep 12, 2026

Copy link
Copy Markdown

RIG-3512

@rigel-mintaka
rigel-mintaka added this pull request to stack #1126 September 12, 2026 02:12
@github-actions

github-actions Bot commented Sep 12, 2026

Copy link
Copy Markdown

Compass engineering docs preview: https://compass-service-owner-rig-35-0ozc.compass-eng-docs.pages.dev

Deployed from compass-service-owner/rig-3512-host-transport at 9bc5d69.

rigel-mintaka and others added 4 commits September 12, 2026 15:14
… backend (RIG-3512)

A host process has no bind mounts, so the leg that hands the agent its
gateway socket and config tree cannot work the way the container tiers
do. The host leg serves the socket and materializes config inside the
handle's own private state dir, appends no mounts, and threads both
paths to the agent as environment variables on the exec that starts it.

Backend selection is an interface probe on the engine, matching the
vsock leg, so every backend without the capability keeps its existing
path byte-identically.

The two agent-side paths become overridable, still defaulting to the
frozen literals when unset. A blank value reads as unset, matching every
other resolver in the agent, because the Runner omits an unset field
entirely and an empty path is not something the agent can dial or read.
The tests that pin the defaults keep pinning them and each gain an
override case.

Co-authored-by: Matt Wilkinson <matt@rigel.build>
…ability (RIG-3512)

The binding is structural and crosses packages, so a signature drift on
either side would leave the host backend quietly not implementing it.
The resolver would then hand back the baked constant -- the regression
the capability exists to prevent -- and it would surface late, at the
first provision, and not at all on a box whose euid is already 1000.

Mirrors the assertions the preflight probes already carry.

Co-authored-by: Matt Wilkinson <matt@rigel.build>
… diagnostic

Review round 1 on the host transport leg found two inaccuracies, both in
text rather than behaviour.

The state-dir comment claimed Create mints the config subdir private. It
does not: Create makes the workspace, home and socket subdirs at 0700,
and the materializer creates the config root itself at 0755 so the agent
can traverse it. The 0700 state dir above it is what keeps it private.
The test fake pre-created the subdir and so reinforced the claim; it now
matches the real backend.

The AF_UNIX budget message named --runtime-dir. That flag governs where
the container tiers put the socket, but the host tier roots it under the
backend's state root, so half the operators reading the message would go
change a value with no effect on their path. It now names the socket's
parent. The test pinned the old flag and now pins the remedy, and the
runnerhub stand-in that mirrors the real string is updated with it.

Co-authored-by: Matt Wilkinson <matt@rigel.build>
… config root

Round 2 caught two comment copies of the claim round 1 corrected in
production: the fake's Create makes only the socket subdir, and the
config root is the materializer's job, as it is on the real backend.
The code was already right; only the comments still said otherwise.

Co-authored-by: Matt Wilkinson <matt@rigel.build>
@rigel-mintaka
rigel-mintaka force-pushed the compass-service-owner/rig-3512-host-transport branch from 7b841b2 to 9bc5d69 Compare September 12, 2026 19:37
@trunk-io
trunk-io Bot merged commit a9ce14a into main Sep 13, 2026
16 of 26 checks passed
@trunk-io
trunk-io Bot deleted the compass-service-owner/rig-3512-host-transport branch September 13, 2026 00:29
@trunk-io

trunk-io Bot commented Sep 13, 2026

Copy link
Copy Markdown

This pull request was merged into main as part of stacked PR 1156.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants