Update userscript.sh

This commit is contained in:
gutosie
2024-01-08 13:10:15 +02:00
committed by GitHub
parent 3e0c9390cd
commit 507f209ed1

View File

@@ -19,33 +19,31 @@ if [ -f /.control_boot_new_image ] ; then
break ; break ;
else else
#if [ -f /usr/lib/python2.7 ] ; then #if [ -f /usr/lib/python2.7 ] ; then
echo "_(Checking internet connection)..." echo "_____(Checking internet connection)..."
ping -c 1 github.com 1>/dev/null 2>%1 ping -c 1 github.com 1>/dev/null 2>%1
if [ $? -gt 0 ]; then if [ $? -gt 0 ]; then
echo -n "github server unavailable" echo -n "_____github server unavailable..."
echo -n "The network has no connection. It is not OK" echo -n "_____The network has no connection..."
echo -n "Network restart..." echo -n "_____Network RESTART..."
echo "_____restart network connection_____" echo "_____restart network connection..."
/etc/init.d/vuplus-wifi-init.sh /etc/init.d/vuplus-wifi-init.sh
/etc/wpa_supplicant/action_wpa.sh /etc/wpa_supplicant/action_wpa.sh
/etc/wpa_supplicant/functions.sh /etc/wpa_supplicant/functions.sh
/etc/wpa_supplicant/ifupdown.sh
ifconfig sys0 up ifconfig sys0 up
/etc/udhcpc.d/50default restart /etc/udhcpc.d/50default restart
/etc/wpa_supplicant/ifupdown.sh #/etc/init.d/networking restart
#/etc/init.d/networking force-reload echo "_____restart network finish..."
sleep 5 sleep 1
else else
echo "github server available" echo "github server available..."
echo "The network has a connection. It is OK" echo "_____The network has a connection. It is OK..."
fi fi
#else #else
#break ; #break ;
#fi #fi
fi fi
if [ -f /STARTUP ] ; then
rm -r /STARTU*
fi
if [ -f /zImage ] ; then if [ -f /zImage ] ; then
rm -r /zImage rm -r /zImage
fi fi
@@ -55,6 +53,8 @@ fi
if [ -f /home/root/%1 ] ; then if [ -f /home/root/%1 ] ; then
rm -f /home/root/%1 rm -f /home/root/%1
fi fi
#/etc/init.d/networking restart; if [ -f /STARTUP ] ; then
rm -r /STARTU*
fi
echo "_____[NEOBOOT] used userscript_____ " echo "_____[NEOBOOT] used userscript_____ "
exit 0 exit 0