jq: parsed
after banging my head against it for long enough, the jq parse that i'm 100% convinced worked in test doesn't work, so I was able to work against that.
This commit is contained in:
parent
816bcff09d
commit
056cb4f2a3
@ -83,9 +83,10 @@ pipeline {
|
||||
while [ -z "\$strRes" ];
|
||||
do
|
||||
sleep 5;
|
||||
strRes=\$(curl -X GET -s -u ${env.JENKINS_USR}:'${env.JENKINS_PSW}' \
|
||||
alloces.lan:8080/job/gitea.arg.rip/api/json \
|
||||
| jq ".jobs.[] | select(.name==\"${env.servicename}\")")
|
||||
curl -X GET -s -u ${env.JENKINS_USR}:'${env.JENKINS_PSW}' \
|
||||
alloces.lan:8080/job/gitea.arg.rip/api/json > f.json
|
||||
strRes=\$(jq '.jobs' f.json | jq '.[] | select(.name==\"${env.servicename}\")')
|
||||
rm f.json
|
||||
done
|
||||
"""
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user