Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Bitbucket cloud webhooks for create pull request doest not trigger Jenkins pipeline build

Shweta Thakur
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 12, 2017

We have a requirement to trigger a Jenkins Pipeline build when a pull request is created.

Below are the configurations that we have for Bitbucket :

1: Added a webhook with URL with active state

http://<jenkinshost>:<jenkinsport>/bitbucket-scmsource-hook/notify

2: Selected radio button Choose from a full list of triggers

3: Selected Pull Request event, Pull Request Created

On the Jenkins side we have below configurations:

1: Poll SCM set to true with a longer interval

2: Discover Branches Strategy: "All Branches"

3: Bitbucket Enpoints > Bitbucket Cloud > Manage Hooks set to checked

Logs on Jenkins server: 

com.cloudbees.jenkins.plugins.bitbucket.hooks.BitbucketSCMSourcePushHookReceiver
X-Bitbucket-Type header not found. Bitbucket Cloud webhook incoming.

Finished processing com.cloudbees.jenkins.plugins.bitbucket.hooks.PullRequestHookProcessor$1 CREATED event from  ⇒ http://<JenkinsHost>:<jenkinsport>/bitbucket-scmsource-hook/notify with timestamp  Matched 0.

It seems it is not able to detect the changes as it always says Matched 0.

If we change the trigger from Pull request created to Repo push everything seems to work fine, only Pull request created does not work

Are we missing any specific setting on Bitbucket or Jenkins side? 

 

 

 

3 answers

2 votes
Muddassir Farooq February 22, 2018

Please use the https://wiki.jenkins.io/display/JENKINS/Generic+Webhook+Trigger+Plugin . It will trigger the build when PR created and Updated. It also hold all the payload from bitbucket webhook.

0 votes
Anirudh Menon
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 8, 2019

Any updates on this one? I am using Jenkins v2.153. Is there a work around?

0 votes
Muddassir Farooq February 21, 2018

any reply on this.

I m also facing the same.

Abhisek Tripathy September 14, 2018

M also facing the same.for a multibranch pipeline job.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events