Jenkins: trigger the same job from different BitBucket repositories

后端 未结 2 1552
误落风尘
误落风尘 2021-01-24 22:54

I have 50+ repositories in a BitBucket project and I want them to execute the same job when a commit is pushed (that is maven build and deploy to artifactory). I tried to create

2条回答
  •  醉酒成梦
    2021-01-24 23:56

    You can use Remote File Plugin for this. What you need to do is,

    • Create a separate repository and put your Jenkins file into it.
    • Define this repository and Jenkins file in the Remote File section of the BitBucket Team Project configuration page.

    This way, for every repository in your BitBucket, this Jenkins file will be run.

    Hope this helps.

    You can find the example screenshot below.

    You can find it under Project Recognizers

提交回复
热议问题