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.

34 lines
826 B

  1. ---
  2. - name: Haproxy | Cleanup potentially deployed nginx-proxy
  3. file:
  4. path: "{{ kube_manifest_dir }}/nginx-proxy.yml"
  5. state: absent
  6. - name: Haproxy | Make haproxy directory
  7. file:
  8. path: "{{ haproxy_config_dir }}"
  9. state: directory
  10. mode: "0755"
  11. owner: root
  12. - name: Haproxy | Write haproxy configuration
  13. template:
  14. src: "loadbalancer/haproxy.cfg.j2"
  15. dest: "{{ haproxy_config_dir }}/haproxy.cfg"
  16. owner: root
  17. mode: "0755"
  18. backup: true
  19. - name: Haproxy | Get checksum from config
  20. stat:
  21. path: "{{ haproxy_config_dir }}/haproxy.cfg"
  22. get_attributes: false
  23. get_checksum: true
  24. get_mime: false
  25. register: haproxy_stat
  26. - name: Haproxy | Write static pod
  27. template:
  28. src: manifests/haproxy.manifest.j2
  29. dest: "{{ kube_manifest_dir }}/haproxy.yml"
  30. mode: "0640"