'Error registering Gitlab Runner in Mac. forbidden

I have been trying to register a gitlab runner in my Mac but I keep getting errors saying it is forbidden. I was able to register on windows but for some reason it doesn't work on my Mac. These are the steps I take:

gitlab-runner register \
>   --non-interactive \
>   --url "https://gitlab.com/" \
>   --registration-token "token" \
>   --description "MyApp runner with shell" \
>   --tag-list ios \
>   --executor "shell"
Runtime platform                                    arch=amd64 os=darwin pid=3868    revision=98daeee0 version=14.7.0
WARNING: Running in user-mode.                     
WARNING: Use sudo for system-mode:                 
WARNING: $ sudo gitlab-runner...                   
                                               
ERROR: Registering runner... forbidden (check registration token)  runner=WswE4
PANIC: Failed to register the runner. You may be having network problems.

I am using the right token. I tried registering with docker and manually in Mac and both failed. Any help?



Solution 1:[1]

Unless you are registering a GitLab runner to a secondary node (issue 350755) or you have a problem with a reset token (issue 351114), that seems to be a bug which should be reported.

An issues search does not show many other cases where "Registering runner... forbidden".

Check also the logs in case of any recorded error message linked to your command there.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 VonC