gitea act_runner is now runner
Rename all scripts to gitea-runner and remove all act_runner references. - rename all scripts - rename systemd service file Note that the older service needs to be remove and re-installed the /etc folder is now /etc/gitea-runner instead of /etc/act_runner
This commit is contained in:
@@ -39,13 +39,13 @@ if [ ! -f "${target_file}" ]; then
|
|||||||
echo "[!] There is no gitea target file at ${target_file}. Is gitea installed?";
|
echo "[!] There is no gitea target file at ${target_file}. Is gitea installed?";
|
||||||
gitea_exists=0;
|
gitea_exists=0;
|
||||||
fi;
|
fi;
|
||||||
target_file_act_runner="/usr/local/bin/act_runner";
|
target_file_gitea_runner="/usr/local/bin/gitea-runner";
|
||||||
act_runner_exists=1
|
gitea_runner_exists=1
|
||||||
if [ ! -f "${target_file_act_runner}" ]; then
|
if [ ! -f "${target_file_gitea_runner}" ]; then
|
||||||
echo "[!] There is no gitea action runner target file at ${target_file_act_runner}. Is gitea action runner installed?";
|
echo "[!] There is no gitea runner target file at ${target_file_gitea_runner}. Is gitea runner installed?";
|
||||||
act_runner_exists=0
|
gitea_runner_exists=0
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
export arch target_file gitea_exists act_runner_exists;
|
export arch target_file gitea_exists gitea_runner_exists;
|
||||||
|
|
||||||
# __END__
|
# __END__
|
||||||
|
|||||||
@@ -1,24 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
BASE_FOLDER=$(dirname "$(readlink -f "$0")")"/";
|
|
||||||
# shellcheck source=init.sh
|
|
||||||
. "${BASE_FOLDER}init.sh";
|
|
||||||
|
|
||||||
if [ -z "${1}" ]; then
|
|
||||||
echo "Please give a Gitea Action Runner version to upgrade to";
|
|
||||||
exit;
|
|
||||||
fi;
|
|
||||||
file_name="${download_folder}act_runner-${1}-${arch}.xz";
|
|
||||||
if [ ! -f "${file_name}" ]; then
|
|
||||||
echo "Cannot find file: ${file_name}";
|
|
||||||
exit;
|
|
||||||
fi;
|
|
||||||
|
|
||||||
echo -e "Update gitea action runner to ${1} ... ";
|
|
||||||
systemctl stop act_runner;
|
|
||||||
xz -dc "${file_name}" > "${target_file_act_runner}";
|
|
||||||
chmod +x "${target_file_act_runner}";
|
|
||||||
systemctl start act_runner;
|
|
||||||
echo "[DONE]";
|
|
||||||
|
|
||||||
# __END__
|
|
||||||
Executable
+24
@@ -0,0 +1,24 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
BASE_FOLDER=$(dirname "$(readlink -f "$0")")"/";
|
||||||
|
# shellcheck source=init.sh
|
||||||
|
. "${BASE_FOLDER}init.sh";
|
||||||
|
|
||||||
|
if [ -z "${1}" ]; then
|
||||||
|
echo "Please give a Gitea Runner version to upgrade to";
|
||||||
|
exit;
|
||||||
|
fi;
|
||||||
|
file_name="${download_folder}gitea-runner-${1}-${arch}.xz";
|
||||||
|
if [ ! -f "${file_name}" ]; then
|
||||||
|
echo "Cannot find file: ${file_name}";
|
||||||
|
exit;
|
||||||
|
fi;
|
||||||
|
|
||||||
|
echo -e "Update gitea runner to ${1} ... ";
|
||||||
|
systemctl stop gitea-runner;
|
||||||
|
xz -dc "${file_name}" > "${target_file_gitea_runner}";
|
||||||
|
chmod +x "${target_file_gitea_runner}";
|
||||||
|
systemctl start gitea-runner;
|
||||||
|
echo "[DONE]";
|
||||||
|
|
||||||
|
# __END__
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=Gitea Actions runner
|
|
||||||
Documentation=https://gitea.com/gitea/act_runner
|
|
||||||
After=docker.service
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
ExecStart=/usr/local/bin/act_runner daemon --config /etc/act_runner/config.yaml
|
|
||||||
ExecReload=/bin/kill -s HUP $MAINPID
|
|
||||||
WorkingDirectory=/var/lib/act_runner
|
|
||||||
TimeoutSec=0
|
|
||||||
RestartSec=10
|
|
||||||
Restart=always
|
|
||||||
User=act_runner
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=multi-user.target
|
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Gitea Runner
|
||||||
|
Documentation=https://gitea.com/gitea/runner
|
||||||
|
After=docker.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
ExecStart=/usr/local/bin/gitea-runner daemon --config /etc/gitea-runner/config.yaml
|
||||||
|
ExecReload=/bin/kill -s HUP $MAINPID
|
||||||
|
WorkingDirectory=/var/lib/gitea-runner
|
||||||
|
TimeoutSec=0
|
||||||
|
RestartSec=10
|
||||||
|
Restart=always
|
||||||
|
User=gitea-runner
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
Reference in New Issue
Block a user