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.
 
 

33 lines
1.6 KiB

  1. # SPDX-FileCopyrightText: 2024 MDAD Team and contributors
  2. #
  3. # SPDX-License-Identifier: AGPL-3.0-or-later
  4. ---
  5. - name: (Deprecation) Catch and report renamed maubot variables
  6. ansible.builtin.fail:
  7. msg: >-
  8. Your configuration contains a variable, which now has a different name.
  9. Please change your configuration to rename the variable (`{{ item.old }}` -> `{{ item.new }}`).
  10. when: "item.old in vars"
  11. with_items:
  12. - {'old': 'matrix_bot_maubot_management_interface_port', 'new': 'matrix_bot_maubot_server_port'}
  13. - {'old': 'matrix_bot_maubot_management_interface_http_bind_port', 'new': 'matrix_bot_maubot_container_management_interface_http_bind_port'}
  14. - {'old': 'matrix_bot_maubot_registration_shared_secret', 'new': 'matrix_bot_maubot_homeserver_secret'}
  15. - name: Fail if required maubot settings not defined
  16. ansible.builtin.fail:
  17. msg: >-
  18. You need to define a required configuration setting (`{{ item.name }}`).
  19. when: "item.when | bool and vars[item.name] == ''"
  20. with_items:
  21. - {'name': 'matrix_bot_maubot_hostname', when: true}
  22. - {'name': 'matrix_bot_maubot_path_prefix', when: true}
  23. - {'name': 'matrix_bot_maubot_unshared_secret', when: true}
  24. - {'name': 'matrix_bot_maubot_admins', when: true}
  25. - {'name': 'matrix_bot_maubot_database_hostname', when: "{{ matrix_bot_maubot_database_engine == 'postgres' }}"}
  26. - {'name': 'matrix_bot_maubot_container_network', when: true}
  27. - {'name': 'matrix_bot_maubot_homeserver_name', when: true}
  28. - {'name': 'matrix_bot_maubot_homeserver_url', when: true}
  29. - {'name': 'matrix_bot_maubot_initial_password', when: true}