Matrix Docker Ansible eploy
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 

32 líneas
1.5 KiB

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