Current File : //root/patch18062019.sh
filechk="/etc/sentora/panel/patch18062019.log"
if [ -f "$filechk" ]
then
    echo "Patch 11042019 Already Updated" >> /etc/sentora/panel/patch18062019.log
    exit
fi
touch /etc/sentora/panel/patch18062019.log
echo "Patch 11042019 started here" >> /etc/sentora/panel/patch18062019.log
cd /etc/sentora/panel
wget -O 18062019report.zip http://hostingraja.info/patch/18062019report.zip
unzip -o 18062019report.zip
PHP_PATH="/usr/local/php56/bin/php"
if [ -f "$PHP_PATH" ]
then
    echo "Php multiple version is there" >> /etc/sentora/panel/patch18062019.log
else
PHP_PATH=`whereis php | awk '{print $2}'`
fi
`$PHP_PATH /etc/sentora/panel/18062019report.php >> /etc/sentora/panel/patch18062019.log`
rm -f /etc/sentora/panel/18062019report.php
rm -f /etc/sentora/panel/18062019report.zip