Note
This plugin is part of the community.general collection (version 2.0.1).
To install it use: ansible-galaxy collection install community.general
.
To use it in a playbook, specify: community.general.gitlab_group_members
.
New in version 1.2.0: of community.general
The below requirements are needed on the host that executes this module.
Parameter | Choices/Defaults | Comments |
---|---|---|
access_level string |
| The access level for the user. Required if state=present, user state is set to present. |
api_password string | The password to use for authentication against the API | |
api_token string / required | A personal access token to authenticate with the GitLab API. | |
api_url string | The resolvable endpoint for the API | |
api_username string | The username to use for authentication against the API | |
gitlab_group string / required | The name of the GitLab group the member is added to/removed from. | |
gitlab_user string / required | The username of the member to add to/remove from the GitLab group. | |
state string |
| State of the member in the group. On present , it adds a user to a GitLab group.On absent , it removes a user from a GitLab group. |
validate_certs boolean |
| Whether or not to validate SSL certs when supplying a https endpoint. |
Note
check_mode
.- name: Add a user to a GitLab Group community.general.gitlab_group_members: api_url: 'https://gitlab.example.com' api_token: 'Your-Private-Token' gitlab_group: groupname gitlab_user: username access_level: developer state: present - name: Remove a user from a GitLab Group community.general.gitlab_group_members: api_url: 'https://gitlab.example.com' api_token: 'Your-Private-Token' gitlab_group: groupname gitlab_user: username state: absent
© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.11/collections/community/general/gitlab_group_members_module.html