Matrix Docker Ansible eploy
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

54 строки
2.6 KiB

  1. {% if matrix_bot_draupnir_container_labels_traefik_enabled %}
  2. traefik.enable=true
  3. {% if matrix_bot_draupnir_container_labels_traefik_docker_network %}
  4. traefik.docker.network={{ matrix_bot_draupnir_container_labels_traefik_docker_network }}
  5. {% endif %}
  6. traefik.http.services.matrix-bot-draupnir.loadbalancer.server.port=8080
  7. ############################################################
  8. # #
  9. # Abuse Reports (/_matrix/client/../rooms/../report) #
  10. # #
  11. ############################################################
  12. {% set middlewares = [] %}
  13. traefik.http.middlewares.matrix-bot-draupnir-redirect.replacepathregex.regex=^/_matrix/client/(r0|v3)/rooms/([^/]*)/report/(.*)$
  14. traefik.http.middlewares.matrix-bot-draupnir-redirect.replacepathregex.replacement=/api/1/report/$2/$3
  15. {% set middlewares = middlewares + ['matrix-bot-draupnir-redirect'] %}
  16. traefik.http.middlewares.matrix-bot-draupnir-cors.headers.accesscontrolalloworiginlist=*
  17. traefik.http.middlewares.matrix-bot-draupnir-cors.headers.accesscontrolallowheaders=Content-Type,Authorization
  18. traefik.http.middlewares.matrix-bot-draupnir-cors.headers.accesscontrolallowmethods=POST,OPTIONS
  19. {% set middlewares = middlewares + ['matrix-bot-draupnir-cors'] %}
  20. traefik.http.routers.matrix-bot-draupnir.rule={{ matrix_bot_draupnir_container_labels_traefik_rule }}
  21. {% if matrix_bot_draupnir_container_labels_traefik_priority | int > 0 %}
  22. traefik.http.routers.matrix-bot-draupnir.priority={{ matrix_bot_draupnir_container_labels_traefik_priority }}
  23. {% endif %}
  24. {% if middlewares | length > 0 %}
  25. traefik.http.routers.matrix-bot-draupnir.middlewares={{ middlewares | join(',') }}
  26. {% endif %}
  27. traefik.http.routers.matrix-bot-draupnir.service=matrix-bot-draupnir
  28. traefik.http.routers.matrix-bot-draupnir.entrypoints={{ matrix_bot_draupnir_container_labels_traefik_entrypoints }}
  29. traefik.http.routers.matrix-bot-draupnir.tls={{ matrix_bot_draupnir_container_labels_traefik_tls | to_json }}
  30. {% if matrix_bot_draupnir_container_labels_traefik_tls %}
  31. traefik.http.routers.matrix-bot-draupnir.tls.certResolver={{ matrix_bot_draupnir_container_labels_traefik_tls_certResolver }}
  32. {% endif %}
  33. ############################################################
  34. # #
  35. # /Abuse Reports (/_matrix/client/../rooms/../report) #
  36. # #
  37. ############################################################
  38. {% endif %}
  39. {{ matrix_bot_draupnir_container_labels_traefik_labels_additional_labels }}