Closed guidoiaquinti closed 5 months ago
Hi @guidoiaquinti, could you double check the permissions of your GitHub token and repository URL? Here is the code where it is failing for you https://github.com/testflows/TestFlows-GitHub-Hetzner-Runners/blob/main/testflows/github/hetzner/runners/scale_up.py#L118.
Please make sure you set all three environment variables to the values that correspond to your project. Specifically, the GITHUB_REPOSITORY should specify your project's repository for which you have created a GITHUB_TOKEN that has the correct permissions. See https://github.com/testflows/TestFlows-GitHub-Hetzner-Runners?tab=readme-ov-file#getting-started-tutorial for more details.
For example,
export GITHUB_TOKEN=ghp_...
export GITHUB_REPOSITORY=...
export HETZNER_TOKEN=GJzdc...
github-hetzner-runners cloud deploy
I've doubled checked against my https://github.com/vzakaznikov/demo-testflows-github-hetzner-runners/ repository by deploying new cloud service and everything works as expected.
Please let me know if you still can't get it to work. You could dump full logs by running github-hetzner-runners cloud log
command. Also, don't forget to delete any servers after any trial runs using github-hetzner-runners delete
and github-hetzner-runners cloud delete
commands.
š Hi everyone! Thank you for your help. I discovered that the issue was indeed related to the type of token used: I initially created a "Fine-grained token" instead of a "Token (classic)," which caused the problem.
The fine-grained tokens could work, but I haven't tried using them yet to see what specific permissions they need.
I've tried different combinations of permissions for the fine-grained tokens but none work. So yes, fine-graned tokens can't be used.
I've tried different combinations of permissions for the fine-grained tokens but none work. So yes, fine-graned tokens can't be used.
Thank you for double checking! š
š Hi! First of all, nice project! I've tried to deploy the service using your documentation. I can see the VM provisioned correctly but it's failing to register as GitHub self-hosted runner. Here's the log from
github-hetzner-runners cloud status
:Version