From a52d5e540c2f97bc6d91f152b108c17480d404b6 Mon Sep 17 00:00:00 2001 From: Jose M Date: Mon, 9 Sep 2019 13:05:40 +0200 Subject: [PATCH] Modify registration task to use new fact "wazuh_agent_win_auth_path" --- roles/wazuh/ansible-wazuh-agent/tasks/Windows.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/roles/wazuh/ansible-wazuh-agent/tasks/Windows.yml b/roles/wazuh/ansible-wazuh-agent/tasks/Windows.yml index d620f5da..f42467d4 100644 --- a/roles/wazuh/ansible-wazuh-agent/tasks/Windows.yml +++ b/roles/wazuh/ansible-wazuh-agent/tasks/Windows.yml @@ -58,15 +58,12 @@ - name: Windows | Register agent win_shell: > - {% if check_path.stat.exists %}{{ wazuh_winagent_config.auth_path_x86 }}{% else %} - {{ wazuh_winagent_config.auth_path }}{% endif %} + {{ wazuh_agent_win_auth_path }} -m {{ wazuh_managers.0.address }} -p {{ wazuh_agent_authd.port }} {% if authd_pass is defined %} -P {{ authd_pass }}{% endif %} - args: - chdir: "{{ wazuh_agent_win_path }}" register: agent_auth_output - notify: restart wazuh-agent windows + notify: Windows | Restart Wazuh Agent when: - wazuh_agent_authd.enable - not check_windows_key.stat.exists or check_windows_key.stat.size == 0