Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

On the Datalog Tagging tab, check “GitHub project”, and put your project URL in the field.

Image Modified

On the Build Triggers tab, check “GitHub Pull Request Builder”. Then the GitHub API credentials is automatically filled in. Make sure the Admin list is filled in with at least one admin name. For my project, I put asfgit, which you can use as well for Apache projects. Check “Use github hooks for build triggering” below.

Image Modified

Next step is a crucial step: click the Advanced button to extend further options.

Image Modified

You can see Skip build phrase and Crontab line are automatically filled in. You can leave them as they are. You job here is to fill in the field “List of organizations. Their members will be whitelisted.” with apache. If you miss it, I am sure the PRs submitted by any Apache committer to your project will not kick-off the pipeline. It took me over 24 hours to find out this configuration, so take it.

Image Modified

On the Pipeline tab, set Definition to Pipeline script from SCM, and set SCM to Git. Under Repositories, set Repository URL to your Apache project. For OpenWhisk, it is git://github.com/apache/incubator-openwhisk.git. Set the Name to origin, and the Refspec to +refs/pull/${ghprbPullId}/*:refs/remotes/origin/pr/${ghprbPullId}/*. Under Branches to build, set the Branch Specifier to ${sha1}.

Image Modified

At last but not least, configure the Script Path to the Jenkinsfile. By default, this file is saved under the home directory of your Apache project, but you may put somewhere else, as long as you configure your script path pointing to it. After you click on the OK button, you are all set.

...