---
name: boxd-setup-hermes
description: Install the Hermes agent (Nous Research) on THIS boxd VM — a self-improving CLI agent with a built-in messaging gateway (Telegram/Discord/Slack/WhatsApp/Signal) — using its official installer, then hand off `hermes setup` + `hermes` to the user. The in-VM version of the laptop `boxd-setup-hermes` skill: you're already on the box with root, so you run the installer here, `source ~/.bashrc`, and the user runs `hermes`. Use when the user says "set up Hermes here", "install hermes-agent on this VM", "install the Nous Hermes agent", "I want to run hermes on this box", or mentions NousResearch/hermes-agent.
---

# boxd-setup-hermes (in-VM)

You are **inside** the boxd VM. Install the Hermes agent here with its official
installer, then hand the interactive parts (`hermes setup`, `hermes`) back to the
user. When you're done, `hermes` is on PATH and the user can pick a model and
start it.

> Hermes Agent (Nous Research) is a self-improving CLI agent with a built-in
> messaging gateway (Telegram/Discord/Slack/WhatsApp/Signal). Repo:
> https://github.com/NousResearch/hermes-agent

## What the installer does

`https://hermes-agent.nousresearch.com/install.sh` is the supported install path
— there's no separate "clone the repo and run a setup script" flow; the installer
*is* it. It clones the repo to `~/.hermes/hermes-agent`, installs Python 3.11 (via
`uv`), Node 22, ripgrep, ffmpeg and Playwright Chromium, drops a `hermes` wrapper
at `~/.local/bin/hermes`, and adds `~/.local/bin` to PATH in `~/.bashrc`. The base
boxd image already has `curl`, ripgrep, ffmpeg and passwordless sudo, so the box
has everything the installer needs.

## Steps

1. **Install Hermes.** Your shell is non-interactive, so pass `--non-interactive`
   (otherwise the installer prompts on `/dev/tty` and blocks):
   ```bash
   curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash -s -- --non-interactive
   ```
   This is a multi-minute install (Python + Node + a Chromium download). Let it
   run to completion before moving on.

2. **Make `hermes` available now.** The installer edits `~/.bashrc`, which only
   affects *new* shells — re-source it (or call the binary by full path) to verify
   in the current one:
   ```bash
   source ~/.bashrc
   hermes --version        # if "command not found": ~/.local/bin/hermes --version
   ```

3. **Hand off configuration to the user.** `hermes setup` is an interactive wizard
   that asks for an LLM provider + API key (OpenAI / Anthropic / OpenRouter / Nous
   Portal) — don't run it for them or invent a key. Tell the user to run, in their
   own interactive shell:
   ```bash
   hermes setup     # pick a provider, paste an API key   (or: hermes setup --portal)
   hermes           # start the interactive agent
   ```
   New SSH / `boxd connect` sessions already have `hermes` on PATH, so a user who
   logs in after the install is ready to go.

## Optional: expose the messaging gateway

Hermes has a built-in always-on gateway (messaging + cron). Only wire it up if the
user asks — most just want the interactive `hermes` CLI. Install it as a managed
service with Hermes' own command, then, if it should be reachable on this VM's
public URL, point the proxy at its port:
```bash
hermes gateway install        # managed gateway service (messaging + cron)
boxd machine proxy set-port --port=<gateway-port>
```

> **Always-on means turning the idle timers off.** A machine goes to standby or
> hibernates after its timeout passes with no network traffic in either direction.
> CPU work, disk work and local timers don't count, and the machine's own DNS, NTP
> and DHCP traffic is ignored. A hibernated machine wakes only on a new connection
> through boxd (HTTPS or SSH, including over the org's tailnet, or
> `boxd machine exec`), not on a raw exposed port and not on its own cron jobs, so
> the gateway's cron stops while the machine sleeps. For a gateway that must stay up:
> `boxd machine config set auto-suspend.timeout 0` and
> `boxd machine config set auto-hibernate.timeout 0`.

> **Central secrets:** the interactive `hermes` runs from the user's login shell,
> so it inherits any `boxd env set --secret` / `boxd env set` values — an API key set
> centrally is visible to it without pasting into `hermes setup`. The managed
> gateway above is a systemd service and won't see central vars; it uses the key
> from `hermes setup`.

## Notes

- **You have root and passwordless sudo** — the installer's optional system
  packages (ripgrep / ffmpeg / Playwright deps) install without prompting.
- **API keys are the user's to provide.** This skill installs Hermes; it does not
  configure providers or store secrets. Stop after the install + handing over
  `hermes setup`.
- **Re-running is safe** — the installer `git pull`s `~/.hermes/hermes-agent` and
  updates in place.

## What this skill does NOT do

- Configure an LLM provider or paste API keys — that's the user's `hermes setup`.
- Set up the messaging gateway as a service unless asked (see "Optional" above).
