【发布时间】:2021-09-11 17:20:57
【问题描述】:
我计划获取所有节点的主厨自动化报告(包括节点描述、配置文件、通过/失败控制)。
到目前为止,根据链接https://docs.chef.io/automate/api/#operation/ReportingService_ListReports 使用自动化 api 获得了单个节点的报告。
代码是
- 使用服务器 fqdn 检索单个节点的报告 ID。
curl -s --insecure -H "api-token: XXXXXXXXXXXXXXX" https://automate.com/api/v0/compliance/reporting/reports -d '{ "过滤器": [{"type":"node_name","values":["test.com"]}]}'
- 使用上述 ID,提取单个节点的合规性报告。
curl -s --insecure -H "api-token: XXXXXXXXXXXXXXXXXXXXXXXX" https://automate.com/api/v0/compliance/reporting/reports/id/YYYYYYXXXXXXXXUUUUUUU -d {}
您能否建议有关提取所有节点而不是单个节点的合规性报告的 api。
【问题讨论】:
标签: api automation chef-infra devops azure-devops-rest-api