m0duspwnens
2020-05-19 10:14:40 -04:00
parent 1d677bb529
commit 4f65d17690
4 changed files with 9 additions and 12 deletions

View File

@@ -43,14 +43,6 @@ ossec:
# - user: 945 # - user: 945
# - group: 945 # - group: 945
# Add wazuh agent
wazuhpkgs:
pkg.installed:
- skip_suggestions: False
- pkgs:
- wazuh-agent: 3.10.2-1
- update_holds: True
# Add Wazuh agent conf # Add Wazuh agent conf
wazuhagentconf: wazuhagentconf:
file.managed: file.managed:

View File

@@ -1131,8 +1131,7 @@ saltify() {
apt-key add "$temp_install_dir"/gpg/GPG-KEY-WAZUH >> "$setup_log" 2>&1 apt-key add "$temp_install_dir"/gpg/GPG-KEY-WAZUH >> "$setup_log" 2>&1
echo "deb http://repo.saltstack.com$py_ver_url_path/ubuntu/$ubuntu_version/amd64/archive/2019.2.5/ $OSVER main" > /etc/apt/sources.list.d/saltstack.list >> "$setup_log" 2>&1 echo "deb http://repo.saltstack.com$py_ver_url_path/ubuntu/$ubuntu_version/amd64/archive/2019.2.5/ $OSVER main" > /etc/apt/sources.list.d/saltstack.list >> "$setup_log" 2>&1
echo "deb https://packages.wazuh.com/3.x/apt/ stable main" | tee /etc/apt/sources.list.d/wazuh.list >> "$setup_log" 2>&1 echo "deb https://packages.wazuh.com/3.x/apt/ stable main" | tee /etc/apt/sources.list.d/wazuh.list >> "$setup_log" 2>&1
apt-mark hold wazuh-agent >> "$setup_log" 2>&1 ;;
;;
esac esac
apt-get update >> "$setup_log" 2>&1 apt-get update >> "$setup_log" 2>&1
set_progress_str 8 'Installing salt-minion & python modules' set_progress_str 8 'Installing salt-minion & python modules'

View File

@@ -424,6 +424,13 @@ export percentage=0
fi fi
if [[ "$WAZUH" = 1 ]]; then if [[ "$WAZUH" = 1 ]]; then
if [ $OS = 'centos' ]; then
yum -y install wazuh-agent-3.10.2-1 >> "$setup_log" 2>&1
echo "exclude=wazuh-agent" >> /etc/yum.repos.d/wazuh.repo
else
apt-get -y install wazuh-agent=3.10.2-1 >> "$setup_log" 2>&1
apt-mark hold wazuh-agent >> "$setup_log" 2>&1
fi
set_progress_str 75 "$(print_salt_state_apply 'wazuh')" set_progress_str 75 "$(print_salt_state_apply 'wazuh')"
salt-call state.apply -l info wazuh >> $setup_log 2>&1 salt-call state.apply -l info wazuh >> $setup_log 2>&1
fi fi

View File

@@ -5,4 +5,3 @@ enabled=1
name=Wazuh repository name=Wazuh repository
baseurl=https://packages.wazuh.com/3.x/yum/ baseurl=https://packages.wazuh.com/3.x/yum/
protect=1 protect=1
exclude=wazuh-agent