Browse Source

Merge branch 'unstable' of evolix/ansible-roles into stable

stable
Jérémy Lecour Gitea 8 months ago
parent
commit
77d0081cbe
2 changed files with 21 additions and 13 deletions
  1. +5
    -0
      CHANGELOG.md
  2. +16
    -13
      evocheck/files/evocheck.sh

+ 5
- 0
CHANGELOG.md View File

@@ -18,6 +18,11 @@ The **patch** part changes incrementally at each release.

### Security

## [9.10.1] - 2019-06-21

### Changed
* evocheck : update (version 19.06) from upstream

## [9.10.0] - 2019-06-21

### Added


+ 16
- 13
evocheck/files/evocheck.sh View File

@@ -891,17 +891,15 @@ check_mysqlmunin() {
}
check_mysqlnrpe() {
if is_debian_stretch && is_installed mariadb-server; then
nagios_home=$(getent passwd "nagios" | cut -d: -f6)
nagios_file_abs="${nagios_home}/.my.cnf"
nagios_file_sym="~nagios/.my.cnf"
nagios_file=~nagios/.my.cnf

if ! test -f $nagios_file_abs; then
failed "IS_MYSQLNRPE" "$nagios_file_abs is missing"
elif [ "$(stat -c %U $nagios_file_abs)" != "nagios" ] \
|| [ "$(stat -c %a $nagios_file_abs)" != "600" ]; then
failed "IS_MYSQLNRPE" "$nagios_file_abs has wrong permissions"
if ! test -f ${nagios_file}; then
failed "IS_MYSQLNRPE" "${nagios_file} is missing"
elif [ "$(stat -c %U ${nagios_file})" != "nagios" ] \
|| [ "$(stat -c %a ${nagios_file})" != "600" ]; then
failed "IS_MYSQLNRPE" "${nagios_file} has wrong permissions"
else
grep -q -F "command[check_mysql]=/usr/lib/nagios/plugins/check_mysql -H localhost -f $nagios_file_sym" /etc/nagios/nrpe.d/evolix.cfg \
grep -q -F "command[check_mysql]=/usr/lib/nagios/plugins/check_mysql" /etc/nagios/nrpe.d/evolix.cfg \
|| failed "IS_MYSQLNRPE" "check_mysql is missing"
fi
fi
@@ -1095,9 +1093,7 @@ check_evomaintenanceconf() {
&& grep "^FULLFROM" $f | grep -qv "John Doe <jdoe@example.com>" \
&& grep "^URGENCYFROM" $f | grep -qv "mama.doe@example.com" \
&& grep "^URGENCYTEL" $f | grep -qv "06.00.00.00.00" \
&& grep "^REALM" $f | grep -qv "example.com" \
&& grep "^API_ENDPOINT" $f | grep -qv "https://example.com/api/" \
&& grep "^API_KEY" $f | grep -qv "secretkey";
&& grep "^REALM" $f | grep -qv "example.com"
} || failed "IS_EVOMAINTENANCECONF" "evomaintenance is not correctly configured"
else
failed "IS_EVOMAINTENANCECONF" "Configuration file \`$f' is missing"
@@ -1128,6 +1124,12 @@ check_evobackup_incs() {
fi
}

check_osprober() {
if is_installed os-prober qemu-kvm; then
failed "IS_OSPROBER" "Removal of os-prober package is recommended as it can cause serious issue on KVM server"
fi
}

main() {
# Default return code : 0 = no error
RC=0
@@ -1248,6 +1250,7 @@ main() {
test "${IS_MELTDOWN_SPECTRE:=1}" = 1 && check_meltdown_spectre
test "${IS_OLD_HOME_DIR:=1}" = 1 && check_old_home_dir
test "${IS_EVOBACKUP_INCS:=1}" = 1 && check_evobackup_incs
test "${IS_OSPROBER:=1}" = 1 && check_osprober
fi

#-----------------------------------------------------------
@@ -1360,7 +1363,7 @@ readonly PROGDIR=$(realpath -m "$(dirname "$0")")
# shellcheck disable=2124
readonly ARGS=$@

readonly VERSION="19.04"
readonly VERSION="19.06"

# Disable LANG*
export LANG=C


Loading…
Cancel
Save