Mac: Hermes dashboard as a launchd service behind Tailscale Serve
The dashboard used to be started by hand as `serve --host 0.0.0.0`, so it was reachable from the LAN and didn't survive a reboot or a Hermes update. Now, following Hermes's docs: - launchd agent local.hermes-dashboard runs `hermes dashboard` on 127.0.0.1:9119 (KeepAlive, --skip-build since `hermes update` builds it). - Tailscale Serve publishes it on https://cogitator-02.porgy-porgy.ts.net, tailnet only. No module exists for Serve; the task reads `serve status --json` and only sets it when it differs. - Login: scrypt password hash and a real signing secret from the vault (the old secret was the literal text "$(openssl rand -base64 32)"); the plaintext password line is removed from .env since it overrides the hash. - After Serve is set, the play checks /api/status demands the basic login; if not, it turns Serve off and fails. - Hermes's Python no longer needs a firewall exception, so that's gone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
fe268bd171
commit
d617a2aa64
8 files changed
+176
-28
No files matched your search
+14
-6
@@ -11,15 +11,23 @@ Manages cogitator-02, an Apple Silicon Mac on the tailnet (`mac.yml`,
|
||||
sleep, power back on after a power cut, wake on network.
|
||||
- **Firewall** (tag `firewall`): macOS's application firewall on, with signed
|
||||
software allowed automatically (SSH, BlueBubbles, AirPlay, Tailscale), no
|
||||
stealth mode and no block-all. Hermes's own Python isn't properly signed, so
|
||||
it's allowed explicitly (its web dashboard listens on port 9119). Any other
|
||||
unsigned program that needs incoming connections must be added the same way,
|
||||
or the firewall silently blocks it.
|
||||
stealth mode and no block-all. Any unsigned program that needs incoming
|
||||
connections has to be allowed explicitly, or the firewall silently blocks
|
||||
it. (Nothing needs that today.)
|
||||
- **Hermes dashboard** (tag `hermes-dashboard`): a launchd service
|
||||
(`local.hermes-dashboard`) running `hermes dashboard` on 127.0.0.1:9119, and
|
||||
Tailscale Serve publishing it at `https://cogitator-02.porgy-porgy.ts.net`,
|
||||
reachable from the tailnet only. Login is username `admin` with the password
|
||||
hash and signing secret from `vault_cogitator02`, written into
|
||||
`~/.hermes/.env` (a plaintext password line there is removed, since it would
|
||||
override the hash). After setting up Serve, the play checks the dashboard
|
||||
demands a login through it; if not, it turns Serve off and fails.
|
||||
|
||||
Ansible logs in as `phil`. sudo needs phil's password, which is in the vault
|
||||
as `vault_cogitator02.become_password`; only tasks with `become: true` use it.
|
||||
phil deliberately doesn't get passwordless sudo, because Hermes Agent runs as
|
||||
phil and takes commands over Telegram.
|
||||
|
||||
Not managed here: Hermes Agent (`~/.hermes`, self-updating git install,
|
||||
launchd agent `ai.hermes.gateway`) and Tailscale.
|
||||
Not managed here: Hermes Agent itself (`~/.hermes`, a self-updating git
|
||||
install on the stable channel, launchd agent `ai.hermes.gateway`), its other
|
||||
settings, and the Tailscale app.
|
||||
Reference in new issue
Block a user