Saltstack Official FirewallD Formula
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 satır
1.2KB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!--
  3. This file is managed/generated by salt.
  4. Do not edit this file manually, it will be overwritten!
  5. Modify the salt pillar for firewalld instead
  6. -->
  7. <service version="1">
  8. {% if 'short' in service %}<short>{{ service.short }}</short>{%- else %}<short>{{ name }}</short>{%- endif %}
  9. {% if 'description' in service %}<description>{{ service.description }}</description>{%- endif %}
  10. {%- if 'ports' in service %}
  11. {%- if 'tcp' in service.ports %}
  12. {%- for v in service.ports.tcp %}
  13. <port port="{{ v }}" protocol="tcp" />
  14. {%- endfor %}
  15. {%- endif %}
  16. {%- if 'udp' in service.ports %}
  17. {%- for v in service.ports.udp %}
  18. <port port="{{ v }}" protocol="udp" />
  19. {%- endfor %}
  20. {%- endif %}
  21. {%- if 'modules' in service %}
  22. {%- for v in service.modules %}
  23. <module name="{{ v }}" />
  24. {%- endfor %}
  25. {%- endif %}
  26. {%- endif %}
  27. {%- if 'destinations' in service %}
  28. {%- if 'ipv4' in service.destinations %}
  29. {%- for v in service.destinations.ipv4 %}
  30. <destination ipv4="{{ v }}" />
  31. {%- endfor %}
  32. {%- endif %}
  33. {%- if 'ipv6' in service.destinations %}
  34. {%- for v in service.destinations.ipv6 %}
  35. <destination ipv6="{{ v }}" />
  36. {%- endfor %}
  37. {%- endif %}
  38. {%- endif %}
  39. </service>