The aim of this PR is to modify the Wazuh installation assistant to install the lsof and openssl packages only when they are needed. Before, the tool installed these dependencies when they were not necessary.
Logs example
Notice that the dependencies are installed only when needed, and then, removed.
:green_circle: Certificates generation
root@ubuntu22:/home/vagrant# lsof
bash: /usr/bin/lsof: No such file or directory
root@ubuntu22:/home/vagrant# openssl
bash: /usr/bin/openssl: No such file or directory
root@ubuntu22:/home/vagrant# bash wazuh-install.sh -g -i
04/03/2024 13:57:34 INFO: Starting Wazuh installation assistant. Wazuh version: 4.8.0
04/03/2024 13:57:34 INFO: Verbose logging redirected to /var/log/wazuh-install.log
04/03/2024 13:57:40 WARNING: Hardware and system checks ignored.
04/03/2024 13:57:40 INFO: --- Configuration files ---
04/03/2024 13:57:40 INFO: Generating configuration files.
04/03/2024 13:57:40 INFO: --- Dependencies ----
04/03/2024 13:57:40 INFO: Installing openssl.
04/03/2024 13:57:44 INFO: Created wazuh-install-files.tar. It contains the Wazuh cluster key, certificates, and passwords necessary for installation.
04/03/2024 13:57:44 INFO: --- Dependencies ----
04/03/2024 13:57:44 INFO: Removing openssl.
root@ubuntu22:/home/vagrant# tar -xvf wazuh-install-files.tar
wazuh-install-files/
wazuh-install-files/root-ca.key
wazuh-install-files/wazuh-indexer-key.pem
wazuh-install-files/admin-key.pem
wazuh-install-files/wazuh-passwords.txt
wazuh-install-files/config.yml
wazuh-install-files/root-ca.pem
wazuh-install-files/admin.pem
wazuh-install-files/wazuh-dashboard-key.pem
wazuh-install-files/wazuh-server-key.pem
wazuh-install-files/wazuh-server.pem
wazuh-install-files/wazuh-dashboard.pem
wazuh-install-files/wazuh-indexer.pem
root@ubuntu22:/home/vagrant#
Description
The aim of this PR is to modify the Wazuh installation assistant to install the
lsof
andopenssl
packages only when they are needed. Before, the tool installed these dependencies when they were not necessary.Logs example
Notice that the dependencies are installed only when needed, and then, removed.
:green_circle: Certificates generation
:green_circle: Cluster initialization
Tests
:green_circle: RHEL7 https://ci.wazuh.info/job/Test_unattended/5379/ :green_circle: AL2 https://ci.wazuh.info/job/Test_unattended/5378/ :green_circle: Ubuntu Focal https://ci.wazuh.info/job/Test_unattended/5377/ :green_circle: Ubuntu Xenial https://ci.wazuh.info/job/Test_unattended/5376/ :green_circle: Ubuntu Bionic https://ci.wazuh.info/job/Test_unattended/5375/ :green_circle: CentOS 8 https://ci.wazuh.info/job/Test_unattended/5374/ :green_circle: CentOS 7 https://ci.wazuh.info/job/Test_unattended/5373/ :green_circle: RHEL8 https://ci.wazuh.info/job/Test_unattended/5372/