2025-02-26 15:52:33 +09:00
|
|
|
# SPDX-FileCopyrightText: 2020 - 2025 Slavi Pantaleev
|
|
|
|
# SPDX-FileCopyrightText: 2022 MDAD project contributors
|
2025-03-05 13:30:50 +09:00
|
|
|
# SPDX-FileCopyrightText: 2025 Suguru Hirahara
|
2025-02-26 15:52:33 +09:00
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
|
2020-07-20 14:13:08 +03:00
|
|
|
---
|
|
|
|
|
2022-11-27 08:23:43 +02:00
|
|
|
- name: Fail if required matrix-reminder-bot settings not defined
|
2022-07-18 10:39:08 +03:00
|
|
|
ansible.builtin.fail:
|
2020-07-20 14:13:08 +03:00
|
|
|
msg: >-
|
|
|
|
You need to define a required configuration setting (`{{ item }}`).
|
2022-11-27 08:23:43 +02:00
|
|
|
when: "item.when | bool and vars[item.name] == ''"
|
2020-07-20 14:13:08 +03:00
|
|
|
with_items:
|
2022-11-27 08:23:43 +02:00
|
|
|
- {'name': 'matrix_bot_matrix_reminder_bot_matrix_user_password', when: true}
|
|
|
|
- {'name': 'matrix_bot_matrix_reminder_bot_reminders_timezone', when: true}
|
2024-01-02 15:56:56 +02:00
|
|
|
- {'name': 'matrix_bot_matrix_reminder_bot_container_network', when: true}
|
|
|
|
- {'name': 'matrix_bot_matrix_reminder_bot_matrix_homeserver_url', when: true}
|
2022-11-27 08:23:43 +02:00
|
|
|
- {'name': 'matrix_bot_matrix_reminder_bot_database_hostname', when: "{{ matrix_bot_matrix_reminder_bot_database_engine == 'postgres' }}"}
|
2022-01-07 13:17:39 +02:00
|
|
|
|
2022-11-27 08:23:43 +02:00
|
|
|
- name: (Deprecation) Catch and report renamed matrix-reminder-bot settings
|
2022-07-18 10:39:08 +03:00
|
|
|
ansible.builtin.fail:
|
2022-01-07 13:17:39 +02:00
|
|
|
msg: >-
|
|
|
|
Your configuration contains a variable, which now has a different name.
|
2025-03-05 13:30:50 +09:00
|
|
|
Please rename the variable (`{{ item.old }}` -> `{{ item.new }}`) on your configuration file (vars.yml).
|
2022-01-07 13:17:39 +02:00
|
|
|
when: "item.old in vars"
|
|
|
|
with_items:
|
|
|
|
- {'old': 'matrix_bot_matrix_reminder_bot_container_self_build', 'new': 'matrix_bot_matrix_reminder_bot_container_image_self_build'}
|
2025-02-24 07:59:37 +02:00
|
|
|
- {'old': 'matrix_bot_matrix_reminder_bot_container_image_name_prefix', 'new': 'matrix_bot_matrix_reminder_bot_container_image_registry_prefix'}
|