diff --git a/defaults/main.yaml b/defaults/main.yaml index e99eae4..6f4f594 100644 --- a/defaults/main.yaml +++ b/defaults/main.yaml @@ -1,12 +1,12 @@ ansible_version: 5.0.1 ansible_pip_package: ansible -ansible_use_ara: false +ansible_use_ara: true ansible_ara_version: 1.5.7 -ansible_ara_pip_package: ara +ansible_ara_pip_package: ara[server] -ansible_use_mitogen: false -ansible_mitogen_version: 0.3.0 +ansible_use_mitogen: true +ansible_mitogen_version: 0.3.2 ansible_mitogen_pip_package: mitogen -ansible_use_ssh_pipelining: true +ansible_use_ssh_pipelining: false diff --git a/tasks/ara.yaml b/tasks/ara.yaml index 6507255..5a7ed0d 100644 --- a/tasks/ara.yaml +++ b/tasks/ara.yaml @@ -5,7 +5,7 @@ name: "{{ansible_ara_pip_package}}" version: "{{ansible_ara_version}}" -- name: get ara location - shell: python3 -c "import os,ara; print(os.path.dirname(ara.__file__))" - register: _ara_location +- name: get ara ansible config + shell: python3 -m ara.setup.ansible + register: _ara_config changed_when: false diff --git a/templates/ansible.cfg.j2 b/templates/ansible.cfg.j2 index e03209b..389cf56 100644 --- a/templates/ansible.cfg.j2 +++ b/templates/ansible.cfg.j2 @@ -1,25 +1,25 @@ [defaults] nocows = 1 stdout_callback = yaml - interpreter_python = auto_silent +retry_files_enabled = False +force_handlers = True library = /usr/share/ansible/library {% if ansible_use_mitogen %} +# mitogen config strategy_plugins = {{ _ansible_mitogen_location.stdout }}/plugins/strategy strategy = mitogen_linear {% endif %} -retry_files_enabled = False -force_handlers = True - {% if ansible_use_ara %} -callback_plugins = {{ _ara_location.stdout }}/plugins/callbacks +# ara config +{{ _ara_config.stdout_lines[1:] | join("\n") }} {% endif %} -{% if not ansible_use_mitogen %} [ssh_connection] +{% if not ansible_use_mitogen %} {% if ansible_use_ssh_pipelining %} pipelining = True {% endif %}