Saltstack Official Linux Formula
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

30 行
545B

  1. {%- from "linux/map.jinja" import system with context %}
  2. {%- if system.enabled %}
  3. {%- for group_name, group in system.group.iteritems() %}
  4. {%- if group.enabled %}
  5. system_group_{{ group_name }}:
  6. group.present:
  7. - name: {{ group.name }}
  8. {%- if group.system is defined and group.system %}
  9. - system: True
  10. {%- endif %}
  11. {%- if group.gid is defined and group.gid %}
  12. - gid: {{ group.gid }}
  13. {%- endif %}
  14. {%- else %}
  15. system_group_{{ group_name }}:
  16. group.absent:
  17. - name: {{ group.name }}
  18. {%- endif %}
  19. {%- endfor %}
  20. {%- endif %}