paulbsd-salt/states/haproxy/config.sls

51 lines
1.4 KiB
Plaintext
Raw Normal View History

2022-10-01 20:06:19 +02:00
---
{%- from "haproxy/map.jinja" import haproxy with context %}
2024-09-01 14:50:42 +02:00
{% for map in haproxy.config.maps %}
2023-06-23 08:47:25 +02:00
haproxy-maps-{{ map }}:
2022-12-11 16:34:27 +01:00
file.managed:
2023-06-23 08:47:25 +02:00
- name: {{ haproxy.config.dir }}/maps/{{ map }}
- source: salt://haproxy/templates/maps/{{ map }}.j2
2022-12-11 16:34:27 +01:00
- user: {{ haproxy.config.user }}
- group: {{ haproxy.config.group }}
- mode: "0600"
- template: jinja
- watch_in:
- service: haproxy-service
{% endfor %}
2024-09-01 14:50:42 +02:00
{% for static in haproxy.config.static %}
2024-09-01 14:39:43 +02:00
haproxy-static-{{ static }}:
file.managed:
- name: {{ haproxy.config.dir }}/static/{{ static }}
- source: salt://haproxy/templates/static/{{ static }}.j2
- user: {{ haproxy.config.user }}
- group: {{ haproxy.config.group }}
- mode: "0600"
- template: jinja
- watch_in:
- service: haproxy-service
{% endfor %}
2023-01-16 12:00:54 +01:00
haproxy-config-main:
2022-12-11 16:34:27 +01:00
file.managed:
2022-12-24 17:49:54 +01:00
- name: {{ haproxy.config.dir }}/{{ haproxy.config.configfile }}
- source: salt://haproxy/templates/haproxy.cfg.j2
2022-12-11 16:34:27 +01:00
- user: {{ haproxy.config.user }}
- group: {{ haproxy.config.group }}
- mode: "0600"
- template: jinja
- watch_in:
- service: haproxy-service
2023-01-16 12:00:54 +01:00
haproxy-config-spoe:
2022-10-01 20:06:19 +02:00
file.managed:
2022-12-24 17:49:54 +01:00
- name: {{ haproxy.config.dir }}/spoe.cfg
- source: salt://haproxy/templates/spoe.cfg.j2
2022-10-01 20:06:19 +02:00
- user: {{ haproxy.config.user }}
- group: {{ haproxy.config.group }}
- mode: "0600"
- template: jinja
- watch_in:
- service: haproxy-service