X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=server%2Frun.sh;h=d4e65104f06007d9d48b16d874752f80ac3555fd;hb=e2c333035c595ef6e48ff66d46a811ca17f97a26;hp=c2bd504f95067bf1df36d47c75566ba7dd18c43b;hpb=f858232d7c564f14e6d2fb9d616f8e12a1ec9171;p=matches%2FMCTX3420.git diff --git a/server/run.sh b/server/run.sh index c2bd504..d4e6510 100755 --- a/server/run.sh +++ b/server/run.sh @@ -1,15 +1,18 @@ #!/bin/bash -# Use this to quickly test run the server in valgrind -#spawn-fcgi -p9005 -n ./valgrind.sh -# Use this to run the server normally -#./stream & + +# Check existence of program +if [ ! -e "server" ]; then + (echo "Rebuild server.") 1>&2; + exit 1 +fi + if [[ "$(uname -m)" != *arm* ]]; then echo Not running on the BBB # Use this to quickly test run the server in valgrind spawn-fcgi -p9005 -n ./valgrind.sh # Use this to run the server normally - #./stream & + #spawn-fcgi -p9005 -n ./server exit 0 fi @@ -19,12 +22,6 @@ if [ "$(whoami)" != "root" ]; then exit 1 fi -# Check existence of program -if [ ! -e "server" ]; then - (echo "Rebuild server.") 1>&2; - exit 1 -fi - # Rotate the logs echo Rotating the system logs logrotate -f /etc/logrotate.d/mctxserv.conf