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

43 строки
1.2 KiB

  1. ---
  2. - name: Fail if Coturn secret is missing
  3. fail:
  4. msg: "You need to set a secret in the matrix_coturn_turn_static_auth_secret variable"
  5. when: "matrix_coturn_turn_static_auth_secret == ''"
  6. - name: Ensure Coturn image is pulled
  7. docker_image:
  8. name: "{{ matrix_docker_image_coturn }}"
  9. - name: Ensure Coturn configuration path exists
  10. file:
  11. path: "{{ matrix_coturn_base_path }}"
  12. state: directory
  13. mode: 0750
  14. owner: "{{ matrix_user_username }}"
  15. group: "{{ matrix_user_username }}"
  16. - name: Ensure turnserver.conf installed
  17. template:
  18. src: "{{ role_path }}/templates/coturn/turnserver.conf.j2"
  19. dest: "{{ matrix_coturn_config_path }}"
  20. mode: 0644
  21. - name: Ensure matrix-coturn.service installed
  22. template:
  23. src: "{{ role_path }}/templates/systemd/matrix-coturn.service.j2"
  24. dest: "/etc/systemd/system/matrix-coturn.service"
  25. mode: 0644
  26. - name: Allow access to Coturn ports in firewalld
  27. firewalld:
  28. port: "{{ item }}"
  29. state: enabled
  30. immediate: yes
  31. permanent: yes
  32. with_items:
  33. - '3478/tcp' # STUN
  34. - '3478/udp' # STUN
  35. - "{{ matrix_coturn_turn_udp_min_port }}-{{ matrix_coturn_turn_udp_max_port }}/udp" # TURN
  36. when: ansible_os_family == 'RedHat'