A containerized, self-hosted GitHub Actions runner built with Docker. Designed for the big-iron-cde organization, this runner supports hardware-in-the-loop workflows with privileged container access and serial device passthrough.
- Automated runner setup – Downloads and configures the latest GitHub Actions runner at image build time.
- Dockerized workflow – Runs inside a lightweight
debian:trixie-slimcontainer. - Hardware access – Privileged mode with serial device passthrough (
/dev/ttyACM0) for embedded and hardware-in-the-loop testing. - Built-in tooling – Pre-installed Python 3, Git,
jq, and theromulanutility frombig-iron-cde/romulan. - CI/CD ready – Automated image builds and publishes to GitHub Container Registry (GHCR) via GitHub Actions.
- Docker
- Docker Compose
- A GitHub organization with self-hosted runner support
- A GitHub personal access token (PAT) with
admin:orgscope (for runner registration)
-
Clone the repository
git clone https://github.com/big-iron-cde/runner.git cd runner -
Configure environment variables
Copy the example environment file and fill in your values:
cp .env .env.local # Edit .env.local with your token and org -
Build and run
docker compose up --build
The runner will register itself with your GitHub organization and begin accepting jobs.
All runtime configuration is handled via environment variables. The table below lists the required and optional variables used by the container and entrypoint script.
| Variable | Required | Description |
|---|---|---|
RUNNER_IMAGE |
Yes | Docker image name/tag for the runner service. |
GITHUB_ORG |
Yes | GitHub organization name (e.g., big-iron-cde). |
RUNNER_TOKEN |
Yes | GitHub personal access token with admin:org scope used to generate the runner registration token. |
These values are consumed by docker-compose.yml and entrypoint.sh.
The docker-compose.yml defines a single runner service:
- Privileged mode enabled for full system access.
- Device mapping exposes
/dev/ttyACM0inside the container for serial hardware communication. - Environment sourced from your
.envfile.
# Build the image locally
docker build -t runner:latest .
# Run manually with env vars
docker run --rm -it \
-e RUNNER_ORG=https://github.com/your-org \
-e RUNNER_TOKEN=ghp_xxxxxxxxxxxx \
--privileged \
--device /dev/ttyACM0 \
runner:latestUse the pre-built image from GHCR:
services:
runner:
image: ghcr.io/big-iron-cde/runner:latest
environment:
RUNNER_ORG: https://github.com/${GITHUB_ORG}
RUNNER_TOKEN: ${RUNNER_TOKEN}
privileged: true
devices:
- /dev/ttyACM0:/dev/ttyACM0The repository includes a CI workflow (.github/workflows/build-ghcr.yml) that:
- Builds the Docker image on every SemVer tag push (
*.*.*). - Pushes the image to GHCR with both
latestand tag-based labels. - Creates a GitHub Release with auto-generated release notes.
Trigger a new release by pushing a tag:
git tag 1.0.0
git push origin 1.0.0Contributions are welcome! Please open an issue or pull request if you have improvements, bug fixes, or new features to propose.
- Fork the repository.
- Create a feature branch (
git checkout -b feature/amazing-feature). - Commit your changes (
git commit -m 'Add amazing feature'). - Push to the branch (
git push origin feature/amazing-feature). - Open a Pull Request.
This project is licensed under the MIT License.