The GitHub plugin for Jenkins is the most basic plugin for integrating Jenkins with GitHub projects. If you are a GitHub user, this plugin enables you to schedule your build, pull your code and data files from your GitHub repository to your Jenkins machine, and automatically trigger each build on the Jenkins server after each Commit on your Git repository.
This saves you time and lets you incorporate your project into the Continuous Integration (CI) process.
How to Start Working with the GitHub Plugin for Jenkins
Before you begin, Install the Github Jenkins plugin and configure it. Then...
1. Go to Manage Jenkins > Configure System.
1a. In the GitHub section, choose Add Github Server.
1b. Add credentials (your GitHub token) and click Save.
2. Open your Jenkins Project.
2a. Check the GitHub project checkbox and set the Project URL to point to your GitHub Repository.
2b. Under Source Code Management, check Git and set the Repository URL to point to your GitHub Repository.
2c. Under Build Triggers, check the Build when a change is pushed to GitHub checkbox.
3. Install the Jenkins (GitHub plugin) and set a webhook to your Jenkins machine.
3a. From your GitHub repository, go to Settings > Integrations & Services.
3b. Click on Add Service > add Jenkins (GitHub plugin).
3c. Set the Jenkins hook URL as the URL for your Jenkins machine, and add /github-webhook/.
Congratulations! Every time you publish your changes to GitHub, GitHub will trigger your new Jenkins job.
Once the GitHub plugin is fully installed and integrated into your Jenkins project, you have completed a very crucial step towards the full CI process. Now, you can proceed to the testing phase. To complete the full CI process, integrate your load testing into your CI tool. For more details about how to do this with Taurus, an open source automation tool, see here.
You might also find these useful: