Let your Claude Code agents run, and answer them from your phone.
marathon runs Claude Code agents in Docker, each with its own Claude login, tmux and history, all working on the same repositories. Shared MCP services (GitLab, GitHub, Sentry, SonarQube, Playwright, Chrome DevTools) and MegaLinter run in their own containers, so their tokens stay out of the agents. Everything the agents wait for lands in one inbox that you answer from a web UI built for the phone, or from stackctl in the terminal. It is self-hosted and open source (Apache-2.0): it runs on your own Linux machine, and the web UI, its fonts and scripts are served from there.
![]() |
![]() |
- One inbox for every agent. Permission prompts,
AskUserQuestionquestions, finished turns with theirStill open:points, interrupted background tasks andask_userquestions from phei. Every item is an A2UI v1.0 surface; yes/no and either/or points become buttons. - The terminal keeps working. You can answer in tmux as before; the first answer wins.
- Startup questions too. When Claude Code asks before a session starts, for example whether to trust a folder, the question shows in the inbox; the trust question is answered Yes after 30 seconds, because each agent is isolated in its own container.
- Agents page. Every agent as a card, every running session saying in plain words what it does
and which step of its to-do list it is on. An agent that is not logged in yet has a Log in button
that opens
claude auth loginin the browser. - Conversations. Markdown, tables and highlighted code with a Copy button; type or dictate a reply, add photos and files (paperclip, drop or paste), rename the session or stop a turn. The agent's tmux opens in the browser when you need the real terminal, with clickable links and copy to your clipboard.
- Switch sessions fast. A rail beside the conversation and the terminal lists every session; on a keyboard, Alt+` goes back to the last one and Alt+K searches them all.
- Sessions and usage. Every session with its tokens and state; usage per day, agent and model, plan limits, and a cost estimate at API list prices.
- Teams. Agents work together through phei: a standing team has a leader that hands on tasks and can start sessions on the other agents, each in its own git worktree: after you allow each one, or without asking if you set the team so. See Work in teams.
- Artifacts of every account. The Artifacts page and the agents' library tools show the claude.ai artifacts all accounts in the stack published, edited or read, without sharing each one (See the artifacts of the other accounts).
- Channels. The Channels page shows how phei reaches you, and how to add Matrix, Rocket.Chat, mail or a cloud channel (Choose how phei reaches you).
- Local-model agents.
claude-local-1runs Claude Code on your own vLLM through the broker, on a network with no way out, for data that must not leave your infrastructure (Run an agent on our own model server). - Agent links and ports. Every agent has ports 3000 to 3004 that the broker forwards behind the web UI's sign-in, and the web terminal opens a dev server's URL or an absolute file path with one click, the file in a viewer (Open what an agent shows me).
- Docker for the agents. With
DOCKER_FOR_AGENTS=onthe agents rundocker pull,run,buildand testcontainers on a Docker daemon of the stack's own, shared by the agents and never with root on the repositories; each download and new container waits for your approval in the inbox (Let the agents use Docker).
- One list for all agents.
config/mcp-servers.json(starting from the shipped default) holds the MCP servers every agent gets. The MCP page and stackctl show each server's status in every agent and add, edit, switch off or delete servers for all agents at once.
- Containers page. Status, update checks, restarts, logs and updates; operations that end agent sessions name them and ask first.
- stackctl. The same features in the terminal, plus a setup wizard. On the host it runs the Docker operations the web UI asks for; the broker itself has no Docker socket.
- Robust to restarts. Sessions a container restart stopped are listed on the Agents page and come back with one tap, in their team, continuing an interrupted task by themselves. Finished turns are restored from the transcripts, and agents keep their MCP session when the broker is redeployed.
| Inbox | Usage | MCP servers |
|---|---|---|
![]() |
![]() |
![]() |
| Sessions | Containers | Conversation on a phone |
![]() |
![]() |
![]() |
| Teams | Channels | Artifacts |
![]() |
![]() |
![]() |
make tui # builds stackctl; its Setup tab writes .env, builds, starts, logs inor without stackctl:
./scripts/setup.sh # creates .env (mode 0600) with random keys and your host paths
$EDITOR .env # agent count, repository folder, MCP backend tokens
make build # build the images
make up # start the selected agents and services
make agent-1 # attach to agent 1's tmux, then /login in Claude (or Log in in the web UI)
make check # status, MCP registrations, account labels, skillsEvery agent logs in by itself (the local-model agent needs no login); never put ANTHROPIC_API_KEY or CLAUDE_CODE_OAUTH_TOKEN into
.env. To use the web UI from your phone, choose a VPN interface for the broker and allow your
phone's address in stackctl (Setup, "Web inbox access"), then press W and scan the QR code. The
full walkthrough is in Set up the stack and
Use the web UI from your phone.
| You need | For |
|---|---|
| Linux with Docker Engine and Docker Compose v2 | the agents, the broker and the MCP services |
| The Go SDK on the host (Go 1.26.2 or newer) | building stackctl; the agents mount it as HOST_GOROOT |
| A Claude account per agent | each agent logs in with /login in its own container |
| A vLLM server (optional) | the local-model agent claude-local-1, through the broker |
| Network access from Docker builds | Docker Hub (or DOCKER_REGISTRY), GitHub, npm, ghcr.io, mcr.microsoft.com, gcr.io |
| Tokens for the MCP backends you use | GitLab, Sentry, SonarQube, GitHub (an empty token keeps a backend off) |
| Node.js 22 (development only) | building and testing the web UI (make web, make test) |
| Command | Does |
|---|---|
make tui |
Build and start stackctl |
make up |
Write the agents from AGENT_COUNT and LOCAL_AGENT_COUNT, then start or reconcile the stack |
make agent-N |
Attach to agent N's tmux (Ctrl-b d detaches) |
make ps, make logs, make check |
Status, logs, smoke check |
make build |
Rebuild the images (recreating agents ends their tmux sessions) |
make down |
Stop everything, keep the logins (never use docker compose down -v) |
make serve-install |
Install the host worker as a systemd user service |
- session-broker (Go,
broker/) collects what the agents wait for and serves the web UI (React,broker/webui/, built intobroker/web/bymake weband by the broker image). - Agent relay (
agents/inbox-relay.py) runs in every agent: it types replies into tmux and reports activity, usage and MCP status. - stackctl (Go,
tui/) is the terminal UI and the host worker for Docker operations. - phei (optional, github.com/dateo/phei) lets agents report work
and ask you questions. Set
PHEI_SRCin.envto build it; without it, marathon builds a placeholder.
The architecture overview has the Mermaid diagrams: services, data flows, the session inbox, the agent relay, the host worker and state and restarts. All documentation is in docs/, an OKF bundle.
marathon is this repository. phei lives in its own repository and
is optional: set PHEI_SRC in .env to build it into the stack. Everything else the stack runs
(Claude Code, the MCP servers, MegaLinter) comes from its upstream project, at the versions set in
compose.yaml and the Dockerfiles.
Only the broker's web listener is published, on loopback by default. Anyone who can reach it and
holds BROKER_TOKEN can approve commands and open a shell in your agents, so keep it on loopback
or a VPN and list the allowed clients in BROKER_ALLOW. Instead of sharing the token, people can
sign in through an OIDC provider such as Keycloak, limited to
the roles, groups and e-mail addresses you allow. The web UI runs under a strict Content
Security Policy, no container gets the Docker socket; with DOCKER_FOR_AGENTS=on a privileged
dind runs the agents' containers, behind docker-gate. .env is mode 0600 and ignored by Git.
See Security model. Report vulnerabilities privately, as
SECURITY.md explains.
marathon is prepared for Level 1 of the OpenSSF Open Source Project Security Baseline
(OSPS Baseline, version 2026.08.28): CI treats pull request input as untrusted and scans every
commit for secrets, build output and binaries stay out of Git, dependencies are pinned and listed,
and the project documents its contribution process, defect reporting and security contact. Three
GitHub settings still wait for an admin to apply them with scripts/github-settings.sh: the
ruleset that lets main change only through pull requests, private vulnerability reporting, and
secret scanning with push protection. OpenSSF Baseline Level 1
shows how each of the 24 controls is met and which are still open.
Questions, bugs and proposals go into GitHub issues; CONTRIBUTING.md explains how to report a bug and how a change gets in.
make hooks # commit hooks: no tooling attribution in commit messages or added lines
make test # session-broker, stackctl and web UI tests (builds the web UI if missing)
python3 -m unittest discover -s tests # compose, scripts and relay
make web # rebuild the web UI into broker/web (build output, not in Git)CI runs the same tests, checks the commit messages of every pull request, scans for secrets and rejects build output and binaries in Git. The developer guide explains the parts, how a change reaches a running stack and how to try it against a test broker; scripts/demo/ fills a test broker with demo data and retakes the screenshots above. The interface follows the dateo Design System, see UI design.
marathon is licensed under the Apache License 2.0 (Apache-2.0). NOTICE lists the third-party code and fonts it includes and their licences. Versions up to v1.0.0 were released under AGPL-3.0-only.
marathon is a dateo project. It is independent of Anthropic and not affiliated with or endorsed by Anthropic. Claude and Claude Code are trademarks of Anthropic.










