File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -26,8 +26,9 @@ function buildUserDataScript(githubRegistrationToken, label) {
2626 `echo "${ config . input . preRunnerScript } " > pre-runner-script.sh` ,
2727 'source pre-runner-script.sh' ,
2828 'case $(uname -m) in aarch64) ARCH="arm64" ;; amd64|x86_64) ARCH="x64" ;; esac && export RUNNER_ARCH=${ARCH}' ,
29- 'curl -O -L https://github.com/actions/runner/releases/download/v2.313.0/actions-runner-linux-${RUNNER_ARCH}-2.313.0.tar.gz' ,
30- 'tar xzf ./actions-runner-linux-${RUNNER_ARCH}-2.313.0.tar.gz' ,
29+ 'RUNNER_VERSION=$(curl -s "https://api.github.com/repos/actions/runner/releases/latest" | jq -r ".name" | tr -d "v")' ,
30+ 'curl -O -L https://github.com/actions/runner/releases/download/v${RUNNER_VERSION}/actions-runner-linux-${RUNNER_ARCH}-${RUNNER_VERSION}.tar.gz' ,
31+ 'tar xzf ./actions-runner-linux-${RUNNER_ARCH}-${RUNNER_VERSION}.tar.gz' ,
3132 'export RUNNER_ALLOW_RUNASROOT=1' ,
3233 `./config.sh --url https://github.com/${ config . githubContext . owner } /${ config . githubContext . repo } --token ${ githubRegistrationToken } --labels ${ label } ` ,
3334 ] ;
@@ -192,4 +193,4 @@ module.exports = {
192193 startEc2Instance,
193194 terminateEc2Instance,
194195 waitForInstanceRunning,
195- } ;
196+ } ;
You can’t perform that action at this time.
0 commit comments