【发布时间】:2021-10-01 21:58:31
【问题描述】:
我们正在使用 AZ CLI GitHub Action azure/CLI (https://github.com/marketplace/actions/azure-cli-action)
此工作流调用的脚本向外部 API 发出 HTTP 请求。此 cURL 调用失败并显示以下内容:
curl: (60) SSL certificate problem: certificate has expired
More details here: curl.haxx.se/docs/sslcerts.html
curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.
但是我可以确认相同的请求在本地有效。
问题工作流程步骤如下所示:
- name: Run script
uses: azure/CLI@1.0.4
with:
azcliversion: 2.0.72
inlineScript: |
$GITHUB_WORKSPACE/github/scripts/script.sh
当我可以在我自己的机器上成功地对同一个 API 域进行相同的调用时,为什么 cURL 认为外部 API 域的 SSL 证书已过期?
【问题讨论】: