{"id":24054606,"url":"https://github.com/cardinal-cryptography/github-actions-runners-exporter","last_synced_at":"2026-01-28T23:02:21.759Z","repository":{"id":181204071,"uuid":"666397316","full_name":"Cardinal-Cryptography/github-actions-runners-exporter","owner":"Cardinal-Cryptography","description":"Calls GitHub API for total count of Actions' runners and exports them to be scrapped by Prometheus","archived":false,"fork":false,"pushed_at":"2024-11-15T21:47:15.000Z","size":21,"stargazers_count":0,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-15T16:42:16.257Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cardinal-Cryptography.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-07-14T12:14:19.000Z","updated_at":"2024-11-15T21:47:03.000Z","dependencies_parsed_at":"2024-01-04T02:24:09.323Z","dependency_job_id":"5012b4dd-e9c0-41a9-9c9a-69a2b62a97c4","html_url":"https://github.com/Cardinal-Cryptography/github-actions-runners-exporter","commit_stats":null,"previous_names":["cardinal-cryptography/github-actions-runners-exporter"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/Cardinal-Cryptography/github-actions-runners-exporter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fgithub-actions-runners-exporter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fgithub-actions-runners-exporter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fgithub-actions-runners-exporter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fgithub-actions-runners-exporter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cardinal-Cryptography","download_url":"https://codeload.github.com/Cardinal-Cryptography/github-actions-runners-exporter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cardinal-Cryptography%2Fgithub-actions-runners-exporter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28854438,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-28T22:56:21.783Z","status":"ssl_error","status_checked_at":"2026-01-28T22:56:00.861Z","response_time":57,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-09T03:48:58.482Z","updated_at":"2026-01-28T23:02:21.742Z","avatar_url":"https://github.com/Cardinal-Cryptography.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# github-actions-runners-exporter\nExports number of GitHub Actions' runners.  Calls GitHub API every X seconds to \nget the value.\n\n\n## Building\nRun `go build -o github-actions-runners-exporter` to compile the binary.\n\n### Building docker image\nTo build the docker image, use the following command.\n\n    docker build -t github-actions-runners-exporter .\n\n\n## Running\nCheck below help message for `run` command:\n\n    Usage:  github-actions-runners-exporter run [FLAGS]\n    \n    Runs the daemon, requires GITHUB_TOKEN environment variable\n    \n    Required flags: \n      -o,    --organization     GitHub Organization owner of the runners\n      -p,    --port         Port to expose /metrics endpoint on\n      -s,    --sleep        Seconds between each request to GitHub API\n\n\n### Example usage\n\nSet `GITHUB_TOKEN` environment variable with github token.  The token needs to\nhave read-only access to **self-hosted runners** within the \n**organizational permissions** (when using fine-grained token).\n\nRun the program in the background with the following command:\n\n    ./github-actions-runners-exporter run -o my-github-org-name -s 30 -p 8081\n\nOpen the `/metrics` endpoint to get the prometheus metrics that would include \ngithub actions' runners total count:\n\n    % curl -sSL http://127.0.0.1:8081/metrics          \n    # HELP github_actions_runners_total_count Number of running GitHub Actions' runners.\n    # TYPE github_actions_runners_total_count gauge\n    github_actions_runners_total_count 1\n    # HELP github_actions_runners_total_count_online Number of running GitHub Actions' runners with 'online' status.\n    # TYPE github_actions_runners_total_count_online gauge\n    github_actions_runners_total_count_online 0\n    # HELP go_gc_duration_seconds A summary of the pause duration of garbage collection cycles.\n    # TYPE go_gc_duration_seconds summary\n    go_gc_duration_seconds{quantile=\"0\"} 0\n    ...\n    # TYPE go_threads gauge\n    go_threads 5\n    # HELP promhttp_metric_handler_requests_in_flight Current number of scrapes being served.\n    # TYPE promhttp_metric_handler_requests_in_flight gauge\n    promhttp_metric_handler_requests_in_flight 1\n    # HELP promhttp_metric_handler_requests_total Total number of scrapes by HTTP status code.\n    # TYPE promhttp_metric_handler_requests_total counter\n    promhttp_metric_handler_requests_total{code=\"200\"} 0\n    promhttp_metric_handler_requests_total{code=\"500\"} 0\n    promhttp_metric_handler_requests_total{code=\"503\"} 0\n\n#### Running in a docker container\n\nRemember to export the `GITHUB_TOKEN` environment variable.\n\n    docker run -e GITHUB_TOKEN github-actions-runners-exporter run -o Cardinal-Cryptography -p 8081 -s 60\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcardinal-cryptography%2Fgithub-actions-runners-exporter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcardinal-cryptography%2Fgithub-actions-runners-exporter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcardinal-cryptography%2Fgithub-actions-runners-exporter/lists"}