bitbake: toaster: fix file name collision

When toaster is used by multiple users on the same machine,
it is possible that files in /tmp have a name race.

This patch makes sure that the files have unique names.

(Bitbake rev: d4a47bc84f762666a847f1152cc2e75c9ef36092)

Signed-off-by: Belen Barros Pena <belen.barros.pena@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Belen Barros Pena 2014-11-18 15:02:17 +00:00 committed by Richard Purdie
parent c09e56168e
commit 2f3e40c5d8
1 changed files with 1 additions and 1 deletions

View File

@ -69,7 +69,7 @@ function webserverStartAll()
fi
if [ $retval -eq 0 ]; then
echo "Starting webserver"
python $BBBASEDIR/lib/toaster/manage.py runserver "0.0.0.0:$WEB_PORT" </dev/null >${BUILDDIR}/toaster_web.log 2>&1 & echo $! >${BUILDDIR}/.toastermain.pid
python $BBBASEDIR/lib/toaster/manage.py runserver "0.0.0.0:$WEB_PORT" </dev/null >${BUILDDIR}/toaster_web_$$.log 2>&1 & echo $! >${BUILDDIR}/.toastermain.pid
sleep 1
if ! cat "${BUILDDIR}/.toastermain.pid" | xargs -I{} kill -0 {} ; then
retval=1