summaryrefslogtreecommitdiffstats
path: root/bin/toaster
diff options
context:
space:
mode:
authorAlexandru DAMIAN <alexandru.damian@intel.com>2014-08-12 15:45:48 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-08-29 13:56:39 +0100
commit2aab77dfccb538e2b09829841ea6c464d40cafb1 (patch)
tree3927682547f903fe72a9e8713102bc09bd98ed67 /bin/toaster
parent59f4a9750a6c4f5360a91e3a4d1c03ceb42da086 (diff)
downloadbitbake-contrib-2aab77dfccb538e2b09829841ea6c464d40cafb1.tar.gz
toaster: update checksettings command for auto-detection
We enhance the checksettings command to try to automatically detect settings for running on localhost. The checksettings will look for a nearby poky layer source, for a nearby build directory, and will try to import settings from "toasterconf.json" files found in the local layer. On new configuration, it will also perform updates from the layer source. Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Diffstat (limited to 'bin/toaster')
-rwxr-xr-xbin/toaster9
1 files changed, 6 insertions, 3 deletions
diff --git a/bin/toaster b/bin/toaster
index ce16de6c3..2fabe5c8e 100755
--- a/bin/toaster
+++ b/bin/toaster
@@ -65,10 +65,10 @@ function webserverStartAll()
fi
if [ "x$TOASTER_MANAGED" == "x1" ]; then
python $BBBASEDIR/lib/toaster/manage.py migrate bldcontrol || retval=1
- python $BBBASEDIR/lib/toaster/manage.py checksettings || retval=1
+ python $BBBASEDIR/lib/toaster/manage.py checksettings --traceback || retval=1
fi
- echo "Starting webserver"
if [ $retval -eq 0 ]; then
+ echo "Starting webserver"
python $BBBASEDIR/lib/toaster/manage.py runserver 0.0.0.0:8000 </dev/null >${BUILDDIR}/toaster_web.log 2>&1 & echo $! >${BUILDDIR}/.toastermain.pid
sleep 1
if ! cat "${BUILDDIR}/.toastermain.pid" | xargs -I{} kill -0 {} ; then
@@ -144,7 +144,10 @@ if [ -z "$ZSH_NAME" ] && [ `basename \"$0\"` = `basename \"$BASH_SOURCE\"` ]; th
}
TOASTER_MANAGED=1
export TOASTER_MANAGED=1
- webserverStartAll || (echo "Fail to start the web server, stopping" 1>&2 && exit 1)
+ if ! webserverStartAll; then
+ echo "Failed to start the web server, stopping" 1>&2;
+ exit 1;
+ fi
xdg-open http://0.0.0.0:8000/ >/dev/null 2>&1 &
trap trap_ctrlc SIGINT
echo "Running. Stop with Ctrl-C"