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

31 行
1.0KB

  1. # -*- coding: utf-8 -*-
  2. # vim: ft=jinja
  3. {#- Start with defaults from defaults.yaml #}
  4. {% import_yaml "firewalld/defaults.yaml" as default_settings %}
  5. {% import_yaml "firewalld/osarchmap.yaml" as osarchmap %}
  6. {% import_yaml "firewalld/osfamilymap.yaml" as osfamilymap %}
  7. {% import_yaml "firewalld/osmap.yaml" as osmap %}
  8. {% import_yaml "firewalld/osfingermap.yaml" as osfingermap %}
  9. {% set _config = salt['config.get']('firewalld', default={}) %}
  10. {% set defaults = salt['grains.filter_by'](default_settings,
  11. default='firewalld',
  12. merge=salt['grains.filter_by'](osarchmap, grain='osarch',
  13. merge=salt['grains.filter_by'](osfamilymap, grain='os_family',
  14. merge=salt['grains.filter_by'](osmap, grain='os',
  15. merge=salt['grains.filter_by'](osfingermap, grain='osfinger',
  16. merge=salt['grains.filter_by'](_config, default='lookup')
  17. )
  18. )
  19. )
  20. )
  21. ) %}
  22. {% set firewalld = salt['grains.filter_by'](
  23. {'defaults': defaults},
  24. default='defaults',
  25. merge=_config
  26. ) %}