Skip to content

bmdevel/gitlab-web-hooks

 
 

Repository files navigation

Gitlab Web Hooks Build Status

Small Sinatra app for providing Web hooks for Gitlab

Reviewboard Web Hook

With this Web hook it is possible to transfer Merge Request changes in Gitlab to a Reviewboard instance. The configuration is done in the .env file. To use the the Web Hook simply run rackup and add the server address as a Web hook for incoming Merge Request events in Gitlab.

How it works:

  • the hook only transfers the changes when the Merge Request has a certain label (default = reviewboard)
  • on the first transfer it creates a Review Request on the Reviewboard and writes a Merge Request comment with the ID (e.g. REVIEW_ID: 234)
  • for every MR change it uploads a new Diff to Reviewboard and adds a MR comment with the link (e.g. http://localhost:8000/r/234/diff/2-3/)
  • it uses the owner of the MR as the submitter of the Review Request, so make sure that:
    • the REVIEWBOARD_USER has the "Can submit as user" permission
    • users in Gitlab and Reviewboard have the same names
    • when using LDAP the user with the GITLAB_PRIVATE_TOKEN has the Admin role (to be able to fetch LDAP user names)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%