GitHub Actions self-hosted runners allow you to run CI/CD workflows on your own hardware, giving you full control over the environment, installed tools, network access, and compute resources. This guide registers and configures a GitHub Actions self-hosted runner on Ubuntu 26.04 LTS.
Tested and valid on:
- Ubuntu 26.04 LTS
Prerequisites
- Ubuntu 26.04 LTS
- A GitHub repository or organisation where you have admin access
- A user with sudo privileges
Step 1 – Create a Runner User (recommended)
sudo useradd -m -s /bin/bash ghrunner
sudo usermod -aG sudo,docker ghrunner
sudo su - ghrunner
Step 2 – Download the Runner
In GitHub, navigate to your repo → Settings → Actions → Runners → New self-hosted runner. Select Linux x64 and follow the download commands:
mkdir actions-runner && cd actions-runner
curl -o actions-runner-linux-x64.tar.gz -L
https://github.com/actions/runner/releases/latest/download/actions-runner-linux-x64.tar.gz
tar xzf actions-runner-linux-x64.tar.gz
Step 3 – Configure the Runner
./config.sh --url https://github.com/YOUR_ORG/YOUR_REPO --token YOUR_TOKEN
Accept the defaults or set a custom runner name and labels.
Step 4 – Install as a systemd Service
sudo ./svc.sh install ghrunner
sudo ./svc.sh start
sudo ./svc.sh status
Step 5 – Verify in GitHub
In GitHub, go to Settings → Actions → Runners. Your runner should show as Idle.
Step 6 – Use the Runner in a Workflow
# .github/workflows/ci.yml
name: CI
on: push
jobs:
build:
runs-on: self-hosted
steps:
- uses: actions/checkout@v4
- run: echo 'Running on self-hosted Ubuntu 26.04!'
Step 7 – Update the Runner
sudo ./svc.sh stop
cd ~/actions-runner
curl -o actions-runner-linux-x64.tar.gz -L https://github.com/actions/runner/releases/latest/download/actions-runner-linux-x64.tar.gz
tar xzf actions-runner-linux-x64.tar.gz
sudo ./svc.sh start
Conclusion
Your Ubuntu 26.04 LTS server is now a GitHub Actions self-hosted runner. Assign it custom labels to target it from specific workflows, and consider using ephemeral runners in Docker containers for isolated build environments.