gpt4 book ai didi

git - Jenkins 管道作业不会在 GitHub 推送上触发

转载 作者:行者123 更新时间:2023-12-01 01:51:57 24 4
gpt4 key购买 nike

我已经创建了 Jenkins Pipline 作业,并希望在我的 GitHub 存储库推送事件上触发它。

我已将 repo url 添加到作业配置并选中“触发推送选项”:
enter image description here

我还添加了具有 jenkins 配置 Github 部分所需权限的 GitHub token :enter image description here

在 Github 存储库中,我为我的 Jenkins 服务器启用了 webhook:
enter image description here

在推送到我的 GitHub 存储库后,所有步骤仍然没有触发。

有谁知道发生了什么以及为什么 Jenkins 不触发配置的管道作业?

最佳答案

OP 在评论中提到的解决方案是正确的。

假设您的 Jenkins 有一个 Github webhook 设置正确且可访问(可以在 Github UI 中验证),您需要手动启动一次构建。构建完成后,存储库中的更改将自动启动新构建。

来自 user8888 的注释:

You actually need to manually start the build and the build must be successful. A failed build won't do anything.

关于git - Jenkins 管道作业不会在 GitHub 推送上触发,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43758656/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com