← Back to all guides

On a VPS (DigitalOcean, Hetzner, Linode)

MarkdownOpen in ClaudeOpen in ChatGPT

At the end, you have a VPS, a rented computer from a smaller cloud company, with Docker on it and a Terminal on it from your laptop. It is the cheapest path and has the fewest screens.

Set this up with your agent

Copy this to a coding agent on your laptop. It runs the commands and checks each step with you; what you sign in to, press or paste stays yours.

This is for a coding agent that can run commands on my laptop (Claude Code, Codex, Cursor), not a chat website.
Walk me through Loopgate's guide "On a VPS (DigitalOcean, Hetzner, Linode)": https://loopgate.dev/runner/guides/vps.md. The guides it links to are beside it, each ending in .md.
Run its commands yourself, on my laptop or on my box over SSH as the guide says, one step at a time, and check each "You should see" line before the next step.
These are mine: tell me when it is my turn, wait for me, and never ask me to type them into this chat. Signing in to anything (the portal, a cloud console, Slack, GitHub), pressing Add a runner, every token and password, my AI subscription's device code, and making the Slack app.
If I paste you the portal's install line, run it on the box: its token works once, for an hour.

At a glance

Time: 10 minutes, then Any Linux computer with Docker.

What you need:

  • An account with DigitalOcean, Hetzner or Linode
  • About 5 to 25 dollars a month, depending on the company

Steps:

  1. Make a key on your laptop
  2. Rent the box
  3. Connect and install Docker

Steps

  1. On your laptop, in Terminal, make a key pair. Press Enter at every question to accept the defaults.

    ssh-keygen -t ed25519

    You should see: Your public key has been saved in …/.ssh/id_ed25519.pub.

  2. Show the public half and copy the whole line it prints.

    cat ~/.ssh/id_ed25519.pub

    You should see: one line starting ssh-ed25519.

    The public half is the part you give the company. The file without .pub is the private half; it never leaves your laptop.

  3. In your company's control panel, create a new server (DigitalOcean calls it a Droplet, Hetzner a Server, Linode a Linode) and fill it in:

    • Location: the one nearest your team.
    • Image: Ubuntu 24.04.
    • Type or size: a shared processor plan with 4 GB of memory and at least 2 processors, on x86 (Intel or AMD), not Arm.
    • SSH key: press Add SSH key and paste the line from step 2. Choose a key over a password.
    • Firewall: add one that allows SSH (port 22) in and nothing else (a Cloud Firewall on DigitalOcean and Linode, a Firewall on Hetzner). If your company lets you, set the SSH source to your own address.
  4. Create the server.

    You should see: the server running after a minute, with its IPv4 address, four numbers with dots.

  5. Connect as the root user, with the server's address in place of <address>.

    ssh root@<address>

    You should see: a question about the box's fingerprint. Type yes and press Enter. Then a prompt that starts root@.

  6. Install Docker with Docker's own script.

    curl -fsSL https://get.docker.com | sh

    You should see: a few minutes of output.

Check

Docker answers with Docker Compose version v2. followed by more numbers:

docker compose version

Next

Your box is ready. Paste the command from the portal: Any Linux computer with Docker.

If something is off

  • SSH asks for a password. The server was made without your key. Add the line from step 2 as its SSH key and connect again.
  • SSH stops connecting. If you set the SSH source to your own address, your address changed; set it again.

Doing it by hand

Once Docker answers, By hand sets the runner up from files instead of the portal's line.