X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Fjob-cost.sh;h=769b972a113cb1ee7ea784d378070a3a2f5e46d9;hb=refs%2Fchanges%2F35%2F63035%2F1;hp=34ab5e730e5c77cd92e0fcc258c80726be4a91b5;hpb=72050cce2c57e8eb314b2f518b846f7810595fbb;p=releng%2Fglobal-jjb.git diff --git a/shell/job-cost.sh b/shell/job-cost.sh index 34ab5e73..769b972a 100644 --- a/shell/job-cost.sh +++ b/shell/job-cost.sh @@ -59,7 +59,7 @@ url="https://pricing.vexxhost.net/v1/pricing/$instance_type/cost?seconds=$uptime json_block=$(curl -s "$url") # check if JSON returned and can be parsed -if jq <<< "$json_block"; then +if jq <<< "$json_block" > /dev/null 2>&1; then cost=$(jq .cost <<< "$json_block") resource=$(jq .resource <<< "$json_block" | tr -d '"') else