projects:bitbucket:pullrequestplugin
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
projects:bitbucket:pullrequestplugin [2016/04/17 23:28] – mkucia | projects:bitbucket:pullrequestplugin [2016/04/25 22:02] – [Notes] mkucia | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Bitbucket Server Pull Request Hook Plugin ====== | + | ====== Bitbucket Server |
- | * [[Atlassian Marketplace]] | + | |
- | * [[Sources]] | + | |
- | ===== TODOs ===== | + | {{ : |
+ | |||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | |||
+ | ===== Planned features | ||
* Internationalization | * Internationalization | ||
* Support for HTTPs | * Support for HTTPs | ||
- | * Test button in the config | ||
- | |||
===== Introduction ===== | ===== Introduction ===== | ||
The plugin provides the following functionality: | The plugin provides the following functionality: | ||
Line 18: | Line 19: | ||
* Per-repository configuration via ' | * Per-repository configuration via ' | ||
* Accessible by the repository administrators | * Accessible by the repository administrators | ||
+ | * The following HTTP operations are supported: | ||
+ | * POST | ||
+ | * GET | ||
+ | * PUT | ||
+ | * DELETE | ||
===== Usage ===== | ===== Usage ===== | ||
Line 26: | Line 32: | ||
'' | '' | ||
- | [IMAGE] | + | {{: |
==== Authorization ==== | ==== Authorization ==== | ||
Line 32: | Line 38: | ||
In such case the field will look like: | In such case the field will look like: | ||
- | [IMAGE] | + | {{: |
Please visit [[wp> | Please visit [[wp> | ||
Line 40: | Line 46: | ||
It allows using anonymous request + build token (think of API key). | It allows using anonymous request + build token (think of API key). | ||
- | ===== Example ===== | + | ===== Example |
- | We want to capture | + | - Create Jenkins job " |
- | | + | - Add String Parameter '' |
- | | + | - Add Token '' |
- | | + | - Check if the job is working |
+ | - Trigger job manually using your browser' | ||
+ | - Enter the (appropriate to your setup) URL '' | ||
+ | |||
+ | Entering URL will take you to an empty page. Back in Jenkins you should see that the job was triggered and parameter is successfully passed: | ||
+ | |||
+ | {{: | ||
+ | |||
+ | |||
+ | | ||
+ | - '' | ||
+ | - '' | ||
+ | - '' | ||
+ | - '' | ||
+ | | ||
+ | - Ensure that the plugin is installed. | ||
+ | - Enter any repository Settings, then Hooks | ||
+ | - Enable '' | ||
+ | - Enter URL '' | ||
+ | - Enable all triggers | ||
+ | - Save | ||
+ | |||
+ | {{: | ||
+ | {{: | ||
+ | {{: | ||
+ | |||
+ | | ||
+ | - Create pull request | ||
+ | - Add a comment | ||
+ | |||
+ | After that you should notice that a new builds were run. Inspect those builds parameters. | ||
+ | |||
+ | {{: | ||
+ | |||
+ | === Extras === | ||
+ | |||
+ | Jenkins job '' | ||
+ | <code xml> | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | <scm class=" | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | |||
+ | ===== Displaying Log ===== | ||
+ | There is a button in the configuration dialog that leads to a log. Communications are logged per-repository. | ||
+ | {{: | ||
+ | |||
+ | {{: | ||
+ | |||
+ | ===== Notes ===== | ||
+ | * Connection time-out is set to 5 seconds | ||
+ | ===== Test scenarios ===== | ||
- | Captured event will be propagated to [[https://jenkins.io/ | + | ==== Configuration ==== |
+ | * Entering incorrect URL | ||
+ | * https:\\123.com | ||
+ | * 45434.com | ||
+ | * http:\\ space .com | ||
+ | * Entering incorrect header data | ||
+ | * without colon | ||
+ | * empty lines | ||
- | There is only a single URL per repository therefore we will need a relay job to extract necessary | + | ==== Core ==== |
+ | * Enable all notification types and check them one-by one | ||
+ | * Set all possible | ||
+ | * Use basic-auth header | ||
- | 1. Configure Jenkins | + | ==== Weblog ==== |
- | * Add Token '' | + | * Accessing non-existing log |
- | * Add Parameters | + | * Accessing existing log by admin of other project |
+ | * Accessing log with non-configured plugin for given repository | ||
+ | * Accessing log when non-existing URL is set in config | ||
- | 2. Configure Bitbucket | ||
- | * Set URL '' |
projects/bitbucket/pullrequestplugin.txt · Last modified: 2016/04/25 22:08 by mkucia