Matrix Docker Ansible eploy
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.
 
 

52 line
2.0 KiB

  1. ---
  2. - name: Ensure Matrix jitsi-jicofo path exists
  3. ansible.builtin.file:
  4. path: "{{ item.path }}"
  5. state: directory
  6. mode: 0777
  7. owner: "{{ matrix_user_username }}"
  8. group: "{{ matrix_user_groupname }}"
  9. with_items:
  10. - {path: "{{ matrix_jitsi_jicofo_base_path }}", when: true}
  11. - {path: "{{ matrix_jitsi_jicofo_config_path }}", when: true}
  12. when: item.when | bool
  13. - name: Ensure jitsi-jicofo Docker image is pulled
  14. community.docker.docker_image:
  15. name: "{{ matrix_jitsi_jicofo_docker_image }}"
  16. source: "{{ 'pull' if ansible_version.major > 2 or ansible_version.minor > 7 else omit }}"
  17. force_source: "{{ matrix_jitsi_jicofo_docker_image_force_pull if ansible_version.major > 2 or ansible_version.minor >= 8 else omit }}"
  18. force: "{{ omit if ansible_version.major > 2 or ansible_version.minor >= 8 else matrix_jitsi_jicofo_docker_image_force_pull }}"
  19. register: result
  20. retries: "{{ devture_playbook_help_container_retries_count }}"
  21. delay: "{{ devture_playbook_help_container_retries_delay }}"
  22. until: result is not failed
  23. - name: Ensure jitsi-jicofo environment variables file created
  24. ansible.builtin.template:
  25. src: "{{ role_path }}/templates/jicofo/env.j2"
  26. dest: "{{ matrix_jitsi_jicofo_base_path }}/env"
  27. owner: "{{ matrix_user_username }}"
  28. group: "{{ matrix_user_groupname }}"
  29. mode: 0640
  30. when: matrix_jitsi_enabled | bool
  31. - name: Ensure jitsi-jicofo configuration files created
  32. ansible.builtin.template:
  33. src: "{{ role_path }}/templates/jicofo/{{ item }}.j2"
  34. dest: "{{ matrix_jitsi_jicofo_config_path }}/{{ item }}"
  35. owner: "{{ matrix_user_username }}"
  36. group: "{{ matrix_user_groupname }}"
  37. mode: 0644
  38. with_items:
  39. - sip-communicator.properties
  40. - logging.properties
  41. - name: Ensure matrix-jitsi-jicofo.service installed
  42. ansible.builtin.template:
  43. src: "{{ role_path }}/templates/jicofo/matrix-jitsi-jicofo.service.j2"
  44. dest: "{{ devture_systemd_docker_base_systemd_path }}/matrix-jitsi-jicofo.service"
  45. mode: 0644
  46. register: matrix_jitsi_jicofo_systemd_service_result