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

api.sls 729B

12345678910111213141516171819202122232425
  1. {% from "salt/map.jinja" import salt_settings with context %}
  2. include:
  3. - salt.master
  4. salt-api:
  5. {% if salt_settings.install_packages %}
  6. pkg.installed:
  7. - name: {{ salt_settings.salt_api }}
  8. {%- if salt_settings.version is defined %}
  9. - version: {{ salt_settings.version }}
  10. {%- endif %}
  11. {% endif %}
  12. {% if salt_settings.api_service_details.state != 'ignore' %}
  13. service.{{ salt_settings.api_service_details.state }}:
  14. - enable: {{ salt_settings.api_service_details.enabled }}:
  15. - name: {{ salt_settings.api_service }}
  16. - require:
  17. - service: {{ salt_settings.master_service }}
  18. - watch:
  19. {% if salt_settings.install_packages %}
  20. - pkg: salt-api
  21. {% endif %}
  22. - file: salt-master
  23. {% endif %}