Saltstack Official FirewallD Formula
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

config.sls 827B

12345678910111213141516171819202122232425262728293031
  1. # == State: firewalld._config
  2. #
  3. # This state configures firewalld.
  4. #
  5. {% from "firewalld/map.jinja" import firewalld with context %}
  6. directory_firewalld:
  7. file.directory: # make sure this is a directory
  8. - name: /etc/firewalld
  9. - user: root
  10. - group: root
  11. - mode: 750
  12. - require:
  13. - pkg: package_firewalld # make sure package is installed
  14. - listen_in:
  15. - module: service_firewalld # restart service
  16. config_firewalld:
  17. file.managed:
  18. - name: /etc/firewalld/firewalld.conf
  19. - user: root
  20. - group: root
  21. - mode: 640
  22. - source: salt://firewalld/files/firewalld.conf
  23. - template: jinja
  24. - require:
  25. - pkg: package_firewalld # make sure package is installed
  26. - file: directory_firewalld
  27. - listen_in:
  28. - module: service_firewalld # restart service