duke
1 year ago
1 changed files with 26 additions and 0 deletions
@ -0,0 +1,26 @@ |
|||||
|
#!/bin/bash |
||||
|
# Stops and restarts hushd to avoid stupid bugs |
||||
|
|
||||
|
# if hushd is not running, start it |
||||
|
#set -e |
||||
|
|
||||
|
DIR="$HOME/git/hush3/src" |
||||
|
CLI="$DIR/hush-cli" |
||||
|
HUSHD="$DIR/hushd" |
||||
|
|
||||
|
echo "Stopping hushd if it is running..." |
||||
|
$CLI stop |
||||
|
|
||||
|
# TODO: look for lockfile |
||||
|
# testing |
||||
|
#sleep 5 |
||||
|
|
||||
|
# prod |
||||
|
sleep 30 |
||||
|
|
||||
|
# save some logs for now to debug |
||||
|
cp $DIR/hush.log $DIR/hush.log.prev-$$ |
||||
|
|
||||
|
# restart hushd |
||||
|
cd $DIR |
||||
|
$HUSHD &> hush.log & |
Loading…
Reference in new issue