-
Type:
Bug
-
Resolution: Incomplete
-
Priority:
Minor
-
Component/s: branch-api-plugin
-
Environment:Docker Image: Jenkins 2.54 - 2.69
Due to high demand of Jenkins runtime environments (used as cattle not treated as pets), we create a fully automated workflow where Jenkins is our build runtime.
Upon creating a new Jenkins instance we tweak the instance with some Groovy scripts that are executed at first runtime (located in /var/jenkins_home/init.groovy.d/) One of these scripts creates one or more 'GitHub Organization' jobs, based on input from the requestor.
The jobs get created correctly, as far as I can see.
The GitHub Organization(s) get scanned, and the repositories, and corresponding branches containing a Jenkinsfile, get created correctly.
The only issue is that the GitHub WebHook does not get created on the GitHub Organization, so there is no build triggered when someone triggers an event on GitHub, usually push some code, or create a PR. If we go to the Job choose "Configure" and click on the "Save" button, the creation of the WebHook gets triggered correctly.
Attached is the Groovy script that seeds the job template that creates the GitHub Organization job(s), along with the template script.