bitbucket-push-and-pull-request-plugin icon indicating copy to clipboard operation
bitbucket-push-and-pull-request-plugin copied to clipboard

Trigger only for specified repo if several repos are in jenkins job

Open malcolm061990 opened this issue 5 years ago • 6 comments

Hi. I use 2.4 version of that plugin on Jenkins ver. 2.204.1. I have job in jenkins with two git repos: backend and infra. Each of this two repos is configured for the same branch name to build - develop. It means that build is triggered when I push to infra repo in develop branch OR in backend repo in develop branch. This is unwanted behavior. What I want? I want to configure builds to be triggered only for pushes to infra repo in develop branch, but not to backend. I tested (as it is written in plugin's help) "Allowed Branches" field with "remotes/infra/develop" or "infra/develop" values. But it doesn't trigger the build when I push to develop in infra :( Please, help.

malcolm061990 avatar Oct 01 '20 07:10 malcolm061990

Is anyone here?

malcolm061990 avatar Jan 03 '21 16:01 malcolm061990

@malcolm061990 You should create a job for each repositories and write in the Allowed Branches filter field only the value 'develop', just to be sure that all is working.

cdelmonte-zg avatar Jan 07 '21 10:01 cdelmonte-zg

@malcolm061990 You should create a job for each repositories and write in the Allowed Branches filter field only the value 'develop', just to be sure that all is working.

I did that before and it worked. So, I am sure all is working using your advice.

malcolm061990 avatar Jan 07 '21 10:01 malcolm061990

@malcolm061990 Maybe is this issue history helpful? Issue: https://github.com/jenkinsci/bitbucket-push-and-pull-request-plugin/issues/100

cdelmonte-zg avatar Jan 07 '21 13:01 cdelmonte-zg

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Apr 16 '22 12:04 stale[bot]

Hi @malcolm061990 Do you mean you need the two repositories for the job to run properly? Otherwise one should follow the advice mentioned before.

julioc-p avatar Sep 27 '24 07:09 julioc-p