Replace most import_tasks calls with include_tasks for improved performance

This commit is contained in:
Slavi Pantaleev
2022-11-24 11:33:30 +02:00
parent 5c3df22c35
commit 7c2a7a8eb6
115 changed files with 1175 additions and 1654 deletions

View File

@ -1,25 +1,21 @@
---
- when: matrix_appservice_webhooks_enabled | bool
ansible.builtin.import_tasks: "{{ role_path }}/tasks/inject_into_nginx_proxy.yml"
- block:
- when: matrix_appservice_webhooks_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/inject_into_nginx_proxy.yml"
tags:
- setup-all
- setup-nginx-proxy
- ansible.builtin.import_tasks: "{{ role_path }}/tasks/validate_config.yml"
when: "run_setup | bool and matrix_appservice_webhooks_enabled | bool"
tags:
- setup-all
- setup-appservice-webhooks
- block:
- when: matrix_appservice_webhooks_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
- ansible.builtin.import_tasks: "{{ role_path }}/tasks/setup_install.yml"
when: "run_setup | bool and matrix_appservice_webhooks_enabled | bool"
tags:
- setup-all
- setup-appservice-webhooks
- when: matrix_appservice_webhooks_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_install.yml"
- ansible.builtin.import_tasks: "{{ role_path }}/tasks/setup_uninstall.yml"
when: "run_setup | bool and not matrix_appservice_webhooks_enabled | bool"
- when: not matrix_appservice_webhooks_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_uninstall.yml"
tags:
- setup-all
- setup-appservice-webhooks