diff --git a/.install/loveland.sh b/.install/loveland.sh index f61b435..b374f3b 100755 --- a/.install/loveland.sh +++ b/.install/loveland.sh @@ -119,7 +119,9 @@ echo ' SSB DEMO HTTP interface ' | lolcat # IN CASE, KILL RUNNING OASIS -sudo kill -9 $(ps auxf --sort=+utime | grep -w oasis | grep -v -E 'color=auto|grep' | tail -n 1 | awk '{print $2}') +isOASIS=$(ps auxf --sort=+utime | grep -w oasis | grep -v -E 'color=auto|grep' | tail -n 1 | awk '{print $2}') +[[ $isOASIS ]] && sudo kill -9 $isOASIS + echo "Starting OASIS with good $NODENAME & network config" echo "TODO: add to your /etc/rc.local or systemd or initV !!!" @@ -241,4 +243,8 @@ oasis.astroport.com:8008::@UeiA9iqZ0/XTjmYBht230KGr44bsr+Tl5BXSUDFv8vo=.ed25519~ exit 0 fi +# Open LOVEland in browser +URL="http://$NODENAME:10010" +path=$(which xdg-open || which gnome-open) && $path $URL > /dev/null + } # for script being completely downloaded before run