Closed dmaasland closed 4 months ago
Assigning this issue to @wazuh/cicd.
watching this - have the same issue on mac. Trying to install 4.7.2.
After resolving that the alternative for using the Wazuh certificates tool for macOS and Windows systems is to use the tool through docker: https://github.com/wazuh/wazuh-packages/issues/1660
An adaptation is made so that when the playbooks are run on a macOS host with Ansible, the creation of the certificates is generated using the dockerized image.
Some tests are carried out in a simulated environment (performed on a Linux machine, limiting the execution of tasks according to the system)
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : RedHat/CentOS/Fedora | Add Wazuh indexer repo] ********************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
changed: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [192.168.57.46]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
changed: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
changed: [192.168.57.46 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : RedHat/CentOS/Fedora | Add Wazuh indexer repo] ********************************************************************************************************************************************************
skipping: [192.168.57.46]
cbordon@cbordon-MS-7C88:~/Documents/wazuh/repositorios/wazuh-ansible$ ls -la playbooks/indexer/certificates/
total 16
drwxr-xr-x 3 root root 4096 jun 27 16:29 .
drwxr-xr-x 3 root root 4096 jun 27 16:29 ..
-rw-r--r-- 1 root root 205 jun 27 16:29 config.yml
dr-x------ 2 root root 4096 jun 27 16:29 wazuh-certificates
cbordon@cbordon-MS-7C88:~/Documents/wazuh/repositorios/wazuh-ansible$ sudo ls -la playbooks/indexer/certificates/wazuh-certificates/
total 40
dr-x------ 2 root root 4096 jun 27 16:29 .
drwxr-xr-x 3 root root 4096 jun 27 16:29 ..
-r-------- 1 cbordon cbordon 1704 jun 27 16:29 admin-key.pem
-r-------- 1 cbordon cbordon 1119 jun 27 16:29 admin.pem
-r-------- 1 cbordon cbordon 1704 jun 27 16:29 node-1-key.pem
-r-------- 1 cbordon cbordon 1277 jun 27 16:29 node-1.pem
-r-------- 1 cbordon cbordon 1704 jun 27 16:29 root-ca.key
-r-------- 1 systemd-coredump systemd-coredump 1704 jun 27 16:29 root-ca-manager.key
-r-------- 1 systemd-coredump systemd-coredump 1204 jun 27 16:29 root-ca-manager.pem
-r-------- 1 cbordon cbordon 1204 jun 27 16:29 root-ca.pem
cbordon@cbordon-MS-7C88:~/Documents/wazuh/repositorios/wazuh-ansible$ cat playbooks/indexer/certificates/config.yml
nodes:
# Indexer server nodes
indexer:
- name: node-1
ip: 127.0.0.1
# Wazuh server nodes
# Use node_type only with more than one Wazuh manager
server:
# Dashboard node
dashboard:
TASK [../roles/wazuh/wazuh-dashboard : Copy the certificates from local to the Wazuh dashboard instance] ***********************************************************************************************************************************
changed: [192.168.57.46] => (item=root-ca.pem)
changed: [192.168.57.46] => (item=node-1-key.pem)
changed: [192.168.57.46] => (item=node-1.pem)
TASK [../roles/wazuh/wazuh-dashboard : Copy Configuration File] ****************************************************************************************************************************************************************************
changed: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Ensuring Wazuh dashboard directory owner] ***********************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Wait for Wazuh-Indexer port] ************************************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Select correct API protocol] ************************************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Attempting to delete legacy Wazuh index if exists] **************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Create Wazuh Plugin config directory] ***************************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Configure Wazuh Dashboard Plugin] *******************************************************************************************************************************************************************
ok: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Configure opensearch.password in opensearch_dashboards.keystore] ************************************************************************************************************************************
changed: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [192.168.57.46]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [192.168.57.46]
RUNNING HANDLER [../roles/wazuh/wazuh-indexer : restart wazuh-indexer] *********************************************************************************************************************************************************************
changed: [192.168.57.46]
RUNNING HANDLER [../roles/wazuh/ansible-wazuh-manager : restart wazuh-manager] *************************************************************************************************************************************************************
changed: [192.168.57.46]
RUNNING HANDLER [../roles/wazuh/ansible-filebeat-oss : restart filebeat] *******************************************************************************************************************************************************************
changed: [192.168.57.46]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [192.168.57.46]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
192.168.57.46 : ok=117 changed=58 unreachable=0 failed=0 skipped=91 rescued=0 ignored=0
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
skipping: [192.168.57.151]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
skipping: [192.168.57.151]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
skipping: [192.168.57.151]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
changed: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [192.168.57.151]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
changed: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
changed: [192.168.57.151 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : RedHat/CentOS/Fedora | Add Wazuh indexer repo] ********************************************************************************************************************************************************
skipping: [192.168.57.151]
TASK [../roles/wazuh/wazuh-indexer : Install Amazon extras] ********************************************************************************************************************************************************************************
skipping: [192.168.57.151]
----
TASK [../roles/wazuh/wazuh-dashboard : Configure opensearch.password in opensearch_dashboards.keystore] ************************************************************************************************************************************
changed: [192.168.57.151]
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [192.168.57.151]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [192.168.57.151]
RUNNING HANDLER [../roles/wazuh/wazuh-indexer : restart wazuh-indexer] *********************************************************************************************************************************************************************
changed: [192.168.57.151]
RUNNING HANDLER [../roles/wazuh/ansible-wazuh-manager : restart wazuh-manager] *************************************************************************************************************************************************************
changed: [192.168.57.151]
RUNNING HANDLER [../roles/wazuh/ansible-filebeat-oss : restart filebeat] *******************************************************************************************************************************************************************
changed: [192.168.57.151]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [192.168.57.151]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
192.168.57.151 : ok=117 changed=62 unreachable=0 failed=0 skipped=91 rescued=0 ignored=0
An attempt has been made to install an AIO with ansible on an ubuntu 20 VM from a macOS host machine.
When trying to install the certificates, the part of running docker containers on macOS was skipped even though the host machine was macOS.
Because of this, I got the error certificate verify failed: unable to get local issuer certificate
The output was the following:
We need to review with @teddytpc1 the behavior of delegate_to parameter
We change the form of validation since the systems check does not work for us because Ansible validates the target system. In this case, it omits validating the host (macOS), so we will use a variable to validate this. With this, the user who runs Ansible on macOS must change the variable to true for the deployment to work correctly:
TASK [../roles/wazuh/wazuh-indexer : include_vars] *****************************************************************************************************************************************************************************************
skipping: [192.168.57.103]
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
ok: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
changed: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
changed: [192.168.57.103 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
skipping: [192.168.57.103]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [192.168.57.103]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
skipping: [192.168.57.103]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
skipping: [192.168.57.103]
TASK [../roles/wazuh/wazuh-indexer : RedHat/CentOS/Fedora | Add Wazuh indexer repo] ********************************************************************************************************************************************************
skipping: [192.168.57.103]
----
TASK [../roles/wazuh/wazuh-dashboard : Configure Wazuh Dashboard Plugin] *******************************************************************************************************************************************************************
ok: [192.168.57.103]
TASK [../roles/wazuh/wazuh-dashboard : Configure opensearch.password in opensearch_dashboards.keystore] ************************************************************************************************************************************
changed: [192.168.57.103]
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [192.168.57.103]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [192.168.57.103]
RUNNING HANDLER [../roles/wazuh/wazuh-indexer : restart wazuh-indexer] *********************************************************************************************************************************************************************
changed: [192.168.57.103]
RUNNING HANDLER [../roles/wazuh/ansible-wazuh-manager : restart wazuh-manager] *************************************************************************************************************************************************************
changed: [192.168.57.103]
RUNNING HANDLER [../roles/wazuh/ansible-filebeat-oss : restart filebeat] *******************************************************************************************************************************************************************
changed: [192.168.57.103]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [192.168.57.103]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
192.168.57.103 : ok=117 changed=61 unreachable=0 failed=0 skipped=91 rescued=0 ignored=0
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
ok: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
skipping: [192.168.57.193]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
skipping: [192.168.57.193]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
changed: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [192.168.57.193]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
changed: [192.168.57.193 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
changed: [192.168.57.193 -> localhost]
---
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [192.168.57.193]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [192.168.57.193]
RUNNING HANDLER [../roles/wazuh/wazuh-indexer : restart wazuh-indexer] *********************************************************************************************************************************************************************
changed: [192.168.57.193]
RUNNING HANDLER [../roles/wazuh/ansible-wazuh-manager : restart wazuh-manager] *************************************************************************************************************************************************************
changed: [192.168.57.193]
RUNNING HANDLER [../roles/wazuh/ansible-filebeat-oss : restart filebeat] *******************************************************************************************************************************************************************
changed: [192.168.57.193]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [192.168.57.193]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
192.168.57.193 : ok=118 changed=62 unreachable=0 failed=0 skipped=90 rescued=0 ignored=0
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
ok: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
skipping: [wi1]
---
TASK [../roles/wazuh/wazuh-dashboard : Attempting to delete legacy Wazuh index if exists] **************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Create Wazuh Plugin config directory] ***************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Configure Wazuh Dashboard Plugin] *******************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Configure opensearch.password in opensearch_dashboards.keystore] ************************************************************************************************************************************
changed: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [dashboard]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [dashboard]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
dashboard : ok=22 changed=12 unreachable=0 failed=0 skipped=5 rescued=0 ignored=0
manager : ok=60 changed=32 unreachable=0 failed=0 skipped=28 rescued=0 ignored=0
wi1 : ok=41 changed=27 unreachable=0 failed=0 skipped=54 rescued=0 ignored=0
wi2 : ok=27 changed=18 unreachable=0 failed=0 skipped=27 rescued=0 ignored=0
wi3 : ok=27 changed=18 unreachable=0 failed=0 skipped=27 rescued=0 ignored=0
wi4 : ok=0 changed=0 unreachable=1 failed=0 skipped=0 rescued=0 ignored=0
worker : ok=56 changed=28 unreachable=0 failed=0 skipped=32 rescued=0 ignored=0
TASK [../roles/wazuh/wazuh-indexer : Check if certificates already exists] *****************************************************************************************************************************************************************
ok: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Create local temporary directory for certificates generation] **************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check that the generation tool exists] *************************************************************************************************************************************************
ok: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Download certificates generation tool] *************************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Prepare the certificates generation template file] *************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Generate the node & admin certificates in local] ***************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Check for Docker installation on macOS] ************************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Fail if Docker is not installed] *******************************************************************************************************************************************************
skipping: [wi1]
TASK [../roles/wazuh/wazuh-indexer : Local action | Run Docker container on macOS] *********************************************************************************************************************************************************
changed: [wi1 -> localhost]
TASK [../roles/wazuh/wazuh-indexer : Local action | Remove Docker image after execution] ***************************************************************************************************************************************************
changed: [wi1 -> localhost]
----
TASK [../roles/wazuh/wazuh-dashboard : Copy Configuration File] ****************************************************************************************************************************************************************************
changed: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Ensuring Wazuh dashboard directory owner] ***********************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Wait for Wazuh-Indexer port] ************************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Select correct API protocol] ************************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Attempting to delete legacy Wazuh index if exists] **************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Create Wazuh Plugin config directory] ***************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Configure Wazuh Dashboard Plugin] *******************************************************************************************************************************************************************
ok: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Configure opensearch.password in opensearch_dashboards.keystore] ************************************************************************************************************************************
changed: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Ensure Wazuh dashboard started and enabled] *********************************************************************************************************************************************************
changed: [dashboard]
TASK [../roles/wazuh/wazuh-dashboard : Remove Wazuh dashboard repository (and clean up left-over metadata)] ********************************************************************************************************************************
skipping: [dashboard]
RUNNING HANDLER [../roles/wazuh/wazuh-dashboard : restart wazuh-dashboard] *****************************************************************************************************************************************************************
changed: [dashboard]
PLAY RECAP *********************************************************************************************************************************************************************************************************************************
dashboard : ok=22 changed=12 unreachable=0 failed=0 skipped=5 rescued=0 ignored=0
manager : ok=60 changed=32 unreachable=0 failed=0 skipped=28 rescued=0 ignored=0
wi1 : ok=42 changed=28 unreachable=0 failed=0 skipped=53 rescued=0 ignored=0
wi2 : ok=27 changed=18 unreachable=0 failed=0 skipped=27 rescued=0 ignored=0
wi3 : ok=27 changed=18 unreachable=0 failed=0 skipped=27 rescued=0 ignored=0
worker : ok=56 changed=28 unreachable=0 failed=0 skipped=32 rescued=0 ignored=0
When running the playbook from a native macOS, everything works as expected. The certificates are created correctly via the docker image and the installation of the AIO on the remote machine completes correctly.
tree playbooks/indexer/
playbooks/indexer/
└── certificates
├── config.yml
└── wazuh-certificates
├── admin-key.pem
├── admin.pem
├── node-1-key.pem
├── node-1.pem
├── root-ca-manager.key
├── root-ca-manager.pem
├── root-ca.key
└── root-ca.pem
Same bug on mac for me, thanks for fix it.
Hello,
It seems that deploying of playbooks does not work when running Ansible on a Mac. Something weird happens during the certificate generation where node certificates aren't created. I've narrowed this down to the Mac version of
awk
not playing nice with the commands in thewazuh-certs-generator.sh
script. It'll give warnings like this when run manually:Ansible won't show you this though so it just seems to fail. Running the same command in an ubuntu docker works fine.