activation

This commit is contained in:
gutosie
2020-04-11 09:16:23 +02:00
committed by GitHub
parent 940bc856c5
commit d8631f93e0
2 changed files with 11 additions and 22 deletions

View File

@@ -1,23 +1,14 @@
#!/bin/sh
TARGET=Flash
NEODEVICE=`cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
IMAGEKATALOG=ImageBoot
UPLOADKATALOG=ImagesUpload
if [ -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$IMAGEKATALOG/$TARGET/.control_ok ]; then
echo "No Error - Booting image normal..."
else
if [ -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$IMAGEKATALOG/$TARGET/.control_boot_new_image ]; then
echo "First start image - The first attempt to launch a new image... ";
rm -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$IMAGEKATALOG/$TARGET/.control_boot_new_image > /dev/null 2>&1
else
echo "Wrong kernel. Press number 3" > `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$UPLOAD/.kernel/used_flash_kernel
ln -sfn /sbin/init.sysvinit /sbin/init
echo "Flash " > `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`$IMAGEKATALOG/.neonextboot
sleep 8; reboot -f
fi
TARGET=Flash
if [ -f $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
TARGET=`cat $NEODEVICE$IMAGEKATALOG/.neonextboot`
fi
if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
mnttest="nouuid"
if [ -e $NEOBOOT/bin/install ]; then
@@ -41,7 +32,8 @@ if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
fi
fi
if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ] ; then
if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ] ; then
export PATH=/bin:/usr/bin:/sbin:/usr/sbin
/bin/mount -t proc proc /proc > /dev/null 2>&1
/bin/mount -t sysfs sysfs /sys > /dev/null 2>&1
/sbin/depmod -Ae > /dev/null 2>&1
@@ -55,10 +47,6 @@ if [ ! -e $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
sleep 5; #reboot -f
fi
if [ -f $NEODEVICE$IMAGEKATALOG/.neonextboot ]; then
TARGET=`cat $NEODEVICE$IMAGEKATALOG/.neonextboot`
fi
if [ $TARGET = "Flash" ]; then
echo "BOOTNEO is booting image from " $TARGET
@@ -100,12 +88,12 @@ else
fi
fi
fi
/usr/bin/showiframe /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/error.mvi > /dev/null 2>&1
echo "Wrong kernel. Press number 3" > $DEVICEBOOT$UPLOAD/.kernel/used_flash_kernel
ln -sfn /sbin/init.sysvinit /sbin/init
echo "Flash " > $DEVICEBOOT$DIRECTORY/.neonextboot
echo "Error - NeoBoot he can not run it image !!! "
echo "Restart STB - Back to Flash... "
/usr/bin/showiframe /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/error.mvi > /dev/null 2>&1
sleep 10; #reboot -f
fi

View File

@@ -37,9 +37,10 @@ else
fi
echo "Mount kernel filesystems ..."
if [ `mount | grep /proc | wc -l` -lt 1 ]; then
export PATH=/bin:/usr/bin:/sbin:/usr/sbin
/bin/mount -a -t media
/bin/mount -t proc proc /proc > /dev/null 2>&1
/bin/mount -t sysfs sysfs /sys > /dev/null 2>&1
/bin/mount -n -t proc proc /proc > /dev/null 2>&1
/bin/mount -n -t sysfs sysfs /sys > /dev/null 2>&1
/sbin/depmod -Ae > /dev/null 2>&1
fi