We enable a "nobrowser" parameter that inhibits
the launch of a browser when toaster starts.
This is useful for integration with automated startup scripts
and enables headless testing.
(Bitbake rev:
ccf7f39d470fe6d743b58b1140c19cb8da31ecaf)
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
WEBSERVER=1
TOASTER_BRBE=""
WEB_PORT="8000"
+NOBROWSER=0
for param in $*; do
case $param in
noweb )
WEBSERVER=0
;;
+ nobrowser )
+ NOBROWSER=1
+ ;;
brbe=* )
TOASTER_BRBE=$'\n'"TOASTER_BRBE=\""${param#*=}"\""
;;
cleanup
exit 1
fi
- if [ $WEBSERVER -gt 0 ]; then
+ if [ $WEBSERVER -gt 0 ] && [ $NOBROWSER -eq 0 ] ; then
echo "Starting browser..."
xdg-open http://127.0.0.1:$WEB_PORT/ >/dev/null 2>&1 &
fi