bind a namespaced agent's socket dir off /run so its owner maps to the agent user
This commit is contained in:
parent
23f4f1823b
commit
6847ed865a
1 changed files with 53 additions and 7 deletions
|
|
@ -199,7 +199,12 @@ in
|
|||
"d ${homeDir}/.local/state 0755 ${owner} - -"
|
||||
"L ${homeDir}/.local/state/nix - - - - ${persisted}"
|
||||
"L ${homeDir}/.nix-profile - - - - ${homeDir}/.local/state/nix/profiles/profile"
|
||||
];
|
||||
]
|
||||
# A namespaced agent's socket dir is bound at /agents/<name>/sockets, not
|
||||
# under /run, whose tmpfs nspawn mounts before the binds and so owns the
|
||||
# mount point to root (hive-c0re `socket_bind`). The harness keeps the
|
||||
# /run/hive-agent path. A dir already bound there is left alone.
|
||||
++ lib.optional config.services.hyperhive.agent.user.privateUsers "L /run/hive-agent/${userName} - - - - /agents/${userName}/sockets";
|
||||
|
||||
# `NOPASSWD: ALL` for the agent user. Lets claude's Bash tool
|
||||
# keep working with anything that expected root (systemctl,
|
||||
|
|
|
|||
Loading…
Reference in a new issue