Description
Bug
API to register a new self-hosted-runner has been updated, and corresponding change in new runner registration is missing.
Earlier it used :
https://github.com/actions/runner/blob/main/scripts/create-latest-svc.sh#L132
export RUNNER_TOKEN=$(curl -s -X POST ${base_api_url}/${orgs_or_repos}/${runner_scope}/actions/runners/registration-token -H "accept: application/vnd.github.everest-preview+json" -H "authorization: token ${RUNNER_CFG_PAT}" | jq -r '.token')
to generate a token .
However new API looks like this:
curl -L -X POST -H "Accept: application/vnd.github+json" -H "Authorization: Bearer ${RUNNER_CFG_PAT}" -H "X-GitHub-Api-Version: 2022-11-28" https://${base_api_url}/${orgs_or_repos}/${runner_scope}/actions/runners/registration-token
To Fix
https://github.com/actions/runner/blob/main/scripts/create-latest-svc.sh#L132 needs to be updated with the new curl cmd