X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=shell%2Fjob-cost.sh;h=cb5f1a5977b3fd4dead49e07c153f04072d8a26e;hb=697cb58821b1738d527ff237b4c4502777908e4b;hp=a7dceea429956b2e997fd02fcc7636ed76f82697;hpb=3ca80e4b7818ebe309abc3ddcabe7086f1ed2d18;p=releng%2Fglobal-jjb.git diff --git a/shell/job-cost.sh b/shell/job-cost.sh index a7dceea4..cb5f1a59 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" > /dev/null 2>&1; then +if jq . <<< "$json_block" > /dev/null 2>&1; then cost=$(jq .cost <<< "$json_block") resource=$(jq .resource <<< "$json_block" | tr -d '"') else