mirror of
https://github.com/saltstack-formulas/users-formula.git
synced 2024-12-18 10:32:55 +01:00
Merge pull request #11 from w3w/fix-multiple-groups
SLS no longer fails for multiple groups
This commit is contained in:
commit
4e1c754183
@ -14,7 +14,7 @@ include:
|
|||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
|
||||||
{% for group in user.get('groups', []) %}
|
{% for group in user.get('groups', []) %}
|
||||||
{{ group }}_group:
|
{{ name }}_{{ group }}_group:
|
||||||
group:
|
group:
|
||||||
- name: {{ group }}
|
- name: {{ group }}
|
||||||
- present
|
- present
|
||||||
@ -87,7 +87,7 @@ user_{{ name }}_private_key:
|
|||||||
- require:
|
- require:
|
||||||
- user: {{ name }}_user
|
- user: {{ name }}_user
|
||||||
{% for group in user.get('groups', []) %}
|
{% for group in user.get('groups', []) %}
|
||||||
- group: {{ group }}_group
|
- group: {{ name }}_{{ group }}_group
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
user_{{ name }}_public_key:
|
user_{{ name }}_public_key:
|
||||||
file.managed:
|
file.managed:
|
||||||
@ -99,7 +99,7 @@ user_{{ name }}_public_key:
|
|||||||
- require:
|
- require:
|
||||||
- user: {{ name }}_user
|
- user: {{ name }}_user
|
||||||
{% for group in user.get('groups', []) %}
|
{% for group in user.get('groups', []) %}
|
||||||
- group: {{ group }}_group
|
- group: {{ name }}_{{ group }}_group
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user