Runner sizes
The runs-on labels, what each machine has, and how to pick a size.
Put one of these labels in a job's runs-on. Every size runs Ubuntu 24.04 on x64, with Docker. Jobs run as root.
| Label | vCPU | Memory | Disk | Per minute | Per hour |
|---|---|---|---|---|---|
raft-ubuntu-24.04-xsmall | 0.5 | 1 GB | 20 GB | $0.000075 | $0.0045 |
raft-ubuntu-24.04-small | 1 | 2 GB | 20 GB | $0.00015 | $0.009 |
raft-ubuntu-24.04 | 2 | 4 GB | 20 GB | $0.0003 | $0.018 |
raft-ubuntu-24.04-4 | 4 | 8 GB | 40 GB | $0.0006 | $0.036 |
raft-ubuntu-24.04-8 | 8 | 16 GB | 100 GB | $0.0012 | $0.072 |
raft-ubuntu-24.04-16 | 16 | 32 GB | 200 GB | $0.003333 | $0.20 |
raft-ubuntu-latest is an alias for raft-ubuntu-24.04, and raft-ubuntu-latest-4 and the others work the same way.
Pick a size
- Lint, small tests, deploy scripts:
raft-ubuntu-24.04-xsmall(half a vCPU, 1 GB) orraft-ubuntu-24.04-small(1 vCPU, 2 GB). A job that mostly waits on the network gains nothing from more cores. - Builds and test suites:
raft-ubuntu-24.04-4or-8. Compilers and test runners that use every core finish about twice as fast for each doubling, so the cost stays close to the same. - Big Docker builds or large images:
-4or larger, for the disk. The two smallest have 20 GB. - Not sure: start with
raft-ubuntu-24.04. After a few runs, Analytics tells you which jobs ran out of memory and should go up, and which idled and can go down.
What is on the machine
A clean Ubuntu 24.04 with Docker, git, curl and the GitHub Actions runner. It is not GitHub's runner image, which preinstalls dozens of languages and tools. Install what a job needs with the usual setup actions; they download in seconds and, with the cache on, restore dependencies from the last run.
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- run: npm ci && npm testEach machine runs one job and is then deleted. Nothing carries over between jobs, including from one job of a matrix to the next.
Spread a suite across machines
A matrix runs each entry on its own machine at once. Four 4 vCPU shards often finish sooner, for the same cost, than one 16 vCPU job.
jobs:
test:
strategy:
matrix:
shard: [1, 2, 3, 4]
runs-on: raft-ubuntu-24.04-4
steps:
- uses: actions/checkout@v4
- run: npm test -- --shard=${{ matrix.shard }}/4How many run at once is capped by your workspace's concurrency limit; the rest wait in the queue. See Limits and timeouts.
Billing
By the second, from when a machine picks up the job until the job ends, with no one-minute minimum. Time in the queue and while the machine starts are free. A 3 minute 20 second job on raft-ubuntu-24.04-4 costs 200 seconds at its per-minute price.