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

29 行
705B

  1. {%- from "linux/map.jinja" import system with context %}
  2. {%- if system.enabled %}
  3. linux_packages:
  4. pkg.installed:
  5. - names: {{ system.pkgs }}
  6. {%- for name, package in system.package.iteritems() %}
  7. linux_extra_package_{{ name }}:
  8. {%- if package.version == 'latest' %}
  9. pkg.latest:
  10. {%- else %}
  11. pkg.installed:
  12. - version: {{ package.version }}
  13. {%- endif %}
  14. - name: {{ name }}
  15. {%- if package.repo is defined %}
  16. - fromrepo: {{ package.repo }}
  17. {%- endif %}
  18. {%- if package.hold is defined %}
  19. - hold: {{ package.hold }}
  20. {%- endif %}
  21. {%- if package.verify is defined %}
  22. - skip_verify: {% if package.verify %}false{% else %}true{% endif %}
  23. {%- endif %}
  24. {%- endfor %}
  25. {%- endif %}