Commit Graph

15 Commits

Author SHA1 Message Date
47b4e533ff Document UID 850 as permanent — never change
Rootless podman deeply caches the UID in storage, subuid mappings,
and systemd sessions. Changing it destroys all container state.
Reference: log/2026-04-03-uid-incident.md

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 09:30:37 -07:00
5a381d314e Pin mcp user UID/GID to 850
UID 995 conflicted with sshd on orion. Pin to 850 (the 800-899 range
is unused on all nodes and well below NixOS auto-assign range).
Pin GID to 850 as well for consistency.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 01:38:45 -07:00
53addc0ed1 Remove pinned UID for mcp user
UID 995 conflicted with sshd on orion. Let NixOS auto-assign the UID
for the mcp system user. Use systemd's %U specifier for XDG_RUNTIME_DIR
instead of the hardcoded UID.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-03 01:33:37 -07:00
6a65e73200 Remove mcp-master systemd unit (now containerized)
The master runs as an MCP-managed container, deployed via
mcp deploy mcp-master --direct. The systemd unit was a temporary
bootstrap mechanism.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 22:56:08 -07:00
b26478d47b Add mcp-master systemd service
Runs the MCP v2 master as a systemd service on rift. Uses
ConditionPathExists so the unit is a no-op on worker nodes
(like orion) that import mcp.nix but don't have the binary.

Starts after mcp-agent.service. Security hardened like the agent
but with ProtectHome=true (master doesn't need /run/user).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 20:43:38 -07:00
c2882fcd8b allow mcp to read systemd logs 2026-03-29 18:00:48 -07:00
34b2a01f1a Use /srv/mcp/mcp-agent binary instead of Nix flake input
The agent binary is now managed by the operator (scp + install to
/srv/mcp/mcp-agent), not by the Nix flake. This allows agent upgrades
without a full NixOS rebuild.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 16:12:51 -07:00
baf09e8b1f Add MCP to Nix packages and wire agent to Nix-managed binary
- Add mcp flake input (git+ssh://git@git.wntrmute.dev/mc/mcp.git)
- Add mcp CLI to mcpkg.nix system packages (installed on all machines)
- Update mcp.nix to use Nix-managed mcp-agent binary path instead of
  hardcoded /usr/local/bin/mcp-agent

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 22:48:40 -07:00
e7d244c606 Disable ProtectHome for mcp-agent (blocks /run/user for podman) 2026-03-26 14:40:54 -07:00
7f0a978e86 Relax mcp-agent sandbox for rootless podman compatibility 2026-03-26 14:34:50 -07:00
bac757c22e Allow mcp-agent access to /run/user for rootless podman 2026-03-26 14:31:33 -07:00
57cab0c88a Pin mcp UID, fix XDG_RUNTIME_DIR for podman access 2026-03-26 14:08:57 -07:00
71e6907a3c Add PATH to mcp-agent service for podman access 2026-03-26 14:04:52 -07:00
f0f15fccb0 Add mcp-agent systemd service to NixOS config 2026-03-26 13:30:06 -07:00
417870a85b Add mcp.nix: MCP agent system user with rootless podman 2026-03-26 13:02:25 -07:00