From the course: Running Jenkins on AWS: Deploying and Managing Jenkins on Cloud Infrastructure
Unlock this course with a free trial
Join today to access over 24,900 courses taught by industry experts.
Create and test a webhook with GitHub
From the course: Running Jenkins on AWS: Deploying and Managing Jenkins on Cloud Infrastructure
Create and test a webhook with GitHub
- [Instructor] To test our webhook, we need to have a repository where our code is stored, and a job that will be triggered when code is pushed to that repository. I have two tabs open, one with GitHub and the other with Jenkins. I've created a public repo with nothing more than a README file. I'll be updating the README file to trigger a job in Jenkins. Before I go to the Jenkins console, I need to get the repo's URL. I can get that by selecting the Code button, and then the HTTPS tab, and then the little clipboard here next to the URL. Okay, now let's go to the Jenkins tab and create a job. I'll start by selecting New Item. On the New Item screen, let's call this job webhook-test and select Freestyle project. I'll enter a brief description. Now, I'll scroll down to the Source Code Management section and select Git. In this section, I need to add the URL for the repo, so I'll paste it in here. This is a public repository, so we don't need to enter any credentials. I do need to update…