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>
This commit is contained in:
2026-03-26 22:48:40 -07:00
parent 67ced96f4d
commit baf09e8b1f
3 changed files with 6 additions and 2 deletions

View File

@@ -2,7 +2,7 @@
#
# Creates a dedicated 'mcp' system user with rootless podman support
# and a systemd service for the agent daemon.
{ pkgs, ... }:
{ pkgs, inputs, ... }:
let
mcpUid = 995;
@@ -29,7 +29,7 @@ in
serviceConfig = {
Type = "simple";
ExecStart = "/usr/local/bin/mcp-agent server --config /srv/mcp/mcp-agent.toml";
ExecStart = "${inputs.mcp.packages.x86_64-linux.mcp-agent}/bin/mcp-agent server --config /srv/mcp/mcp-agent.toml";
Restart = "on-failure";
RestartSec = 5;