Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gitlab_runner: enhanced runners registration #58840

Open
wants to merge 1 commit into
base: devel
from

Conversation

Projects
None yet
2 participants
@drzraf
Copy link
Contributor

commented Jul 8, 2019

SUMMARY

Support registration of runners:

  1. Of per-project scope
  2. At GitLab.com
ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

gitlab_runner

ADDITIONAL INFORMATION

The current module register runners on global scope (in particular, trying to fetch instance-wide listing of runners) what GitLab.com obviously forbids.
But runners can be registered by-project (and by-group although GitLab API does not support it yet).
By opting for project-scope, then listing and idempotent registration are allowed.
Using a (existing) project is also a convenient way to register a group runner (by providing a group registration token). This avoid the failure of requesting instance-wide runners at GitLab.com

This PR also set debug when using extra-verbose options which is quite handy, especially for such a new module.

@drzraf drzraf referenced this pull request Jul 8, 2019

Open

gitlab_runner refactor #877

@ansibot

This comment has been minimized.

Copy link
Contributor

commented Jul 8, 2019

The test ansible-test sanity --test pylint [explain] failed with 1 error:

lib/ansible/modules/source_control/gitlab_runner.py:179:56: bad-whitespace No space allowed around keyword argument assignment     def __init__(self, module, gitlab_instance, project = None):                                                         ^

The test ansible-test sanity --test pep8 [explain] failed with 2 errors:

lib/ansible/modules/source_control/gitlab_runner.py:179:56: E251 unexpected spaces around keyword / parameter equals
lib/ansible/modules/source_control/gitlab_runner.py:179:58: E251 unexpected spaces around keyword / parameter equals

The test ansible-test sanity --test validate-modules [explain] failed with 2 errors:

lib/ansible/modules/source_control/gitlab_runner.py:0:0: E322 Argument 'project' is listed in the argument_spec, but not documented in the module documentation
lib/ansible/modules/source_control/gitlab_runner.py:0:0: E337 Argument 'project' in argument_spec defines type as 'str' but documentation doesn't define type

click here for bot help

@ansibot

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.