From c75213effb68294c7845cdc55d8ca517906e22a9 Mon Sep 17 00:00:00 2001 From: Alejandro Lembke Barrientos Date: Thu, 9 Nov 2023 22:47:10 +0000 Subject: [PATCH] Returning to use organizations. --- README.md | 2 +- start.sh | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 5edc2b5..03860bd 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ # Docker Github Action Runner -## Version 1.0.1 \ No newline at end of file +## Version 1.0.2 \ No newline at end of file diff --git a/start.sh b/start.sh index e9226e2..7bbed02 100644 --- a/start.sh +++ b/start.sh @@ -1,14 +1,13 @@ #!/bin/bash -OWNER=$OWNER -REPO=$REPO +ORGANIZATION=$ORGANIZATION ACCESS_TOKEN=$ACCESS_TOKEN -REG_TOKEN=$(curl -sX POST -H "Authorization: token ${ACCESS_TOKEN}" https://api.github.com/repos/${OWNER}/${REPO}/actions/runners/registration-token | jq .token --raw-output) +REG_TOKEN=$(curl -sX POST -H "Authorization: token ${ACCESS_TOKEN}" https://api.github.com/orgs/${ORGANIZATION}/actions/runners/registration-token | jq .token --raw-output) cd /home/docker/actions-runner -./config.sh --url https://github.com/${OWNER}/${REPO} --token ${REG_TOKEN} +./config.sh --url https://github.com/${ORGANIZATION} --token ${REG_TOKEN} cleanup() { echo "Removing runner..."