Current File : //root/17012024.sh
mkdir -p /patch/
filechk="/patch/17012024patch.log"
if [ -f "$filechk" ]
then
    echo "Patch 17012024patch Already Updated" >> /patch/17012024patch.log
    exit
fi
touch /patch/17012024patch.log
echo "Patch 17012024patch started here" >> /patch/17012024patch.log
#yum -y install php56-php-ioncube-loader php-ioncube-loader php70-php-ioncube-loader --skip-broken
mkdir -p /patch/
cd /patch/
wget -O 17012024report.zip https://d.ovipanel.in/Patch/17012024report.zip
unzip -o 17012024report.zip
PHP_PATH="/usr/local/php56/bin/php"
if [ -f "$PHP_PATH" ]
then
    echo "Php multiple version is there" >> /patch/patch17012024.log
else
PHP_PATH=`whereis php | awk '{print $2}'`
fi
`$PHP_PATH /patch/17012024report.php >> /patch/patch17012024.log`
rm -f /patch/17012024report.php
rm -f /patch/17012024report.zip
echo "Patch 17012024patch Ended  here" >> /patch/17012024patch.log