Skip to content

Commit 73f8559

Browse files
add a different folder as ec2 macos doesn't allow to write in the default one
1 parent b7b4a79 commit 73f8559

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

dist/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62811,13 +62811,13 @@ function buildUserDataScript(githubRegistrationToken, label) {
6281162811
'#!/bin/bash',
6281262812
`cd "${config.input.runnerHomeDir}"`,
6281362813
'export RUNNER_ALLOW_RUNASROOT=1',
62814-
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work "${config.input.runnerHomeDir}"`,
62814+
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work "${config.input.runnerHomeDir}" --replace`,
6281562815
'./run.sh',
6281662816
];
6281762817
} else {
6281862818
return [
6281962819
'#!/bin/bash',
62820-
'mkdir actions-runner && cd actions-runner',
62820+
'cd /opt && mkdir actions-runner && cd actions-runner',
6282162821
'case $(uname -m) in aarch64|arm64) ARCH="arm64" ;; amd64|x86_64) ARCH="x64" ;; esac && export RUNNER_ARCH=${ARCH}',
6282262822
'case $(uname -a) in Darwin*) OS="osx" ;; Linux*) OS="linux" ;; esac && export RUNNER_OS=${OS}',
6282362823
'export VERSION="2.303.0"',
@@ -62826,7 +62826,7 @@ function buildUserDataScript(githubRegistrationToken, label) {
6282662826
'export LANG=en_EN.UTF-8',
6282762827
'tar xzf ./actions-runner-${RUNNER_OS}-${RUNNER_ARCH}-${VERSION}.tar.gz',
6282862828
'export RUNNER_ALLOW_RUNASROOT=1',
62829-
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work $(pwd)`,
62829+
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work $(pwd) --replace`,
6283062830
'./run.sh',
6283162831
];
6283262832
}

src/aws.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ function buildUserDataScript(githubRegistrationToken, label) {
1111
'#!/bin/bash',
1212
`cd "${config.input.runnerHomeDir}"`,
1313
'export RUNNER_ALLOW_RUNASROOT=1',
14-
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work "${config.input.runnerHomeDir}"`,
14+
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work "${config.input.runnerHomeDir}" --replace`,
1515
'./run.sh',
1616
];
1717
} else {
1818
return [
1919
'#!/bin/bash',
20-
'mkdir actions-runner && cd actions-runner',
20+
'cd /opt && mkdir actions-runner && cd actions-runner',
2121
'case $(uname -m) in aarch64|arm64) ARCH="arm64" ;; amd64|x86_64) ARCH="x64" ;; esac && export RUNNER_ARCH=${ARCH}',
2222
'case $(uname -a) in Darwin*) OS="osx" ;; Linux*) OS="linux" ;; esac && export RUNNER_OS=${OS}',
2323
'export VERSION="2.303.0"',
@@ -26,7 +26,7 @@ function buildUserDataScript(githubRegistrationToken, label) {
2626
'export LANG=en_EN.UTF-8',
2727
'tar xzf ./actions-runner-${RUNNER_OS}-${RUNNER_ARCH}-${VERSION}.tar.gz',
2828
'export RUNNER_ALLOW_RUNASROOT=1',
29-
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work $(pwd)`,
29+
`./config.sh --url ${config.github.url} --token ${githubRegistrationToken} --labels ${label} --name ${label} --runnergroup default --work $(pwd) --replace`,
3030
'./run.sh',
3131
];
3232
}

0 commit comments

Comments
 (0)