7c632352a0
The behaviour of the `include` module is badly defined (it try to choose between statically importing the tasks and dynamically including them) and can cause problems depending on any number of constraints (mostly if it choose the wrong behaviour). Replace it with the `import_tasks` (always statically import tasks) unless the `include` is in a loop in which case we replace it with `include_tasks` (always dynamically include tasks).
50 lines
1.3 KiB
YAML
50 lines
1.3 KiB
YAML
---
|
|
|
|
- name: Set if MySQL should be restart (if needed) or not at all
|
|
set_fact:
|
|
mysql_restart_handler_name: "{{ mysql_restart_if_needed | bool | ternary('restart mysql', 'restart mysql (noop)') }}"
|
|
|
|
- import_tasks: packages_stretch.yml
|
|
when: ansible_distribution_major_version is version('9', '>=')
|
|
|
|
- import_tasks: packages_jessie.yml
|
|
when: ansible_distribution_release == "jessie"
|
|
|
|
## There is nothing to do with users on Debian 11+ - yet we need a /root/.my.cnf for compatibility
|
|
- import_tasks: users_bullseye.yml
|
|
when: ansible_distribution_major_version is version('11', '>=')
|
|
|
|
- import_tasks: users_buster.yml
|
|
when: ansible_distribution_release == "buster"
|
|
|
|
- import_tasks: users_stretch.yml
|
|
when: ansible_distribution_release == "stretch"
|
|
|
|
- import_tasks: users_jessie.yml
|
|
when: ansible_distribution_release == "jessie"
|
|
|
|
- import_tasks: config_stretch.yml
|
|
when: ansible_distribution_major_version is version('9', '>=')
|
|
|
|
- import_tasks: config_jessie.yml
|
|
when: ansible_distribution_release == "jessie"
|
|
|
|
- import_tasks: replication.yml
|
|
when: mysql_replication | bool
|
|
|
|
- import_tasks: datadir.yml
|
|
|
|
- import_tasks: logdir.yml
|
|
|
|
- import_tasks: tmpdir.yml
|
|
|
|
- import_tasks: nrpe.yml
|
|
|
|
- import_tasks: munin.yml
|
|
|
|
- import_tasks: log2mail.yml
|
|
|
|
- import_tasks: utils.yml
|
|
|
|
- import_tasks: mysql_skip.yml
|