---

- block:
    - ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
  tags:
    - setup-all
    - install-all

# This needs to always run, because it populates `matrix_user_uid` and `matrix_user_gid`,
# which are required by many other roles.
- block:
    - ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_matrix_user.yml"
  tags:
    - always
    - setup-system-user
    - common

- block:
    - ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_matrix_base.yml"
  tags:
    - setup-all
    - install-all
    - common

- block:
    - ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_well_known.yml"
  tags:
    - setup-all
    - setup-ma1sd
    - setup-synapse
    - setup-dendrite
    - setup-conduit
    - setup-nginx-proxy
    - install-all
    - install-ma1sd
    - install-synapse
    - install-dendrite
    - install-conduit
    - install-nginx-proxy
