如何在 Jenkins 中通过参数查找构建?
How to find build by parameters in Jenkins?
Jenkins 中有很多构建,每个构建都有参数。我知道参数的值,需要用它找到所有构建。
从以下位置获取构建历史编号:
http://jenkins_url/job/project_name/api/json?tree=builds[number]
然后对于构建数组中的每个 "number",找到具有
的参数
http://jenkins_url/job/project_name/<number>/api/json?tree=actions[parameters[*]]
如果结果 JSON 包含你的参数,你就成功了
Jenkins 中有很多构建,每个构建都有参数。我知道参数的值,需要用它找到所有构建。
从以下位置获取构建历史编号:
http://jenkins_url/job/project_name/api/json?tree=builds[number]
然后对于构建数组中的每个 "number",找到具有
的参数http://jenkins_url/job/project_name/<number>/api/json?tree=actions[parameters[*]]
如果结果 JSON 包含你的参数,你就成功了