ArakunDocsDownloadarakun on GitHub

Go further

Run Arakun on a server

Run Arakun without a window on a build box, an office workstation or a VPS, and follow its agent sessions from your other devices.

On this page
  1. Set it up
  2. Manage the sign-in
  3. Agents
  4. Use a server from the app
  5. New environments on a server
  6. Add a folder on a server
  7. Sandbox agents on a server
  8. Plugins, skills and MCP servers
  9. The Computers tab
  10. Cloud environments
  11. Keep it running
  12. Update it
  13. How devices reach it
  14. What it keeps

arakun server serve is Arakun without a window: for a build box, the workstation at the office or a VPS. It runs sessions of any agent signed in on that machine and keeps them going while nothing is connected. Agents ask for permission as they do in the app, and you answer from wherever you are.

arakun-server is the same server as a program of its own. It needs no display library.

#Set it up

  1. Install it

    On Linux (x86_64 or arm64), install arakun-server alone:

    sh
    curl -fsSL https://arakun.ai/install-server | sh

    It puts the binary in ~/.local/bin. It checks the release's checksums, and their signature when a verifier is installed.

    It also installs what the server runs agents with, if it is missing:

    • git and gh, with the system's package manager. That needs root or sudo without a password; otherwise it prints the command to run.
    • Node.js 22, in ~/.local/share/arakun/node, linked as node, npm and npx in ~/.local/bin. Without Node, a new session fails as it starts.
    • Claude Code, in ~/.local/bin/claude, when there is no claude on the PATH. Run claude once to sign in.

    --no-tools leaves git, gh, Node.js and Claude Code to you. --version installs a given release.

    On a Mac or Windows, install the app and use arakun server in place of arakun-server.

  2. Sign in

    Through the relay (the default), the server needs a sign-in to your account:

    sh
    arakun-server login   # once: sign in with GitHub, for the relay

    login prints a code and https://github.com/login/device. Open that address on any device, enter the code and approve. The terminal says "Signed in as" and your login. The machine needs no browser.

    Over Tailscale or the local network (--reach tailscale or --reach lan), no account is needed. Skip this step.

  3. Start it

    sh
    arakun-server serve   # runs until Ctrl+C, a signal or `arakun-server quit`

    Through the relay without a sign-in, serve in a terminal stops and says to run login.

  4. Reach it from a device

    Through the relay, there is no link. Devices signed in to the same GitHub account get in:

    • In the app: sign in with GitHub, then open the Computers tab. The server joins the list under Your servers by itself.
    • On a phone, or in any browser: open https://app.arakun.dev, sign in as the same account and pick the server. It is the page the phone remote uses: it lists the sessions, reads them live, and notifies you when one finishes or needs you.

    Through the relay, arakun-server pair prints where to sign in and as which account.

    Over Tailscale or the local network, run arakun-server pair in another terminal. It prints a link and its QR code. The link is good for two minutes and pairs one device. In the app's Computers tab, press Add a computer, pick By link and paste it. Or open it on a phone or in any browser.

  5. Work with sessions

    sh
    arakun-server add ~/code/app                 # a folder sessions can start in
    arakun-server new --agent claude "fix the failing test"   # prints its id
    arakun-server ls                             # folders and sessions
    arakun-server log <id>                       # its status and last entries
    arakun-server wait <id>                      # until it stops working
    arakun-server send <id> <text>               # a follow-up
    arakun-server approve <id>                   # or deny: answer what it asks
    arakun-server stop <id>                      # stop its turn
    arakun-server devices                        # paired devices
    arakun-server unpair <device>                # forget one
    arakun-server machines                       # the account's machines, this one marked
    arakun-server forget <label>                 # remove one of them from the account

    arakun-server help lists them all.

#Manage the sign-in

  • login again checks that the sign-in still works and says who is signed in. login --force signs in again and ends the old sign-in.
  • logout ends the sign-in. A running server stays up and leaves the relay. Devices on the network or Tailscale stay.
  • status shows who it is signed in as, "Not signed in", or that the sign-in ended.
  • status --json lists the open turns as times and CPU use, with nothing from the sessions' content.
  • A sign-in lasts at most 180 days, or 90 days without use. Run arakun-server login again then.
  • forget <label> disconnects a running machine. It stays out until it is restarted or signed in again with login.

