(git@localhost:test/sample.gitを連携させる例)
1.GitLabのプロジェクトのメンバーにredmineユーザーをReporterとして追加 (GitLab上にredmineユーザーは作成済み)
2.ミラーリポジトリを作成
$ cd /home/redmine/git_repositories
$ sudo -u redmine git clone --mirror git@localhost:test/sample.git
3.Redmineのプロジェクト設定のリポジトリに登録(ローカルパスを指定)
リポジトリ:/home/redmine/git_repositories/sample.git/
4.GitLab上のWebHooksに登録し、commitのタイミングでミラーリポジトリを更新させる。
http://localhost:3000/github_hook?project_id=sample-project
(git@localhost:test/sample.gitを連携させる例)
1.GitLabのプロジェクトのメンバーにjenkinsユーザーをReporterとして追加 (GitLab上にjenkinsユーザーは作成済み)
2.新ジョブ登録
- ソースコード管理:Git
- Repository URL:git@localhost:test/sample.git
- ビルド・トリガ:SCMをポーリング
3.GitLab上のWebHooksに登録し、commitのタイミングでジョブ実行させる。
http://localhost:8080/git/notifyCommit?url=git@localhost:test/sample.git