GIF89a; Mini Shell

Mini Shell

Direktori : /proc/self/root/etc/cron.daily/
Upload File :
Current File : //proc/self/root/etc/cron.daily/imunify-antivirus.cron

#!/bin/bash
#
# imunify-antivirus daily cron jobs.
#
# Usage:
#   ./imunify-antivirus.cron [<logfile>]
#
# if logfile is not specified, the output will be discarded
# If imunify360-firewall is installed, doing nothing
log=${1:-/dev/null}

main()
{
    echo "Checking if imunify360-firewall is installed"
    if rpm -qi imunify360-firewall; then
        echo "Imunify360-installed, skipping antivirus cron"
        exit 0
    fi

    echo "Starting daily imunify-antivirus cron jobs at $(date)"
    /usr/bin/imunify360-agent check-domains

    PACKAGES="imunify-antivirus \
              ai-bolit \
              alt-php-internal \
              alt-php-hyperscan \
              app-version-detector \
              imunify-common \
              imunify-notifier \
              imunify360-venv \
              imunify-core \
              imunify-ui"
    /usr/libexec/report-command-error /usr/bin/yum update --assumeyes $PACKAGES

    /usr/bin/imunify-antivirus version
    echo "Finished daily imunify-antivirus cron jobs at $(date)"
}

main >> "$log" 2>&1

./BlackJoker Mini Shell 1.0