build.sh script switches to local WebUI build in case release tarball is not available

This commit is contained in:
Andrea Bondavalli 2021-05-28 17:27:06 +02:00
parent 49949b1f74
commit 185dd36452
2 changed files with 10 additions and 5 deletions

View File

@ -26,13 +26,17 @@ fi
cd ..
cd webui
# echo "Building and installing webui ..."
# npm install react-modal react-toastify react-router-dom
# npm install
# npm run build
echo "Downloading current webui release ..."
if [ -f webui.tar.gz ]; then
rm -f webui.tar.gz
fi
wget https://github.com/bondagit/aes67-linux-daemon/releases/latest/download/webui.tar.gz
tar -xzvf webui.tar.gz
if [ ! -f webui.tar.gz ]; then
echo "Building locally and installing webui ..."
npm install react-modal react-toastify react-router-dom
npm install
npm run build
fi
cd ..
cd daemon

View File

@ -23,6 +23,7 @@ rm -f demo/sink-test.wav
rm -rf webui/build
rm -rf webui/node_modules
rm -f webui/webui.tar.gz
rm -f webui/*.log
rm -f webui/package-lock.json