macunha1 / ansible-github-actions-runner Goto Github PK
View Code? Open in Web Editor NEWIdempotent Ansible role that installs and configures self-hosted GitHub Actions Runners (yeah, plural!)
License: MIT License
Idempotent Ansible role that installs and configures self-hosted GitHub Actions Runners (yeah, plural!)
License: MIT License
I was trying to create multiple github runnner for an Org, using indididual repo keys,
- name: Install Runner1 on github-runners-ubuntu
hosts: github-runners-ubuntu
roles:
- role: ansible-github-actions-runner
vars:
gh_runner_config_labels:
- ubuntu22
- linux
- self-hosted
gh_runner_config_url: https://github.com/acme.net
gh_runner_config_token: APERFECTLYFINETOKEN
gh_runner_config_name: ubuntu-runner1
gh_runner_allow_runasroot: "Refuse"
- role: ansible-github-actions-runner
vars:
gh_runner_config_labels:
- ubuntu22
- linux
- self-hosted
gh_runner_config_url: https://github.com/acme.net
gh_runner_config_token: ANOTHERPERFECTLYFINETOKEN
gh_runner_config_name: ubuntu-runner2
gh_runner_allow_runasroot: "Refuse"
I expected this to create two runners for on the host and that they both would be online.
Instead it replaced the first runner with the second one.
Ive been looking at the code to understand why its replacing the existing one instead of generating a separate one, but Im not able to figure it out as of yet so figured Id put in an Issue.
Hi, thanks for this runner. I was able to create and register the runner but when I want to uninstall it, it says "must not run with sudo"
which config should I change so this step wont return error?
this is what I put into my yml
- hosts: all
roles:
- role: roles/macunha1.github_actions_runner
vars:
gh_runner_config_labels:
- linux
- self-hosted
gh_runner_remove_host: true
gh_runner_allow_runasroot: "0"
gh_runner_config_url: some_repo
gh_runner_config_token: some_token
Hi,
This looks like a great ansible role!
I occasionally need to install a set of runners across multiple platforms: Linux, MacOS, Windows. There are multiple ways to add Windows, perhaps the easiest one would be in main.yml where there are three includes, add three more includes such as "../includes-win/install.yaml". Conditionally check on the operating system for all the includes. Would you be interested in a pull request which adds such functionality? Another option is less integrated. Clone the role, modify everything to support (only) windows. Then there are two separate Ansible roles.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.