githubにpushされたら自動でビルドする
- github側の設定
1. Settings > Service hooks > Jenkins(git plugin)
2. Jenkins Urlを設定
http://{JenkinsのURL}/git/notifyCommit?url={gitリポジトリのURL}
例:http://example.jenkins/git/notifyCommit?url=git@github.com:example/example.git
- Jenkins側の設定
1. 設定 > ビルド・トリガ > SCMをポーリング
チェックを入れ、スケジュールを設定する
- 確認
githubの設定でActiveにチェックを入れ、pushした時にJenkinsの「Gitのポーリングログ」が動いていることを確認