fix: gitea runner

This commit is contained in:
2026-09-03 06:49:45 +00:00
parent fd6c9536e7
commit 27ccff23f3
2 changed files with 65 additions and 1 deletions
+12 -1
View File
@@ -25,7 +25,18 @@ gcr_gitea_list_runners() {
token="$(gcr_gitea_admin_token)" || return 1
curl -fsS -H "Authorization: token $token" \
"$GCR_GITEA_URL/api/v1/orgs/hectic-lab/actions/runners?per_page=50" \
| jq -r '.entries[] | "\(.id) \(.name)"'
| jq -r '.entries[]? | "\(.id) \(.name)"'
}
# gcr_gitea_job_state REPO JOB_ID — prints "<status>:<conclusion>".
gcr_gitea_job_state() {
repo="$1"; job_id="$2"
token="$(gcr_gitea_admin_token)" || return 1
owner="${repo%%/*}"
name="${repo#*/}"
curl -fsS -H "Authorization: token $token" \
"$GCR_GITEA_URL/api/v1/repos/$owner/$name/actions/jobs/$job_id" \
| jq -r '.status + ":" + (.conclusion // "")'
}
gcr_gitea_delete_runner() {