mirror of
https://github.com/gtxaspec/wz_mini_hacks.git
synced 2024-11-23 14:07:24 +00:00
Update upgrade-run.sh echo messages for better coherence
This commit is contained in:
parent
43f988e6a1
commit
703b59e5b0
@ -1,19 +1,20 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
if df / | grep -q overlayfs; then
|
if df / | grep -q overlayfs; then
|
||||||
echo "Unable to upgrade because rootfs is overlay"
|
echo "Unable to upgrade because overlay rootfs being used"
|
||||||
echo "Please disable rootfs overlay by setting ENABLE_OVERLAY_FOR_ROOTFS=\"false\" in wz_mini.conf and reboot first"
|
read -r -p "Do you want to disable overlay rootfs now? This action will reboot your camera.[y/N]" response
|
||||||
echo "You can change it back after upgrade is finished"
|
|
||||||
read -r -p "Do you want to disable overlay and reboot now? [y/N]" response
|
|
||||||
case "$response" in
|
case "$response" in
|
||||||
[yY][eE][sS]|[yY])
|
[yY][eE][sS]|[yY])
|
||||||
|
echo "Proceeding..."
|
||||||
sed -i 's/ENABLE_OVERLAY_FOR_ROOTFS=\"true\"/ENABLE_OVERLAY_FOR_ROOTFS=\"false\"/g' /opt/wz_mini/wz_mini.conf
|
sed -i 's/ENABLE_OVERLAY_FOR_ROOTFS=\"true\"/ENABLE_OVERLAY_FOR_ROOTFS=\"false\"/g' /opt/wz_mini/wz_mini.conf
|
||||||
echo "You can run upgrade-run.sh to start upgrade after the camera reboots"
|
echo "wz_mini.conf has been changed to disable overlay rootfs on next reboot."
|
||||||
|
echo "Please connect to your camera and run upgrade-run.sh after the reboot is finished"
|
||||||
|
echo "Rebooting now..."
|
||||||
reboot
|
reboot
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
echo "Aborting upgrade"
|
echo "Upgrade has been aborted"
|
||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
Loading…
Reference in New Issue
Block a user