#Agents

The server runs the same agents as the app: Claude Code, Droid, OpenCode, Codex, Devin, Cursor, Antigravity and Workers AI.

Claude Code and Codex also need their ACP adapter. The server installs a missing one with npm the first time a session needs it, so Node 22 or newer must be on the server's PATH. The install script puts one there.

#Use a server from the app

Once you have connected a server, the app connects to it each time it starts. Each folder the server offers is an environment in the sidebar, marked with the machine's name. A folder whose repository you also have here (the same origin) joins that project. An environment whose folder you remove on the server yourself, such as with rm or git worktree remove, leaves the list with its sessions within a few seconds, unless a session there is still working or waiting for an answer.

Its sessions open in the same tabs, with the same composer, as sessions here. Send, stop, approve and answer go to the server. In a server's environment:

  • The model menu lists the models and reasoning levels that server offers, and only the agents it can start.
  • Before a session starts, / in the composer lists the skills of the folder's repository on the server too, ahead of personal and plugin skills.
  • A terminal is a shell in that folder on the server. The project commands from Settings run there too.
  • The Changes panel shows that folder's changes. Stage, discard, commit, pull, push and the pull request button run there, with the server's git and gh logins.
  • The Explorer lists its files, and they open in file tabs (text only). @ in the composer completes its paths.
  • A file you attach from this computer, such as an image, a log or a PDF, goes to the server with the prompt: up to 5 MB each and 15 MB for one prompt. A larger image goes as a smaller copy. A relative path still names a file in the server's folder. An older arakun-server takes images only.
  • The Artifacts tab shows the pages of the folder's artifacts/, and New artifact and Change start their session on the server.
  • Fork, compact, rewind and /stage run on the server. "Continue with" hands the session to another agent on that server.
  • When an agent there needs a login, token or password, it asks with the same private card as in the app, and the phone page shows it too. What you type goes only over an encrypted connection: the relay, Tailscale or https. Over --reach lan, the card offers only Decline. A sandboxed agent on a server doesn't get the card yet.
  • When the agent is not signed in on that server, the session shows a card with Sign in in a terminal. It runs the agent's sign-in in a terminal on the server.

#New environments on a server

"New environment" makes a worktree on a server too: Alt+click the + and pick the machine, or right-click a server's environment. It goes in ~/arakun-workspaces/<project>/<branch> there, or /work/arakun-workspaces/<project>/<branch> on a cloud environment.

To spread new environments across machines, turn on Spread new environments at the foot of the Computers tab's list. A new environment then goes to the least busy connected machine that has the project, this computer included. Set each machine to Prefer, Normal, Avoid or Off under New environments in its settings there. A preferred machine takes new environments before the others. An avoided one takes them only when no other can. One that is Off never takes them this way, but you can still pick it in the New environment dialog. When every machine is Off, a new environment goes to the open environment's machine.

#Add a folder on a server

To add a folder on a server, pick it in the Computers tab and press Add a folder. Clone runs that machine's git, with its logins, and puts the repository in the folder that holds most of the server's folders. A folder right under the root, such as a cloud environment's /work, holds the clones itself (/work/<repo>). You can also paste a clone URL in Add project (Ctrl+O) and pick the item that clones it on the server, such as Clone owner/app on box. The new folder opens in its project once the server has it. If the clone fails, a notice says so.

#Sandbox agents on a server

On a Linux server, agents can run in a bubblewrap sandbox. They can change the folder they work in, the repository's Git folder (but not its config or hooks), their own sign-in and settings folders, caches and their own /tmp, and nothing else.

Settings › Project shows Sandbox agents on the server for each server where the project has folders. The switch changes it for all of the project's folders there, and applies to sessions started afterwards. It shows on only when the sandbox is on for all of them, and it can be changed only while the server is connected. A Windows server offers no switch.

