Running Agents on Your Own Machines
agentrqd is a small program you install on a computer
so that AgentRQ can run coding agents on it. You enrol the machine once, and after that you can
start an agent for a workspace from the control panel, watch its terminal, and type into it.
This page is about what that means, what it can and cannot protect you from, and how to turn it off. It is the same guide as DAEMON.md in the repository.
Read This Before You Enrol a Machine
That is the whole trust model in one sentence, and it is not a caveat. An agent started on your machine can read every file you can read, write every file you can write, reach every network your machine can reach, and use every credential sitting in your home directory — because it is you, as far as the operating system is concerned.
- — Enrol machines you would be comfortable giving that account a shell on.
- — Protect the AgentRQ account accordingly. Your machines are only as safe as it is.
- — Do not enrol a machine that holds something the account's owner should not have.
The daemon refuses to run as root or Administrator, which limits the damage an agent can do to what you can do. That is a meaningful limit and it is not isolation.
Installing It
agentrqd is one static binary. Put it on your
PATH, enrol it, run it. The steps below are for the
platform this page thinks you are reading on — pick another if you are setting up a
different machine, which is the usual case.
The Script — Linux
curl -fsSL https://agentrq.com/install-agentrqd.sh | sh
It works out which archive this machine needs, verifies it
against the SHA-256 checksums published with the release, and installs to
~/.local/bin. Running it again updates in place. It installs and nothing more: it
does not enrol the machine, start anything, install a service, or run as root.
If you would rather read it first, which is a fair thing to want on the machine you are about to grant command access to:
curl -fsSL https://agentrq.com/install-agentrqd.sh -o install-agentrqd.sh
less install-agentrqd.sh
sh install-agentrqd.sh
Same install, and it is about 300 lines of POSIX sh.
To pass flags through the one-liner, put them after
-s --:
curl -fsSL https://agentrq.com/install-agentrqd.sh | sh -s -- --version 0.7.0
--version pins a release,
--dir installs somewhere else,
--force reinstalls, and
--help lists them.
Or by Hand — Linux
Releases are on the releases page — pick the archive for the machine you are installing on, not the one you are reading this on.
tar xzf agentrqd_*_linux_*.tar.gz
install -m 0755 agentrqd ~/.local/bin/
sudo. If an install guide anywhere tells
you to work around that refusal, it is removing the only thing keeping an agent
to what you can already do yourself.
Nothing here verifies what you downloaded. If you install by hand, check it against
checksums.txt on the release page yourself:
sha256sum -c checksums.txt --ignore-missing
That is the one thing the script does that a manual install usually skips, and the reason it is worth preferring.
The Script — macOS
curl -fsSL https://agentrq.com/install-agentrqd.sh | sh
It works out which archive this machine needs, verifies it
against the SHA-256 checksums published with the release, and installs to
/usr/local/bin. Running it again updates in place. It installs and nothing more: it
does not enrol the machine, start anything, install a service, or run as root.
If you would rather read it first, which is a fair thing to want on the machine you are about to grant command access to:
curl -fsSL https://agentrq.com/install-agentrqd.sh -o install-agentrqd.sh
less install-agentrqd.sh
sh install-agentrqd.sh
Same install, and it is about 300 lines of POSIX sh.
To pass flags through the one-liner, put them after
-s --:
curl -fsSL https://agentrq.com/install-agentrqd.sh | sh -s -- --version 0.7.0
--version pins a release,
--dir installs somewhere else,
--force reinstalls, and
--help lists them.
Or by Hand — macOS
Releases are on the releases page — pick the archive for the machine you are installing on, not the one you are reading this on.
tar xzf agentrqd_*_darwin_*.tar.gz
sudo install -m 0755 agentrqd /usr/local/bin/
/usr/local/bin.
The daemon itself refuses to run as root, because an agent it starts would
inherit those powers. If an install guide anywhere tells you to work around
that refusal, it is removing the only thing keeping an agent to what you can
already do yourself.
Nothing here verifies what you downloaded. If you install by hand, check it against
checksums.txt on the release page yourself:
sha256sum -c checksums.txt --ignore-missing
That is the one thing the script does that a manual install usually skips, and the reason it is worth preferring.
By Hand — Windows
sh, which Windows does
not have, so Windows has one step more than the other two platforms and verifies
the download itself rather than having the script do it.
Take agentrqd_*_windows_*.zip from the
releases page
— the archive for the machine you are installing on, not the one you are reading this
on — and, in PowerShell:
Expand-Archive agentrqd_*_windows_*.zip -DestinationPath .
Move-Item agentrqd.exe "$env:LOCALAPPDATA\Programs\agentrqd.exe"
Windows has no user directory that is already on
PATH, so add the one you installed into. It takes
effect in new shells:
[Environment]::SetEnvironmentVariable("Path",
"$env:Path;$env:LOCALAPPDATA\Programs", "User")
Nothing here verifies what you downloaded, so check the archive against
checksums.txt on the release page before you
unpack it. Compare the hash this prints with the line for your archive:
Get-FileHash agentrqd_*_windows_*.zip -Algorithm SHA256
Enrol It
In the control panel: Machines → Add machine gives you a short code, and shows these same steps. On the machine itself:
agentrqd enroll --server https://your-agentrq-server --code ABCD-EFGH
There is no remote enrolment. Somebody has to be at the machine, which is what makes the code safe to display.
Run It
agentrqd serve
To keep it running after you log out, use the service files. The installer saves them
beside the daemon's own config —
~/.config/agentrqd on Linux,
~/Library/Application Support/agentrqd on macOS
— and a manual install leaves them in the archive you unpacked.
agentrqd.service into
~/.config/systemd/user/, then
systemctl --user daemon-reload && systemctl --user enable --now agentrqd.
Add sudo loginctl enable-linger "$USER"
so it survives logout.
com.agentrq.agentrqd.plist into
~/Library/LaunchAgents/, then
launchctl load -w ~/Library/LaunchAgents/com.agentrq.agentrqd.plist.
Both are user-level — a systemd user unit and a LaunchAgent, not a system service and not a LaunchDaemon — for the reason above. Under either, the daemon exits and lets the service manager restart it when it updates itself; run by hand, it re-executes. Both work.
agentrqd serve in
a terminal you leave open; when it updates itself it re-executes in place rather
than waiting for a service manager to restart it.
A Profile Is a Credential Boundary, Not an Execution Boundary
One machine can be enrolled with several AgentRQ accounts. Each is a "profile", with its own token and its own machine identity, and the panel shows them separately.
This is worth saying plainly because the desktop app's profiles do isolate — separate cookie jars, separate sessions — and it would be reasonable to assume these work the same way. They do not.
What It Can Do, Exactly
The daemon runs exactly two programs, and nothing else:
claude-code and
acp-gateway.
It will not run a shell, and it will not run a command the server sends it. The control
panel asks for a kind — one of those two names — and the
daemon decides what that means from its own configuration. A backend that has been taken
over cannot ask this machine to run /bin/sh, because
there is no message that says "run this".
What it can do, once one of those two is running, is send it keystrokes. That is the feature. An agent at a terminal can do whatever you could do at that terminal.
Turning It Off
agentrqd disable --profile <id>
This deletes that profile's token from the machine. It works without the server's cooperation and takes effect immediately: the machine can no longer authenticate, so no future connection succeeds, whatever the server thinks. It is the thing to reach for if you believe the account has been compromised.
Also remove the machine in the control panel, which revokes it server-side and closes any connection it currently holds. The two are independent on purpose — either one alone is enough to stop that machine working, and you do not need access to the panel to do the local one.
systemctl --user stop agentrqd,
or closing the terminal it runs in) stops new work but leaves the credential on disk.
Seeing What Is Happening on Your Own Machine
agentrqd status
It reports what is running right now: each agent, the folder it is working in, which profile asked for it, and — the part that matters most — whether anybody is attached to its terminal at this moment.
That question is answerable from the machine, by the person sitting at it, without asking the account that might be doing the watching. A machine whose owner cannot find out what is driving it is not a machine anyone should enrol.
The daemon also writes a log line when a viewer attaches to a terminal on this machine and
when they leave. Under systemd:
journalctl --user -u agentrqd -f.
The Audit Trail, and What Is Deliberately Not in It
- An agent being started, and by whom
- An agent being killed
- A browser attaching to a terminal, and detaching
- An update being approved, and to which version
- Keystrokes — not on the server, not on the machine
- Terminal output, which is relayed and forgotten
What somebody types into a terminal is passwords, tokens, and the contents of files; recording it would build the most sensitive log in the system to answer a question nobody asked. That an attach happened, and when, is the fact worth keeping.
Updates
The daemon checks for new releases and tells the control panel when there is one. It never updates itself on its own initiative. Somebody has to approve it, because approving means: stop every agent running on this machine, replace the daemon, and start them again.
Before anything is replaced, the daemon:
- 1 checks the release manifest's signature against a key built into it,
- 2 checks the downloaded file against the checksum in that manifest,
- 3 runs the new binary and confirms it works on this machine,
- 4 writes down what was running, then stops it.
A build with no release key refuses to update itself and says
so; update it by hand. If an update turns out to be bad,
agentrqd rollback puts the previous binary back — it
is kept for exactly that reason.
Where Things Are
| What | Where |
|---|---|
| Config | ~/.config/agentrqd/config.json
(%AppData%\agentrqd on Windows) |
| Tokens | one 0600 file per profile in
.../agentrqd/tokens/ |
| Local status | .../agentrqd/status.json,
what agentrqd status reads |
The config file is not a credential and can safely be copied, backed up or pasted into a bug report. The tokens directory is.
Commands
agentrqd enroll --server <url> --code <code> [--profile <id>]
agentrqd serve [--profile <id>] [--verbose]
agentrqd status
agentrqd disable --profile <id>
agentrqd rollback
agentrqd version