mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
improve change reporting for postgres_user groups
This commit is contained in:
parent
8712bce91a
commit
bc90c5bffe
1 changed files with 3 additions and 2 deletions
|
@ -192,8 +192,9 @@ def present(name,
|
|||
if isinstance(groups, (six.string_types, six.text_type)):
|
||||
lgroups = lgroups.split(',')
|
||||
if isinstance(lgroups, list):
|
||||
if [a for a in lgroups if a not in user_groups]:
|
||||
update = True
|
||||
missing_groups = [a for a in lgroups if a not in user_groups]
|
||||
if missing_groups:
|
||||
update['groups'] = missing_groups
|
||||
|
||||
if mode == 'create' or (mode == 'update' and update):
|
||||
if __opts__['test']:
|
||||
|
|
Loading…
Add table
Reference in a new issue