Daita Agents · Guide
The background Daita host runs routines and jobs while your terminal is closed. Install it as a login service with daita host install.
The Daita host is a background process on your machine. It opens your agents, runs scheduled routines and background jobs, and raises approvals and notifications. Routines and jobs only progress while it runs. There is no cloud execution.
daita and the CLI start the host on demand, and it keeps running after you close the terminal. A host started this way exits after 30 idle minutes with no agent open. A host you install as a login service does not exit when idle, starts at login and restarts after a crash.
One agent home has one writer. While the host holds an agent, a script's Agent.open() and daita --no-host are refused for it. Stop the host first if you need the lock.
If the host stops, routines and jobs stay inspectable, but no new due work runs. On the next start Daita fences stale claims, finalizes runs that already ended without rerunning them, and keeps exactly one result per delivery.
daita host installThis writes a per-user login service (launchd on macOS, systemd on Linux) and starts it. A host already running is stopped first so the service owns it. Pass --no-start to start it at your next login.
| Platform | Service file |
|---|---|
| macOS | ~/Library/LaunchAgents/ai.daita.host.plist |
| Linux | ~/.config/systemd/user/daita-host.service |
On Linux, run loginctl enable-linger $USER to keep the host running after you log out.
| Command | Does |
|---|---|
daita host status [--json] | Show whether it runs, its pid and version, the agents it holds, whether the service is installed, and the log path |
daita host start | Start it, replacing a host of an older version |
daita host stop | Stop it gracefully |
daita host restart | Stop and start it. Use after an upgrade. |
daita host list | List every Daita host you run, across state roots |
daita host logs [-f] | Print the host log; -f follows it |
daita host install [--no-start] | Register the login service |
daita host uninstall | Stop and remove the login service |
daita host serve | Run the host in this process |
serve takes --foreground (also log to standard error) and --log-level debug|info|warning|error. Use it to debug; normal use never needs it.
On SIGINT or SIGTERM the host finishes or cancels active runs and closes every agent before it exits.
The log is logs/host.log under the state root, ~/.daita/logs/host.log by default. It rotates at 5 MB and keeps five old files. daita host status prints the exact path.
After you upgrade, run daita host restart so the host runs the new version. daita host status tells you when the host and the command differ.
To remove the service and stop the host:
daita host uninstall
daita host stopTo remove a managed installation, run daita host stop, then:
curl -fsSL https://daita-tech.io/install.sh | bash -s -- --uninstallAgent state under ~/.daita is separate from the installation and is not deleted.