mirror of
https://github.com/ansible-collections/community.mysql.git
synced 2025-04-18 16:31:26 -07:00
mysql_role - don't add members to a role when creating the role and detach_members true is set (#372)
Co-authored-by: betanummeric <40263343+betanummeric@users.noreply.github.com>
This commit is contained in:
parent
e34cfba109
commit
46dc308e28
4 changed files with 33 additions and 0 deletions
|
@ -119,6 +119,7 @@ seealso:
|
|||
|
||||
author:
|
||||
- Andrew Klychkov (@Andersson007)
|
||||
- Felix Hamme (@betanummeric)
|
||||
|
||||
extends_documentation_fragment:
|
||||
- community.mysql.mysql
|
||||
|
@ -1006,6 +1007,8 @@ def main():
|
|||
try:
|
||||
if state == 'present':
|
||||
if not role.exists:
|
||||
if detach_members:
|
||||
members = None # avoid adding unwanted members
|
||||
changed = role.add(members, priv, module.check_mode, admin,
|
||||
set_default_role_all)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue