简体   繁体   English

Jenkins 多分支管道 - 创建 PullRequest 时不会从 Bitbucket 触发扫描

[英]Jenkins Multibranch Pipeline - scan is not triggered from Bitbucket when a PullRequest is created

We have configured Jenkins multibranch pipelines to automatically build feature branches that are filed as Pull request in Bitbucket.我们已经配置了 Jenkins 多分支管道来自动构建功能分支,这些分支在 Bitbucket 中作为拉取请求提交。 For the Webhook creatin in Bitbucket(Server), we use Parametrized Builds for Jenkins.对于 Bitbucket(Server) 中的 Webhook creatin,我们使用 Jenkins 的参数化构建。 In Jenkins we have successfully configured this, the buildable branches are detected like a charm.在 Jenkins 中,我们已经成功配置了这个,可构建的分支像魅力一样被检测到。

The thing is that I have to tell Jenkins to check for new branches every 2 Minutes, I'd rather have Jenkins notified when a PR is created,merged or changed.问题是我必须告诉 Jenkins 每 2 分钟检查一次新分支,我宁愿在创建、合并或更改 PR 时通知 Jenkins。 All other notifications from Bitbucket work pretty well, changes in a multibranch build lead to an automatic build, normal builds on none multibranch pipelines also work.来自 Bitbucket 的所有其他通知都运行良好,多分支构建中的更改导致自动构建,非多分支管道上的正常构建也有效。

Does sombody know why the scan cannot be triggered from Bitbucket?有人知道为什么不能从 Bitbucket 触发扫描吗? I can provide Screenshots of my configuration if someone needs that... Thanks Carsten如果有人需要,我可以提供我的配置截图...谢谢 Carsten

You'd need to add a corresponding Webhook to each repository in Bitbucket to have builds being triggered on specific actions.您需要将相应的 Webhook 添加到 Bitbucket 中的每个存储库,以便在特定操作上触发构建。 We are using an extra add-on in Bitbucket ( https://marketplace.atlassian.com/apps/1215474/post-webhooks-for-bitbucket?hosting=server&tab=overview ) but you could even use the default Webhook implementation in Bitbucket (described here https://confluence.atlassian.com/bitbucketserver/managing-webhooks-in-bitbucket-server-938025878.html )我们在 Bitbucket( https://marketplace.atlassian.com/apps/1215474/post-webhooks-for-bitbucket?hosting=server&tab=overview )中使用了一个额外的附加组件,但您甚至可以在 Z39EC4B66BBCED386DF823ZEFEC4B60BBCED386DF823ZEFEC4B60BBCED386DF823ZEF3B60 (此处描述https://confluence.atlassian.com/bitbucketserver/managing-webhooks-in-bitbucket-server-938025878.html

The endpoint in Jenkins is defined by the Multibranch plugin. Jenkins 中的端点由 Multibranch 插件定义。 It is this one: "YOUR_JENKINS_URL/bitbucket-scmsource-hook/notify"就是这个:“YOUR_JENKINS_URL/bitbucket-scmsource-hook/notify”

See https://support.cloudbees.com/hc/en-us/articles/115000053051-How-to-Trigger-Multibranch-Jobs-from-BitBucket-Server- for a good guide.有关好的指南,请参阅https://support.cloudbees.com/hc/en-us/articles/115000053051-How-to-Trigger-Multibranch-Jobs-from-BitBucket-Server-

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 从另一个作业触发Jenkins多分支管道扫描 - Trigger Jenkins Multibranch Pipeline Scan from another job Jenkins 多分支管道扫描而不执行 - Jenkins multibranch pipeline Scan without execution 在 Jenkins 多分支管道上扫描存储库后未触发作业构建(检测到更改) - Job build not triggered after repository scan on Jenkins Multibranch Pipeline (changes detected) 在GitHub中创建拉取请求时触发Jenkins Multibranch管道 - Triggering Jenkins Multibranch pipeline when there is a pull request created in GitHub Jenkins 来自版本控制 (Bitbucket) 的多分支管道 - 我可以为特定分支指定规则吗? - Jenkins Multibranch Pipeline from Version Control (Bitbucket) - can I specify rules for specific branches? Jenkins 从另一个多分支管道构建多分支管道 - Jenkins build multibranch pipeline from another multibranch pipeline 生成SNAPSHOT时不会触发Jenkins Multibranch项目 - Jenkins Multibranch project are not triggered when a SNAPSHOT is built 在 Jenkins 中使用 pollSCM 和 Scan Multibranch Pipeline Triggers 有什么区别? - What is the difference between using the pollSCM and the Scan Multibranch Pipeline Triggers in Jenkins? Jenkins Scan Multibranch Pipeline停止检测开发分支 - Jenkins Scan Multibranch Pipeline stopped detecting develop branch Jenkins 多分支管道未检测到 Bitbucket 服务器中的拉取请求 - Jenkins multibranch pipeline does not detect pull requests in Bitbucket server
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM