Skip to content

Display runners status #5

Display runners status

Display runners status #5

name: "Generate runners status"
on:
push:
schedule:
- cron: '0 * * * *' # Run every hour
workflow_dispatch: # Manually triggered via GitHub Actions UI
concurrency:
group: redirector
cancel-in-progress: false
jobs:
Check:
name: "Check permissions"
runs-on: "ubuntu-24.04"
steps:
- name: "Check permissions"
uses: armbian/actions/team-check@main
with:
ORG_MEMBERS: ${{ secrets.ORG_MEMBERS }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TEAM: "Release manager"
build:
name: "Get source of truth"
runs-on: ubuntu-24.04
needs: Check
steps:
- name: "Install dependencies: jq"
uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: jq
version: 1.0
- name: "Get runners from ORG"
env:
GH_TOKEN: ${{ secrets.ACCESS_TOKEN }}
run: |
# get runners
for i in `seq 0 1 10`; do
gh api \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
/orgs/${{ github.repository_owner }}/actions/runners
done