I recently moved some repositories from a deprecated Bitbucket Server installation to Bitbucket cloud.
In my repository I'd like to trigger different Jenkins build jobs for different repo branches.
For example, a push to the `develop` branch should trigger a Jenkins job to build the project on my staging site while a push to the `master` branch should trigger a separate Jenkins job to build the project on my production site. I don't see options for that kind of differentiation in the webhook settings.
On Bitbucket Server I was able to specify branches on the Bitbucket side (via a Bitbutcket/Jenkins integration plugin, I believe) to send requests to different Jenkins jobs based on the specified branch(es). The examples & tutorials I've seen for a Bitbucket Cloud/Jenkins setup only seem to connect up via the Jenkins server URL. Who knows which job it will trigger when the request hits Jenkins?
Can I use webhooks to accomplish this?
Can pipelines accomplish this?
What is the recommended approach for this sort of workflow?
Hi @suchpower
Can you tell me which Bitbucket/Jenkins integrations plugin you're using? I'm the Product Marketing Manager for Appfire's Webhook to Jenkins for Bitbucket Cloud.
Best,
Jennifer
Let's see...in the Jenkins plugin manager I see "Bitbucket Plugin" and "Bitbucket Push and Pull Request Plugin" installed. I inherited this Jenkins installation so I'm guessing I may not need both of those.
The Webhook to Jenkins for Bitbucket Cloud looks like exactly what I need! Where in Bitbucket Cloud do I add/manage integrations?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @suchpower
Great! I'm happy we have a solution for you. I'm going to reach out to a member of our Support team to help you with your question regarding adding/managing your integrations. They'll be happy to walk you through the set up process. Someone will reach out to you soon.
Best,
Jennifer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @suchpower
Hope you are doing well,
We have created a support request SUPPORT-96982 However, we couldn't add you as a reporter.
Please sign up using this link sign up and share with us the user name or id.
We will then add you as the reporter and confirm.
As per my understanding, you would like to integrate jenkins with Bitbucket. For this after installing the WJB Cloud app. In the repository setting tab, you have the CONFIGURING WEBHOOKS TO JENKINS option to add/integrate the Jenkins instance as below.
Thanks,
Naveen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.