0
votes

I am facing problem with jenkins bitbucket notify build status plugin.

Problem statement: I am triggering a jenkins job from Developers Application development branch through bitbucket pipeline. I am using bitbucket notify build status plugin, after the execution is completed. But the notifier is updating the last commit id of automation branch where we have all the automation scripts. Instead of updating it to the development branch commit id from where the job was triggered.

Can anyone help me with updating the status for right commit id on development branch?

1

1 Answers

0
votes

Looks like you are encountering an issue similar to what has been reported here - Jenkins sending notifications to the wrong commit id

To resolve the issue, specify the commitId and repoSlug as below:

bitbucketStatusNotify(
    buildState: '<INPROGRESS> OR <SUCCESSFUL> OR <FAILED>',
    repoSlug: '<your_repo_slug>',
    commitId: '<commit_id>'      
)

Note that the repoSlug and commitId parameters work only when they are both specified