Commit c598f2c8 authored by Franco Fichtner's avatar Franco Fichtner

firmware: allow stderr to reach the GUI progress window

parent 4fc57390
......@@ -37,7 +37,7 @@ fi
: > ${PKG_PROGRESS_FILE}
echo "***GOT REQUEST TO INSTALL: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
pkg install -y $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg autoremove -y >> ${PKG_PROGRESS_FILE}
pkg clean -ya >> ${PKG_PROGRESS_FILE}
pkg install -y $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
pkg autoremove -y 2>&1 >> ${PKG_PROGRESS_FILE}
pkg clean -ya 2>&1 >> ${PKG_PROGRESS_FILE}
echo '***DONE***' >> ${PKG_PROGRESS_FILE}
......@@ -37,5 +37,5 @@ fi
: > ${PKG_PROGRESS_FILE}
echo "***GOT REQUEST TO LOCK: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
pkg lock -y $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg lock -y $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
echo '***DONE***' >> ${PKG_PROGRESS_FILE}
......@@ -37,7 +37,7 @@ fi
: > ${PKG_PROGRESS_FILE}
echo "***GOT REQUEST TO REINSTALL: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
pkg install -yf $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg autoremove -y >> ${PKG_PROGRESS_FILE}
pkg clean -ya >> ${PKG_PROGRESS_FILE}
pkg install -yf $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
pkg autoremove -y 2>&1 >> ${PKG_PROGRESS_FILE}
pkg clean -ya 2>&1 >> ${PKG_PROGRESS_FILE}
echo '***DONE***' >> ${PKG_PROGRESS_FILE}
......@@ -37,7 +37,7 @@ fi
: > ${PKG_PROGRESS_FILE}
echo "***GOT REQUEST TO REINSTALL: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
pkg remove -y $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg autoremove -y >> ${PKG_PROGRESS_FILE}
pkg clean -ya >> ${PKG_PROGRESS_FILE}
pkg remove -y $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
pkg autoremove -y 2>&1 >> ${PKG_PROGRESS_FILE}
pkg clean -ya 2>&1 >> ${PKG_PROGRESS_FILE}
echo '***DONE***' >> ${PKG_PROGRESS_FILE}
......@@ -37,5 +37,5 @@ fi
: > ${PKG_PROGRESS_FILE}
echo "***GOT REQUEST TO UNLOCK: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
pkg unlock -y $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg unlock -y $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
echo '***DONE***' >> ${PKG_PROGRESS_FILE}
......@@ -41,17 +41,17 @@ echo "***GOT REQUEST TO UPGRADE: $PACKAGE***" >> ${PKG_PROGRESS_FILE}
if [ "$PACKAGE" == "all" ]; then
# update all installed packages
opnsense-update -p >> ${PKG_PROGRESS_FILE}
opnsense-update -p 2>&1 >> ${PKG_PROGRESS_FILE}
# restart the web server
/usr/local/etc/rc.restart_webgui >> ${PKG_PROGRESS_FILE}
/usr/local/etc/rc.restart_webgui 2>&1 >> ${PKG_PROGRESS_FILE}
# if we can update base, we'll do that as well
if opnsense-update -c; then
if opnsense-update -bk >> ${PKG_PROGRESS_FILE}; then
if opnsense-update -bk 2>&1 >> ${PKG_PROGRESS_FILE}; then
REBOOT=1
fi
fi
elif [ "$PACKAGE" == "pkg" ]; then
pkg upgrade -y $PACKAGE >> ${PKG_PROGRESS_FILE}
pkg upgrade -y $PACKAGE 2>&1 >> ${PKG_PROGRESS_FILE}
echo "*** PLEASE CHECK FOR MORE UPGRADES"
else
echo "Cannot update $PACKAGE" >> ${PKG_PROGRESS_FILE}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment