Merge pull request #79 from wazuh/PR-54_new_structure

client.keys registration triggers
This commit is contained in:
AlfonsoRBJ 2018-11-12 14:13:04 +01:00 committed by GitHub
commit fcf7bf4b00
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View File

@ -56,7 +56,7 @@
{% if wazuh_agent_authd.ssl_auto_negotiate == 'yes' %}-a{% endif %} {% if wazuh_agent_authd.ssl_auto_negotiate == 'yes' %}-a{% endif %}
register: agent_auth_output register: agent_auth_output
when: when:
- check_keys.stat.size == 0 - check_keys.stat.exists == false or check_keys.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
tags: tags:
- config - config
@ -65,7 +65,7 @@
- name: Linux | Verify agent registration - name: Linux | Verify agent registration
shell: echo {{ agent_auth_output }} | grep "Valid key created" shell: echo {{ agent_auth_output }} | grep "Valid key created"
when: when:
- check_keys.stat.size == 0 - check_keys.stat.exists == false or check_keys.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
tags: tags:
- config - config
@ -97,7 +97,7 @@
register: newagent_api register: newagent_api
changed_when: newagent_api.json.error == 0 changed_when: newagent_api.json.error == 0
when: when:
- check_keys.stat.size == 0 - check_keys.stat.exists == false or check_keys.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
become: no become: no
tags: tags:
@ -113,7 +113,7 @@
user: "{{ wazuh_managers.0.api_user }}" user: "{{ wazuh_managers.0.api_user }}"
password: "{{ api_pass }}" password: "{{ api_pass }}"
when: when:
- check_keys.stat.size == 0 - check_keys.stat.exists == false or check_keys.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
- newagent_api.json.error == 0 - newagent_api.json.error == 0
register: newagentdata_api register: newagentdata_api
@ -134,7 +134,7 @@
OSSEC_ACTION_CONFIRMED: y OSSEC_ACTION_CONFIRMED: y
register: manage_agents_output register: manage_agents_output
when: when:
- check_keys.stat.size == 0 - check_keys.stat.exists == false or check_keys.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
- newagent_api.changed - newagent_api.changed
tags: tags:

View File

@ -62,7 +62,7 @@
notify: restart wazuh-agent windows notify: restart wazuh-agent windows
when: when:
- wazuh_agent_authd.enable == true - wazuh_agent_authd.enable == true
- check_windows_key.stat.exists == false - check_windows_key.stat.exists == false or check_windows_key.stat.size == 0
- wazuh_managers.0.address is not none - wazuh_managers.0.address is not none
tags: tags:
- config - config