[Jenkins] GitHub Webhook 설정 시 "Polling has not run yet" 메시지
Jenkins에 Webhook을 설정하여, GitHub Repository에 푸시가 발생했을 때 자동으로 빌드 및 배포를 실행하려 했다.
여러 설정을 마치고 해당 GitHub Repository의 Settings > Webhooks > Recent Deliveries 를 확인해보니
push 후 Jenkins 서버로 요청을 보냈고 200 status code를 받은 것을 알 수 있었다.
하지만 Jenkins의 해당 프로젝트 GitHub Hook Log를 보니 "Polling has not run yet" 라는 메시지가 떴다.
즉, GitHub Repository에서는 요청을 보냈으나 Webhook이 일어나지 않은 것이다.
사람들마다 여러 이유가 있겠지만 나의 경우에는 GitHub Repository의 Settings > Webhooks 에서
Payload URL을 "{Jenkins URL}/"로 설정한 것이 문제였다.
"{Jenkins URL}/github-webhook/"로 설정한 후에는 Webhook이 제대로 실행됐다.
참고:
stackoverflow.com/questions/56714213/jenkins-not-triggered-by-github-webhook
Jenkins not triggered by github-webhook
I have taken these steps: Check "GitHub project" and set up the project Check "GitHub hook trigger for GITScm polling" Setup connection to private repository with user/password If I build manually...
stackoverflow.com