GithubHelp home page GithubHelp logo

sdgdsffdsfff / stash-jenkins-postreceive-webhook Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mohamicorp/stash-jenkins-postreceive-webhook

0.0 1.0 0.0 1.78 MB

Webhook used to notify Jenkins when commits are made to Stash

License: Other

Java 95.88% JavaScript 4.12%

stash-jenkins-postreceive-webhook's Introduction

Stash Webhook for Jenkins

After making commits to Stash, notify Jenkins that a new build has been created.

Requirements

  • Git Plugin - Jenkins needs to have the Git Plugin installed in Jenkins and the Poll SCM option must be enabled

Setup

Once installed, follow these steps:

  • Navigate to a repository in Stash.
  • Hit the Settings link
  • In the left-navigation, hit the Hooks link
  • For the Stash Webhook to Jenkins, click the Enable button.
  • Enter the URL to your Jenkins instance
  • Select the method that clone method that Jenkins is using (HTTP or SSH).
  • If using HTTP, enter the username that Jenkins is using to clone your repository.
  • Submit the form.
  • Commit some code and watch it trigger a build!

Troubleshooting

  • Check your log file for any exceptions
  • Be sure you have polling turned on for your project in Jenkins (can use H 0 1 1 0 as an example)
  • Verify that the URLs for your repository match in Jenkins and the webhook settings. They MUST be identical.
  • Still stuck? Check out the this wiki page or open an issue

Rate the Plugin

If you found this plugin useful, please consider leaving us a rating on our Atlassian Marketplace listing. Thanks!

Donate to Development

If you've benefited from this open-source project, please take a moment and donate to its continued maintenance and development.

Forget buying me a beer (don't drink anyways)... they're going to pay off student loans, save up for a house, college funds, and who knows? maybe a toy or two.

Release Notes

Version 2.6.0

  • Added ability to not send commit hash in Jenkins notification
  • Reverted pull-request notifications back to where it was before

Version 2.5.1

  • Fixed a Javascript error when opening plugin settings
  • Added datacenter compatible flag

Version 2.5.0

  • Git Plugin version 2.0.2 or greater in Jenkins is highly recommended
  • No longer requires polling to be enabled for the git repository in Jenkins setup
  • Added more metadata in webhook notification to Jenkins, including the sha1
  • Allows "Trigger Build" button to trigger a build multiple times

Special shoutout to loa for his pull request, work, and patience

Version 2.4.2

  • Fixed syntax error in Javascript for the "Trigger Build" button (thanks dojcsak for the pull request)

Version 2.4.1

  • Stash 3.0 support

Version 2.4.0

  • Added ability to whitelist or blacklist specific branches for triggering of Jenkins. (whitelist = branch HAS to be in list to trigger; blacklist = branch is IGNORED if in the list)

Version 2.3.1

  • Move Jenkins event notification off to its own thread pool to prevent Stash's event thread from blocking (thanks charleso for the pull request)
  • Fixed compatibility issue with versions of Stash before 2.8 (thanks xuey90 for the pull request)

Version 2.3.0

  • Created more helpful error messages during testing of the webhook on the configuration screen.

Version 2.2.2

  • Fixed NPE that occurs when event has a null user. Was seen using the SVN Mirror plugin.

Version 2.2.1

  • Fixed bug in which notifications no longer were sent when pull request is merged

Version 2.2

  • Added button to Pull Request page to trigger a build. Note that Jenkins will still only build if there is an actual change to build.

Version 2.1

  • Trigger webhooks when pull requests are opened, reopened, or updated (thanks stupchiy for the research and lordmatanza for the pull request)

Version 2.0.1

  • Fixed bug in which non-admin users were unable to access webhook settings

Version 2.0

  • Made setup of the Jenkins repository easier by adding SSH/HTTP quick select
  • Fire notification after pull-requests have been merged
  • Added a plugin logo
  • Added test button to the Hook Configuration display
  • Added ability to not send notifications if commits/merges are made by specified Stash users
  • Requires Stash 2.3.0
  • Renamed plugin to Stash Webhook for Jenkins

Version 1.1

  • Added an option to "Skip SSL Certificate Validation", allowing for plugin to communicate with Jenkins instance using a self-signed cert (setting is on Hooks settings for each project)
  • Handle Jenkins urls with trailing slashes more gracefully (thanks ellingbo)

Version 1

  • Initial release

stash-jenkins-postreceive-webhook's People

Contributors

bbaetz avatar cmclaughlin avatar cszmajda avatar ellingbo avatar hendrikhalkow avatar loa avatar mikesir87 avatar stengerh avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.