Merge pull request #1916 from wazuh/enh/1911--bridge-4.14.4--Ensure_boolean_condition_evaluations__from_community_PR

Ensure boolean condition evaluations from community pr #1897
This commit is contained in:
Gonzalo Acuña 2026-01-26 14:25:27 -03:00 committed by GitHub
commit 99e3c35708
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 11 additions and 9 deletions

View File

@ -9,7 +9,7 @@ All notable changes to this project will be documented in this file.
### Changed
- None
- Ensure boolean condition evaluations - from community PR #1897 ([#1916](https://github.com/wazuh/wazuh-ansible/pull/1916))
### Fixed

View File

@ -242,7 +242,7 @@
notify: restart wazuh-manager
when:
- csyslog_enabled.stdout == '0' or "skipped" in csyslog_enabled.stdout
- syslog_output is defined and syslog_output
- syslog_output is defined and (syslog_output | bool)
tags:
- config

View File

@ -108,7 +108,8 @@
delay: 5
tags: debug
when:
- hostvars[inventory_hostname]['private_ip'] is not defined or not hostvars[inventory_hostname]['private_ip']
- hostvars[inventory_hostname]['private_ip'] is not defined or
(hostvars[inventory_hostname]['private_ip'] | length) == 0
- name: Wait for Wazuh indexer API (Private IP)
uri:
@ -127,7 +128,8 @@
delay: 5
tags: debug
when:
- hostvars[inventory_hostname]['private_ip'] is defined and hostvars[inventory_hostname]['private_ip']
- hostvars[inventory_hostname]['private_ip'] is defined and
(hostvars[inventory_hostname]['private_ip'] | length) > 0
- import_tasks: "RMRedHat.yml"
when: ansible_os_family == "RedHat"

View File

@ -114,5 +114,5 @@
register: result
until: result.status in [200,201,401]
when:
- indexer_custom_user is defined and indexer_custom_user
- indexer_custom_user | default('') | trim | length > 0
- inventory_hostname == ansible_play_hosts[0]