Matrix Docker Ansible eploy
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.
 
 

36 řádky
1.6 KiB

  1. # SPDX-FileCopyrightText: 2024 MDAD Team and contributors
  2. #
  3. # SPDX-License-Identifier: AGPL-3.0-or-later
  4. ---
  5. - name: Fail if required rageshake settings not defined
  6. ansible.builtin.fail:
  7. msg: >
  8. You need to define a required configuration setting (`{{ item }}`).
  9. when: "vars[item] == ''"
  10. with_items:
  11. - matrix_rageshake_hostname
  12. - matrix_rageshake_path_prefix
  13. - matrix_rageshake_container_network
  14. - when: matrix_rageshake_container_labels_traefik_enabled | bool
  15. block:
  16. - name: Fail if required rageshake Traefik settings not defined
  17. ansible.builtin.fail:
  18. msg: >-
  19. You need to define a required configuration setting (`{{ item }}`).
  20. when: "vars[item] == ''"
  21. with_items:
  22. - matrix_rageshake_container_labels_traefik_hostname
  23. - matrix_rageshake_container_labels_traefik_path_prefix
  24. # We ensure it doesn't end with a slash, because we handle both (slash and no-slash).
  25. # Knowing that `matrix_rageshake_container_labels_traefik_path_prefix` does not end with a slash
  26. # ensures we know how to set these routes up without having to do "does it end with a slash" checks elsewhere.
  27. - name: Fail if matrix_rageshake_container_labels_traefik_path_prefix ends with a slash
  28. ansible.builtin.fail:
  29. msg: >-
  30. matrix_rageshake_container_labels_traefik_path_prefix (`{{ matrix_rageshake_container_labels_traefik_path_prefix }}`) must either be `/` or not end with a slash (e.g. `/rageshake`).
  31. when: "matrix_rageshake_container_labels_traefik_path_prefix != '/' and matrix_rageshake_container_labels_traefik_path_prefix[-1] == '/'"