Sign inSign up

safeimages/dind-runner

By safeimages

•Updated about 2 years ago

This Docker image is designed to be used as a self-hosted runner for GitHub Actions.

Image
Developer tools
0

325

safeimages/dind-runner repository overview

⁠GitHub Self-Hosted Runner in Docker

This Docker image provides a self-hosted runner for GitHub Actions, with support for Docker-in-Docker (DIND) functionality.

⁠What is this image?

This Docker image is designed to be used as a self-hosted runner for GitHub Actions. It includes the necessary components to run GitHub Actions workflows, including the ability to execute Docker commands within the runner container (DIND).

The image is based on the official docker:27-dind image, which provides the Docker-in-Docker functionality. The self-hosted runner is then added on top of this base image.

⁠How to use this image

To use this image, you'll need to have Docker and Docker Compose installed on your host system. Follow these steps:

  1. Clone the repository:

    git clone [email protected]:brnorg/safeimages-dind-runner.git
    
  2. Update the environment variables in the docker-compose.yml file:

    • TOKEN: Your GitHub personal access token with the necessary permissions to register a self-hosted runner.
    • ORG: The GitHub organization name, or REPO if you want to register the runner for a specific repository.
    • TAG: The tags to be associated with the runner.
  3. Start the Docker Compose setup:

    docker-compose up -d
    

    This will start the Docker-in-Docker (DIND) service and the self-hosted runner container.

  4. Register the runner on GitHub:

    • Go to your GitHub organization or repository settings.
    • Navigate to the "Actions" section and click on "Runners".
    • Click on "New runner" and follow the instructions to download and configure the runner.
  5. Once the runner is registered, it will automatically start running any workflows that are triggered.

⁠Environment Variables

  • TOKEN: Your GitHub personal access token with the necessary permissions to register a self-hosted runner.
  • ORG: The GitHub organization name, or REPO if you want to register the runner for a specific repository.
  • TAG: The tags to be associated with the runner.

⁠Volumes

  • docker-certs-ca: Stores the Docker TLS CA certificates.
  • docker-certs-client: Stores the Docker TLS client certificates.

⁠Networking

The image uses a custom Docker network named container-network to allow communication between the DIND service and the self-hosted runner container.

Tag summary

Content type

Image

Digest

sha256:b102cab3d…

Size

1.1 GB

Last updated

about 2 years ago

docker pull safeimages/dind-runner:1.6