Work in progress: a GitHub runner as a Portainer stack
A self-hosted GitHub Actions runner as a single Portainer stack that moves long CI jobs onto your own hardware. Still in progress.
by NoiXdev
You look at your Actions bill and almost all of it comes from one job. Usually it’s the browser tests. This project moves exactly that job onto a machine of your own.
The Portainer GitHub Runner packages your own runner as a Portainer stack. Point it at a repository, fill in the variables, deploy. The fast jobs stay on GitHub, so a push still gets its verdict when your server is off.
Let’s be upfront: this is a work in progress. No job has run end to end on it yet. Also, the runner uses the host’s Docker socket, which means root on that machine. For a private repository and people you trust, that’s a fair trade. For a public one it isn’t.
What it does
- One stack. Two services and one block of variables in Portainer. No build step.
- A label of its own. Only the jobs you meant for it end up here.
- Cleans up after itself. Old images, build cache and stopped containers are pruned regularly. Volumes are left alone.
- No restarts mid-job. The stack opts out of Watchtower.
Get started
Everything else is on the project page and in the documentation. Read the security section before you deploy.