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:
Executable
+24
@@ -0,0 +1,24 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
BASE_FOLDER=$(dirname "$(readlink -f "$0")")"/";
|
||||
# shellcheck source=init.sh
|
||||
. "${BASE_FOLDER}init.sh";
|
||||
|
||||
download_file=$(curl -s https://gitea.com/api/v1/repos/gitea/runner/releases/latest |\
|
||||
jq ".assets[].browser_download_url" |\
|
||||
sed -e 's/"//g' |\
|
||||
grep "${arch}.xz$");
|
||||
version=$(echo "${download_file}" | cut -d "/" -f 8);
|
||||
file=$(echo "${download_file}" | cut -d "/" -f 9);
|
||||
if [ -f "${download_folder}/${file}" ]; then
|
||||
echo "[!] File ${file} has already been downloaded";
|
||||
exit;
|
||||
fi;
|
||||
echo "act_runner version to download: ${version}";
|
||||
|
||||
cd "${download_folder}" || exit;
|
||||
echo "${download_file}" |\
|
||||
xargs curl -LJO --output-dir "${download_folder}"
|
||||
cd - || exit;
|
||||
|
||||
# __END__
|
||||
Reference in New Issue
Block a user