A folder with no choice of its own follows the other folders of its repository, so a new environment follows its project. Otherwise it follows ARAKUN_SERVER_SANDBOX: set it to 1 in the server's environment to sandbox agents by default. A cloud environment sets it, so its agents run in the sandbox unless you turn it off.

#Plugins, skills and MCP servers

In the Marketplace, "Install on" adds a plugin or MCP server for Claude Code on a paired server.

Every paired server also mirrors this computer. When it connects, and after each install here, it adds the plugins (and their marketplaces), the user MCP servers and the skills from skills.sh it lacks. A notice lists what was added. What you installed in a repo just for you goes to the server's folders with the same origin. What you shared with the repo goes with git. The mirror never removes anything you installed. Over plain http, only plugins and skills go.

Your MCP sign-ins (Claude Code's tokens for the MCP servers you signed in to) go only to a server you let have them. Pairing by link asks, and the answer is no unless you change it. Copy MCP sign-ins in the server's settings in the Computers tab changes it later, and the server's card says when it holds a copy.

  • Turning it off takes the copy off the server when it next connects. So does removing the server, or unpairing this app on it.
  • A server paired before pairing asked keeps getting them until you turn it off.
  • A server on macOS doesn't take sign-ins, since Claude keeps them in the Keychain there.

#The Computers tab

The Computers tab lists this computer first, then your servers, each with its status as a dot and a word: Online, Connecting, Offline or Not connected. Pick one to see how it is reached, its environments and their sessions, its agents and their plan limits, and its settings. A session opens in its project.

Signed in, a server on your account joins the list by itself. Signed out, the list says your account's servers show up once you sign in. Add a computer shows both ways to add one: Your own server, signed in with your GitHub account, or By link, for one on Tailscale or your network.

Remove, in a server's settings or its ⋯ menu, asks once. Then the server forgets the app, and a server on your account leaves the account too. Its sessions stay on it. If the server can't be reached then, remove the app there with arakun-server unpair <device>.

#Cloud environments

Under the servers, Cloud offers cloud environments: servers Arakun runs for you, so sessions keep working with your computer off. Access is given by hand. Press Ask for access there and say what you would use it for. The section then shows where your request stands.

Asking for access, making a cloud environment and waking one need a GitHub account linked to your Arakun account, since the review reads its age and activity. Without one, the Computers tab says so and offers Link GitHub, which opens Settings › Account.

With access, New cloud environment makes one. The first start takes a few minutes, and its card shows the steps: start the environment, install Arakun and the agents, connect to it, and sign an agent in. The step under way shows how long it has run, and says so when it takes longer than usual. A step that fails says why, with Try again or Connect again.

The last step offers Sign in to Claude, Sign in to Codex and Skip. A sign-in button opens a terminal in the environment's /work with claude /login or codex login. The sign-in stays on the environment's own disk, and nothing is copied from this computer. If you skip, a session there offers the sign-in when it needs one. The buttons stay on the card until the app restarts, so you can sign the other agent in too.

The free plan gives 3, named Cloud, Cloud 2 and Cloud 3. The section lists each by name, with whether it is awake and why it stopped, and Wake, Stop and Remove. It also shows the hours left this month: 20 hours a month, which your cloud environments share. The phone's Computers screen has the same.

Each time a cloud environment wakes, it updates its server and the agents' CLIs (Claude Code, Codex) to the latest Arakun release. Your files stay, so clones, commits you have not pushed and sign-ins are still there. If the update fails, it starts with the versions it had. Rarely, a change to the environment's system starts it with empty files. You get a notice at least a week before.

A cloud environment goes to sleep 2 minutes after its sessions stop working and you last used it, and keeps your files. A session waiting on you keeps it awake for 15 minutes. A connected device alone doesn't keep it awake. Starting a session or sending a message wakes it, and the message goes once it is back. An agent with no progress for 20 minutes looks stuck: if no device is connected and no other session is working, the environment sleeps at once. In these two cases you get a notice that says why.

A sleeping cloud environment keeps its disk for 30 days, since that is how long Cloudflare keeps it. Any wake, by you, a device or Linear, starts the 30 days again. A week before the disk goes, and again on the day, you get a notice that names the environment. After that the disk is removed, and the environment's next wake starts clean.

Sleep after sets how long a cloud environment may run before it stops: 1, 2, 4 or 8 hours, or No limit. Until you choose, your plan's default applies (2 hours on the free plan), and the choice marks it. With no limit, a stuck agent can use the month's hours. The phone's Computers screen has the same choice.

A cloud environment has git and ripgrep, a C compiler and build tools (build-essential, pkg-config), Python 3 with pip and venv, jq, zip, unzip, xz, file and ssh-keygen. Its agents run in the sandbox: they can change the folder a session works in, their own settings and caches, and nothing else on the environment's disk. Agents there can't install system packages, so put a Python package in a virtual environment and other tools in the home folder. Terminals there run as the same user as the agents, so agents can change what you clone from a terminal.

To let a cloud environment clone your private repositories and push branches, install the Arakun Cloud GitHub App on the repositories you choose, or on your whole account. Your own GitHub account must also be able to read the repository, and write to it for a push. No GitHub token is stored in the environment: Arakun adds a short-lived token for the one repository on each git request.

  • Public repositories clone without the app.
  • When git is refused, it prints why, with the link to install the app where it is missing.
  • git@github.com: URLs work too. Git uses https for them.
  • The gh CLI and Git LFS don't get a token yet.

#Keep it running

service install runs serve --service as a service: systemd on Linux, launchd on macOS. It starts the server now, again after a crash, and at boot (Linux) or login (macOS).

sh
arakun-server login               # through the relay: sign in, before or after install
arakun-server service install     # takes serve's flags: --reach, --port, --relay
arakun-server service status      # installed, running, lingering, and how it is reached
arakun-server service logs -f     # what it prints
arakun-server service uninstall   # stop it and remove the service; the data stays

arakun-server quit stops it until the next boot or login. service install --print shows the service file and installs nothing.

  • Not signed in. Through the relay, a service with no sign-in does not fail. It runs signed out, and connects as soon as you run arakun-server login, with no restart. A service installed before v0.19.0 needs only arakun-server login once after updating.
  • Logged out (Linux). It keeps running after you log out, so you can set it up over SSH. If turning that on needs root, it prints the sudo command to run.
  • As root. Many VPSs only have root. There it installs a system unit that runs as root. The binary must then be in a folder only root can write to, such as /usr/local/bin, not a home folder. To run the agents as another user, log in as that user and install from there.
  • macOS. Use arakun server service install. It runs from login to logout, so a Mac nobody sits at needs automatic login.
  • Agents. The service gets the PATH of the shell you install it from, so it finds the same agents. If Node comes from mise or nvm, install it from a shell where node works. If you install an agent somewhere else later, run service install again.

On Windows there is no service command yet. To keep the server running, start arakun server serve --service from Task Scheduler, with the trigger "At log on".

#Update it

The server does not update itself. Run the install line again, then restart the service on the new binary:

sh
systemctl --user restart arakun-server
  • Installed as root: the service is a system unit, so leave out --user.
  • A server in another folder (ARAKUN_SERVER_DIR): its unit is arakun-server-<folder>.

#How devices reach it

--reach relay is the default. The server dials out, so it works behind a firewall, and everything between the device and the server is end-to-end encrypted. --relay <url> names a relay of your own.

It needs login, before or after it starts. It lets in the devices signed in to the same account, with nothing to pair.

What serve is started with is kept for the next run.

#What it keeps

The server keeps its data in ~/.local/share/arakun/server/, which only your user can read: paired devices, the sign-in (account.json, which logout removes), folders, sessions and their transcripts, and photos sent with prompts. Photos sent with prompts are removed after 30 days, and the transcript of a session the server no longer lists after 7 days. The app's own files are not touched, so the app and a server can run side by side. ARAKUN_SERVER_DIR names another folder, for a second server on the same machine.

A turn that is running when the server stops is cut off. Its session is still there after a restart, and the next message picks it up.

Did this page help?

Tell us about a mistake on this page, or ask for help with Arakun.