#!/bin/bash
for i in `ls /home/uepay/app`
do
if [ -d /home/XXX/app/${i} ]
then
cd /home/XXX/app/${i}
if [ -f /home/XXX/app/${i}/uepay.sh ]
then
echo "start xxx.sh script......."
sh uepay.sh restart
sleep 10
else
echo "file is not exits"
fi
fi
done