Matrix Docker Ansible eploy
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 

39 行
2.6 KiB

  1. # SPDX-FileCopyrightText: 2022 - 2025 Slavi Pantaleev
  2. # SPDX-FileCopyrightText: 2022 Nikita Chernyi
  3. # SPDX-FileCopyrightText: 2025 Suguru Hirahara
  4. #
  5. # SPDX-License-Identifier: AGPL-3.0-or-later
  6. ---
  7. - name: (Deprecation) Catch and report renamed Buscarron settings
  8. ansible.builtin.fail:
  9. msg: >-
  10. Your configuration contains a variable, which now has a different name.
  11. Please rename the variable (`{{ item.old }}` -> `{{ item.new }}`) on your configuration file (vars.yml).
  12. when: "lookup('ansible.builtin.varnames', ('^' + item.old + '$'), wantlist=True) | length > 0"
  13. with_items:
  14. - {'old': 'matrix_bot_buscarron_noencryption', 'new': '<removed>'}
  15. - {'old': 'matrix_bot_buscarron_spam_hosts', 'new': '<superseded by matrix_bot_buscarron_spamlist>'}
  16. - {'old': 'matrix_bot_buscarron_spam_emails', 'new': '<superseded by matrix_bot_buscarron_spamlist>'}
  17. - {'old': 'matrix_bot_buscarron_spam_localparts', 'new': '<superseded by matrix_bot_buscarron_spamlist>'}
  18. - {'old': 'matrix_bot_buscarron_container_image_name_prefix', 'new': 'matrix_bot_buscarron_container_image_registry_prefix'}
  19. - {'old': 'matrix_bot_buscarron_docker_image', 'new': 'matrix_bot_buscarron_container_image'}
  20. - {'old': 'matrix_bot_buscarron_docker_image_force_pull', 'new': 'matrix_bot_buscarron_container_image_force_pull'}
  21. - {'old': 'matrix_bot_buscarron_docker_image_registry_prefix', 'new': 'matrix_bot_buscarron_container_image_registry_prefix'}
  22. - {'old': 'matrix_bot_buscarron_docker_image_registry_prefix_upstream', 'new': 'matrix_bot_buscarron_container_image_registry_prefix_upstream'}
  23. - {'old': 'matrix_bot_buscarron_docker_image_registry_prefix_upstream_default', 'new': 'matrix_bot_buscarron_container_image_registry_prefix_upstream_default'}
  24. - {'old': 'matrix_bot_buscarron_docker_repo', 'new': 'matrix_bot_buscarron_container_repo'}
  25. - {'old': 'matrix_bot_buscarron_docker_repo_version', 'new': 'matrix_bot_buscarron_container_repo_version'}
  26. - {'old': 'matrix_bot_buscarron_docker_src_files_path', 'new': 'matrix_bot_buscarron_container_src_files_path'}
  27. - name: Fail if required Buscarron settings not defined
  28. ansible.builtin.fail:
  29. msg: >-
  30. You need to define a required configuration setting (`{{ item.name }}`).
  31. when: "item.when | bool and lookup('vars', item.name, default='') | string | length == 0"
  32. with_items:
  33. - {'name': 'matrix_bot_buscarron_password', when: true}
  34. - {'name': 'matrix_bot_buscarron_hostname', when: true}
  35. - {'name': 'matrix_bot_buscarron_database_hostname', when: "{{ matrix_bot_buscarron_database_engine == 'postgres' }}"}
  36. - {'name': 'matrix_bot_buscarron_homeserver', when: true}