wrong handling of variables
This commit is contained in:
@@ -20,6 +20,6 @@ pokt_blockheight=$(curl -s -X POST -H "Content-Type: application/json" -m 2 -d '
|
||||
peers=$(curl -s -X POST -H "Content-Type: application/json" -m 2 -d '{"jsonrpc":"2.0","method":"net_peerCount","params": [],"id":1}' https://$HAPROXY_SERVER_NAME:$RPT/$HAPROXY_PROXY_NAME 2>/dev/null | jq '.result' -r)
|
||||
|
||||
# If any of the above tests failed, then exit 1.
|
||||
if [[ $our_blockheight -lt $($pokt_blockheight - 10) ]]; then exit 1; fi
|
||||
if [[ "$our_blockheight" -lt "$pokt_blockheight - 10" ]]; then exit 1; fi
|
||||
if [[ `printf "%d" $peers` == "0" || `printf "%d" $peers` == "1" ]]; then exit 1; fi
|
||||
exit 0
|
||||
Reference in New Issue
Block a user