-
Notifications
You must be signed in to change notification settings - Fork 202
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MVP - Ansible - Roles: wazuh-dashboard role #1523
Comments
UpdateTests have been carried out to verify the functioning of the Ansible role to perform the installation of Tested OSs
Each host successfully installed the Wazuh Dashboard and connected it to a preconfigured cluster (comprising an indexer, server, and a connected agent) to verify the success of the installation and connection between the dashboard and the cluster. The deployment was completed successfully across all hosts. Archive with all evidence files DescriptionHere is all included evidence of testing. This includes: execution outputs, screenshots, inventory and example playbook.Accessing dashboardIn the Ansible execution logPLAY [all] *********************************************************************
TASK [Gathering Facts] *********************************************************
ok: [100.*.*.249]
ok: [54.*.*.185]
ok: [3.*.*.237]
ok: [34.*.*.45]
ok: [52.*.*.218]
TASK [wazuh-dashboard : include_vars] ******************************************
ok: [34.*.*.45]
ok: [3.*.*.237]
ok: [52.*.*.218]
ok: [54.*.*.185]
ok: [100.*.*.249]
TASK [wazuh-dashboard : include_vars] ******************************************
ok: [34.*.*.45]
ok: [3.*.*.237]
ok: [52.*.*.218]
ok: [54.*.*.185]
ok: [100.*.*.249]
TASK [wazuh-dashboard : Retrieve local_configs_path directory information] *****
ok: [34.*.*.45 -> localhost]
TASK [wazuh-dashboard : fail] **************************************************
skipping: [34.*.*.45]
TASK [wazuh-dashboard : Ensure wazuh-dashboard package download directory exists] ***
changed: [100.*.*.249]
changed: [3.*.*.237]
changed: [54.*.*.185]
changed: [52.*.*.218]
changed: [34.*.*.45]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora | Install Dashboard dependencies] ***
skipping: [3.*.*.237]
skipping: [52.*.*.218]
ok: [100.*.*.249]
ok: [34.*.*.45]
ok: [54.*.*.185]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora (x86_64) | Download wazuh-dashboard package] ***
skipping: [3.*.*.237]
skipping: [52.*.*.218]
skipping: [54.*.*.185]
changed: [100.*.*.249]
changed: [34.*.*.45]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora (aarch64) | Download wazuh-dashboard package] ***
skipping: [34.*.*.45]
skipping: [3.*.*.237]
skipping: [52.*.*.218]
skipping: [100.*.*.249]
changed: [54.*.*.185]
TASK [wazuh-dashboard : Debian-based | Install Dashboard dependencies] *********
skipping: [34.*.*.45]
skipping: [54.*.*.185]
skipping: [100.*.*.249]
ok: [3.*.*.237]
changed: [52.*.*.218]
TASK [wazuh-dashboard : Debian-based (AMD64) | Download wazuh-dashboard package] ***
skipping: [34.*.*.45]
skipping: [52.*.*.218]
skipping: [54.*.*.185]
skipping: [100.*.*.249]
changed: [3.*.*.237]
TASK [wazuh-dashboard : Debian-based (ARM64) | Download wazuh-dashboard package] ***
skipping: [34.*.*.45]
skipping: [3.*.*.237]
skipping: [54.*.*.185]
skipping: [100.*.*.249]
changed: [52.*.*.218]
TASK [wazuh-dashboard : Linux CentOS/RedHat | Install wazuh-dashboard using yum] ***
skipping: [3.*.*.237]
skipping: [52.*.*.218]
changed: [100.*.*.249]
changed: [54.*.*.185]
changed: [34.*.*.45]
TASK [wazuh-dashboard : Linux Debian | Install wazuh-dashboard using dpkg] *****
skipping: [34.*.*.45]
skipping: [54.*.*.185]
skipping: [100.*.*.249]
changed: [52.*.*.218]
changed: [3.*.*.237]
TASK [wazuh-dashboard : Dashboard | Remove current opensearch.hosts configuration] ***
changed: [3.*.*.237]
changed: [52.*.*.218]
changed: [34.*.*.45]
changed: [100.*.*.249]
changed: [54.*.*.185]
TASK [wazuh-dashboard : Dashboard | Add opensearch.hosts configuration] ********
changed: [100.*.*.249]
changed: [54.*.*.185]
changed: [52.*.*.218]
changed: [3.*.*.237]
changed: [34.*.*.45]
TASK [wazuh-dashboard : Copy the certificates from local to the Wazuh dashboard instance] ***
changed: [100.*.*.249] => (item=root-ca.pem)
changed: [52.*.*.218] => (item=root-ca.pem)
changed: [3.*.*.237] => (item=root-ca.pem)
changed: [54.*.*.185] => (item=root-ca.pem)
changed: [34.*.*.45] => (item=root-ca.pem)
changed: [100.*.*.249] => (item=dashboard-key.pem)
changed: [52.*.*.218] => (item=dashboard-key.pem)
changed: [54.*.*.185] => (item=dashboard-key.pem)
changed: [3.*.*.237] => (item=dashboard-key.pem)
changed: [34.*.*.45] => (item=dashboard-key.pem)
changed: [100.*.*.249] => (item=dashboard.pem)
changed: [52.*.*.218] => (item=dashboard.pem)
changed: [54.*.*.185] => (item=dashboard.pem)
changed: [3.*.*.237] => (item=dashboard.pem)
changed: [34.*.*.45] => (item=dashboard.pem)
TASK [wazuh-dashboard : Rename certificates to match default names] ************
skipping: [34.*.*.45] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [34.*.*.45] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [3.*.*.237] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [3.*.*.237] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [34.*.*.45]
skipping: [52.*.*.218] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [52.*.*.218] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [3.*.*.237]
skipping: [52.*.*.218]
skipping: [54.*.*.185] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [54.*.*.185] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [54.*.*.185]
skipping: [100.*.*.249] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [100.*.*.249] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [100.*.*.249]
TASK [wazuh-dashboard : Ensure Wazuh dashboard started and enabled] ************
changed: [100.*.*.249]
changed: [34.*.*.45]
changed: [54.*.*.185]
changed: [52.*.*.218]
changed: [3.*.*.237]
TASK [wazuh-dashboard : Remove installation leftovers] *************************
changed: [100.*.*.249]
changed: [52.*.*.218]
changed: [54.*.*.185]
changed: [3.*.*.237]
changed: [34.*.*.45]
PLAY RECAP *********************************************************************
100.*.*.249 : ok=12 changed=8 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
3.*.*.237 : ok=12 changed=8 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
34.*.*.45 : ok=13 changed=8 unreachable=0 failed=0 skipped=7 rescued=0 ignored=0
52.*.*.218 : ok=12 changed=9 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
54.*.*.185 : ok=12 changed=8 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
|
UpdateDuring the PR review, several changes were recommended:
Additionally:
To implement these updates, the deployment will need to be retested on the previously identified hosts. The results and supporting evidence will be shared here once the tests are completed and the necessary data is collected. The configuration file required for setting the Server API is not automatically generated on all hosts after installing the Wazuh Dashboard package and starting the service. This file is only created on RHEL and Ubuntu operating systems. TASK [wazuh-dashboard : Dashboard | Configure /usr/share/wazuh-dashboard/data/wazuh/config/wazuh.yml file] ***
changed: [18.*.*.215]
changed: [52.*.*.191]
fatal: [3.*.*.224]: FAILED! => {"changed": false, "msg": "Path /usr/share/wazuh-dashboard/data/wazuh/config/wazuh.yml does not exist !", "rc": 257}
fatal: [100.*.*.210]: FAILED! => {"changed": false, "msg": "Path /usr/share/wazuh-dashboard/data/wazuh/config/wazuh.yml does not exist !", "rc": 257}
fatal: [44.*.*.203]: FAILED! => {"changed": false, "msg": "Path /usr/share/wazuh-dashboard/data/wazuh/config/wazuh.yml does not exist !", "rc": 257}
|
UpdateAfter reaching out to the dashboard team to gather more information about the existence of this file and why it was created in some systems but not in others, we learned that the As a result, a task was implemented to modify the default value for the API host (localhost) to the IP address registered as the Wazuh Server instance in the Ansible deployment. Additionally, the other changes and improvements (previously mentioned) were implemented. The corresponding evidence is attached below. EvidenceAnsible results: ...
PLAY RECAP *********************************************************************
al2_amd : ok=16 changed=11 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
centos9_amd : ok=17 changed=11 unreachable=0 failed=0 skipped=7 rescued=0 ignored=0
debian12_amd : ok=16 changed=11 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
rhel9_arm : ok=16 changed=10 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
ubuntu22_arm : ok=16 changed=10 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
Complete Ansible output:PLAY [all] *********************************************************************
TASK [Gathering Facts] *********************************************************
ok: [rhel9_arm]
ok: [al2_amd]
ok: [ubuntu22_arm]
ok: [debian12_amd]
ok: [centos9_amd]
TASK [wazuh-dashboard : include_vars] ******************************************
ok: [centos9_amd]
ok: [debian12_amd]
ok: [ubuntu22_arm]
ok: [rhel9_arm]
ok: [al2_amd]
TASK [wazuh-dashboard : include_vars] ******************************************
ok: [centos9_amd]
ok: [debian12_amd]
ok: [ubuntu22_arm]
ok: [rhel9_arm]
ok: [al2_amd]
TASK [wazuh-dashboard : Retrieve local_configs_path directory information] *****
ok: [centos9_amd -> localhost]
TASK [wazuh-dashboard : fail] **************************************************
skipping: [centos9_amd]
TASK [wazuh-dashboard : Ensure wazuh-dashboard package download directory exists] ***
changed: [ubuntu22_arm]
changed: [rhel9_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora | Install Dashboard dependencies] ***
skipping: [debian12_amd]
skipping: [ubuntu22_arm]
ok: [al2_amd]
ok: [centos9_amd]
ok: [rhel9_arm]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora (x86_64) | Download wazuh-dashboard package] ***
skipping: [debian12_amd]
skipping: [ubuntu22_arm]
skipping: [rhel9_arm]
changed: [al2_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : RedHat/CentOS/Fedora (aarch64) | Download wazuh-dashboard package] ***
skipping: [centos9_amd]
skipping: [debian12_amd]
skipping: [ubuntu22_arm]
skipping: [al2_amd]
changed: [rhel9_arm]
TASK [wazuh-dashboard : Debian-based | Install Dashboard dependencies] *********
skipping: [centos9_amd]
skipping: [rhel9_arm]
skipping: [al2_amd]
ok: [debian12_amd]
ok: [ubuntu22_arm]
TASK [wazuh-dashboard : Debian-based (AMD64) | Download wazuh-dashboard package] ***
skipping: [centos9_amd]
skipping: [ubuntu22_arm]
skipping: [rhel9_arm]
skipping: [al2_amd]
changed: [debian12_amd]
TASK [wazuh-dashboard : Debian-based (ARM64) | Download wazuh-dashboard package] ***
skipping: [centos9_amd]
skipping: [debian12_amd]
skipping: [rhel9_arm]
skipping: [al2_amd]
changed: [ubuntu22_arm]
TASK [wazuh-dashboard : Linux CentOS/RedHat | Install wazuh-dashboard using yum] ***
skipping: [debian12_amd]
skipping: [ubuntu22_arm]
changed: [al2_amd]
changed: [rhel9_arm]
changed: [centos9_amd]
TASK [wazuh-dashboard : Linux Debian | Install wazuh-dashboard using APT] ******
skipping: [centos9_amd]
skipping: [rhel9_arm]
skipping: [al2_amd]
changed: [ubuntu22_arm]
changed: [debian12_amd]
TASK [wazuh-dashboard : Dashboard | Remove current opensearch.hosts configuration] ***
changed: [ubuntu22_arm]
changed: [debian12_amd]
changed: [centos9_amd]
changed: [al2_amd]
changed: [rhel9_arm]
TASK [wazuh-dashboard : Dashboard | Add opensearch.hosts configuration] ********
changed: [rhel9_arm]
changed: [ubuntu22_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : Dashboard | Update Wazuh API URL] **********************
ok: [ubuntu22_arm]
ok: [rhel9_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : Dashboard | Remove comments from configuration file] ***
changed: [ubuntu22_arm]
changed: [rhel9_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : Dashboard | Remove empty lines from config.yml file] ***
changed: [ubuntu22_arm]
changed: [rhel9_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [centos9_amd]
TASK [wazuh-dashboard : Copy the certificates from local to the Wazuh dashboard instance] ***
changed: [ubuntu22_arm] => (item=root-ca.pem)
changed: [rhel9_arm] => (item=root-ca.pem)
changed: [al2_amd] => (item=root-ca.pem)
changed: [debian12_amd] => (item=root-ca.pem)
changed: [centos9_amd] => (item=root-ca.pem)
changed: [ubuntu22_arm] => (item=dashboard-key.pem)
changed: [rhel9_arm] => (item=dashboard-key.pem)
changed: [al2_amd] => (item=dashboard-key.pem)
changed: [debian12_amd] => (item=dashboard-key.pem)
changed: [centos9_amd] => (item=dashboard-key.pem)
changed: [ubuntu22_arm] => (item=dashboard.pem)
changed: [rhel9_arm] => (item=dashboard.pem)
changed: [al2_amd] => (item=dashboard.pem)
changed: [debian12_amd] => (item=dashboard.pem)
changed: [centos9_amd] => (item=dashboard.pem)
TASK [wazuh-dashboard : Rename certificates to match default names] ************
skipping: [centos9_amd] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [centos9_amd] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [debian12_amd] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [debian12_amd] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [centos9_amd]
skipping: [ubuntu22_arm] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [ubuntu22_arm] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [debian12_amd]
skipping: [ubuntu22_arm]
skipping: [rhel9_arm] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [rhel9_arm] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [rhel9_arm]
skipping: [al2_amd] => (item={'src': 'dashboard.pem', 'dest': 'dashboard.pem'})
skipping: [al2_amd] => (item={'src': 'dashboard-key.pem', 'dest': 'dashboard-key.pem'})
skipping: [al2_amd]
TASK [wazuh-dashboard : Ensure Wazuh dashboard started and enabled] ************
changed: [al2_amd]
changed: [rhel9_arm]
changed: [centos9_amd]
changed: [ubuntu22_arm]
changed: [debian12_amd]
TASK [wazuh-dashboard : Wait for Wazuh dashboard to be ready] ******************
FAILED - RETRYING: [ubuntu22_arm]: Wait for Wazuh dashboard to be ready (10 retries left).
FAILED - RETRYING: [rhel9_arm]: Wait for Wazuh dashboard to be ready (10 retries left).
FAILED - RETRYING: [al2_amd]: Wait for Wazuh dashboard to be ready (10 retries left).
FAILED - RETRYING: [debian12_amd]: Wait for Wazuh dashboard to be ready (10 retries left).
FAILED - RETRYING: [centos9_amd]: Wait for Wazuh dashboard to be ready (10 retries left).
ok: [ubuntu22_arm]
ok: [rhel9_arm]
ok: [al2_amd]
ok: [debian12_amd]
ok: [centos9_amd]
TASK [wazuh-dashboard : Remove installation leftovers] *************************
changed: [ubuntu22_arm]
changed: [al2_amd]
changed: [debian12_amd]
changed: [rhel9_arm]
changed: [centos9_amd]
PLAY RECAP *********************************************************************
al2_amd : ok=16 changed=11 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
centos9_amd : ok=17 changed=11 unreachable=0 failed=0 skipped=7 rescued=0 ignored=0
debian12_amd : ok=16 changed=11 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
rhel9_arm : ok=16 changed=10 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
ubuntu22_arm : ok=16 changed=10 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
|
Description
The ansible role for Wazuh dashboard (
roles/wazuh-dashboard
) is intended to simplify the installation and configuration of the Wazuh dashboard component.For a more detailed description, please refer to the parent commit (#1493).
Tasks
The text was updated successfully, but these errors were encountered: