Allow registration of runners via API

Description

Setting up a GitLab CI runner requires an admin to retrieve the GitLab CI registration token from the admin dashboard. This means the runner cannot be automatically deployed without pre-setting the runners token as an ENV var or in config.toml

Proposal

Provide an API endpoint to register a runner by POSTing to /runners with a PAT:

  1. Admin would be allowed to register any kind of runner: shared or project/group specific
  2. User would be allowed to register only project/group specific runner if he has master access

Links / references

  • https://gitlab.zendesk.com/agent/tickets/46603

  • https://docs.debops.org/en/latest/ansible/roles/ansible-gitlab_runner/docs/getting-started.html

//cc @zj @ayufan @grzesiek

Edited Oct 03, 2018 by Jason Yavorsky
Assignee Loading
Time tracking Loading