Self-hosted CI runners on DigitalOcean
Create a Droplet that installs the Ferro agent from cloud-init user data on first boot and connects out to your control plane.
Outbound HTTPS only, and no cloud credentials in Ferro
ferro-agent is a single static Linux binary for x86_64 and aarch64. In the default Relay Mode it connects out to your Ferro control plane over HTTPS (443), so the runner needs no inbound ports, and Ferro never holds DigitalOcean API credentials for a server you install yourself.
Before you start
- A Ferro account. The Free plan covers one runner; see the quickstart if you have not signed up yet.
- The
doctlCLI, authenticated for your DigitalOcean team. You can also paste the same user data into the control panel when creating a Droplet.
1. Register a node and copy its token
In the dashboard, open Fleet Nodes and choose Add Linux server. Name the node (for example do-nyc3-01) and leave the direct URL blank to stay in Relay Mode.
Ferro shows the node's frn_... token once, together with a generated bootstrap script, and stores only the token's SHA-256 hash. Copy the token now. In the snippets below, replace https://ferro.example.com with your control plane URL and frn_YOUR_NODE_TOKEN with that token.
2. Save the cloud-init config
Save this as ferro-cloud-init.yaml with your control plane URL and node token filled in. On first boot it installs the prerequisites, blocks the Droplet metadata service for non-root users, and runs your control plane's installer, which verifies the ferro-agent release before installing it as a systemd service.
#cloud-config# Ferro BYO-Metal Runner — Ubuntu 24.04 cloud-init (DigitalOcean, Vultr, OVHcloud, Hetzner Cloud)package_update: truepackages: - curl - ca-certificates - git - nftables - polkitdruncmd: - | set -euo pipefail # Block cloud metadata service (169.254.169.254) for non-root UIDs nft add table inet ferro_metadata_guard nft 'add chain inet ferro_metadata_guard output { type filter hook output priority 0; policy accept; }' nft flush chain inet ferro_metadata_guard output nft add rule inet ferro_metadata_guard output ip daddr 169.254.169.254 meta skuid != 0 reject # Run your Control Plane's hosted verified installer (SHA-256 + Cosign, LoadCredential, Polkit, OS sandbox) export FERRO_CONTROL_PLANE="https://ferro.example.com" export FERRO_NODE_TOKEN="frn_YOUR_NODE_TOKEN" export FERRO_LABELS="linux,cloud-init" export FERRO_MAX_CONCURRENCY="4" curl -fsSL --proto '=https' --tlsv1.2 "${FERRO_CONTROL_PLANE}/install-agent.sh" | bashThe node token lives in user data
User data stays readable from the Droplet's metadata service. The config blocks 169.254.169.254 for non-root users, so CI jobs running as ferro-job cannot read it. If the token is ever exposed, rotate it from Fleet Nodes.
3. Create the Droplet
doctl compute droplet create ferro-runner-do-01 \ --region nyc3 \ --size s-4vcpu-8gb-amd \ --image ubuntu-24-04-x64 \ --user-data-file ferro-cloud-init.yaml- Change the region and size to suit your workload.
FERRO_MAX_CONCURRENCYin the config sets how many runs the Droplet takes at once, so match it to the size you pick. - Ferro needs no inbound access. A Droplet without a Cloud Firewall is reachable on every port, so attach a DigitalOcean Cloud Firewall with no inbound rules if you want it closed. Keep outbound traffic open for HTTPS, DNS, and whatever your builds download.
4. Check that the runner is online
Within a few seconds of the service starting, the node turns online in Fleet Nodes. If it does not, open the Droplet console and check the service:
sudo systemctl status ferro-agentsudo journalctl -u ferro-agent -n 50 --no-pagercurl -kfsS https://127.0.0.1:7420/healthStill offline? See Troubleshooting.
Good to know
- The same cloud-init config works on Vultr and OVHcloud. Paste it into the user data or post-installation script field when you create an Ubuntu 24.04 server there.
- Ferro does not create or scale Droplets for you. Each Droplet is a runner you register once and keep warm, which is also what keeps its dependency and build caches on local disk.
- You pay DigitalOcean for the Droplet and Ferro a flat monthly fee, with no per-minute charge from Ferro.
Next steps
- Install the CLI and offload a build with
ferro runfrom your terminal. - Connect the GitHub App so pushes and pull requests run on this server.
- Describe your pipeline in ferro.toml, including warm dependency caches.
- Read the security model before running code you do not trust.
- Other providers and Direct Mode are covered in Multi-Cloud Runners.