Kill the old blockexplorer harder
This commit is contained in:
parent
8d94972d88
commit
9917ece826
|
@ -271,8 +271,15 @@ EOF
|
|||
cat > ~/solana/restart-explorer <<EOF
|
||||
#!/bin/bash -ex
|
||||
cd ~/solana
|
||||
npm install @solana/blockexplorer@1
|
||||
|
||||
if [[ -f blockexplorer.pid ]]; then
|
||||
pgid=\$(ps opgid= \$(cat blockexplorer.pid) | tr -d '[:space:]')
|
||||
if [[ -n \$pgid ]]; then
|
||||
kill -- -\$pgid
|
||||
fi
|
||||
fi
|
||||
killall node || true
|
||||
npm install @solana/blockexplorer@1
|
||||
export BLOCKEXPLORER_GEOIP_WHITELIST=$PWD/net/config/geoip.yml
|
||||
npx solana-blockexplorer > blockexplorer.log 2>&1 &
|
||||
echo \$! > blockexplorer.pid
|
||||
|
|
Loading…
Reference in New Issue