Migrate integrations/jira-plugin.html to markdown.

This commit is contained in:
Aditya Bansal
2017-06-05 20:57:59 +05:30
committed by Tim Abbott
parent 6b86de3a3c
commit 6fec949678
3 changed files with 73 additions and 64 deletions

View File

@@ -1,63 +0,0 @@
<p>
<em>If you are running JIRA version 5.2 or greater, or using the
hosted JIRA provided by Atlassian, we recommend using the
<a href="#jira">web-hook method</a> above instead. This plugin
supports older versions of JIRA.</em>
</p>
<p>
First, create the stream you'd like to use for JIRA notifications, and
subscribe all interested parties to this stream. We recommend the
name <code>jira</code>.
</p>
<h5>Plugin mechanism</h5>
Next, download and install our <a href="/api">Python bindings and example scripts</a>.
<p><b>Plugin Installation</b></p>
The JIRA integration plugin requires two JIRA plugins. Please install
the following plugins using the Universal Plugin Manager in your JIRA
installation:
<ul>
<li><a href="https://marketplace.atlassian.com/plugins/com.onresolve.jira.groovy.groovyrunner">Script Runner
Plugin</a></li>
<li><a href="https://marketplace.atlassian.com/plugins/com.atlassian.jira.plugin.jirasslplugin">SSL Plugin</a>
</li>
</ul>
<p><b>SSL Setup</b></p>
As Zulip is using a StartCOM SSL certificate that is not recognized by default in the Java installation shipped with
JIRA,
you will need to tell JIRA about the certificate. Navigate to <code>Administration > System > Configure SSL</code>
and in
the <code>Import SSL Certificates</code> field, enter <code>{{ external_api_uri_subdomain }}</code>. After clicking
<code>Save Certificates</code>,
follow the on-screen instructions and restart JIRA for it to recognize the proper certificates.
<p><b>Zulip Integration</b></p>
Copy the folder <code>integrations/jira/org/</code> (from the tarball you downloaded above) to your JIRA
<code>classes</code>
folder.
For self-contained JIRA installations, this will be <code>atlassian-jira/WEB-INF/classes/</code>, but this may be
different in your deployment.
Edit the constants at the top of <code>org/zulip/jira/ZulipListener.groovy</code>
and fill them with the appropriate values:
<div class="codehilite"><pre><span class="n">String</span> <span class="n">zulipEmail</span> <span
class="o">=</span> <span class="s2">"jira-notifications-bot@example.com"</span>
<span class="n">String</span> <span class="n">zulipAPIKey</span> <span class="o">=</span> <span class="s2">"0123456789abcdef0123456789abcdef"</span>
<span class="n">String</span> <span class="n">zulipStream</span> <span class="o">=</span> <span class="s2">"JIRA"</span>
<span class="n">String</span> <span class="n">issueBaseUrl</span> <span class="o">=</span> <span class="s2">"https://jira.COMPANY.com/browse/"</span>
</pre>
</div>
<p>
In the Administrators page, navigate to <code>Plugins > Other > Script Listeners</code>. In the
<code>Add Listener</code> section, click on
the <code>Custom Listener</code> option. Select the events you wish the Zulip integration to fire for, and the
projects you wish Zulip to be notified for.
In the <code>Name of groovy class</code> field, enter <code>org.zulip.jira.ZulipListener</code>.
</p>
<p>Click <code>Add Listener</code>, and JIRA will now notify your Zulip of changes to your issues!</p>
<p>
<b>Congratulations! You're done!</b><br/>
Updates from JIRA will be sent to the stream you've configured, as below.
</p>
<img class="screenshot" src="/static/images/integrations/jira/001.png"/>

View File

@@ -0,0 +1,72 @@
_If you are running JIRA version 5.2 or greater, or using the hosted
JIRA provided by Atlassian, we recommend using the
[web-hook method](#jira) above instead. This plugin supports older
versions of JIRA._
First, create the stream you'd like to use for JIRA notifications, and
subscribe all interested parties to this stream. We recommend the name
`jira`.
##### Plugin mechanism
{! download-python-bindings.md !}
**Plugin Installation**
The JIRA integration plugin requires two JIRA plugins. Please install
the following plugins using the Universal Plugin Manager in your JIRA
installation:
* [Script Runner Plugin][script-runner]
* [SSL Plugin][ssl-plugin]
[script-runner]: https://marketplace.atlassian.com/plugins/com.onresolve.jira.groovy.groovyrunner
[ssl-plugin]: https://marketplace.atlassian.com/plugins/com.atlassian.jira.plugin.jirasslplugin
**SSL Setup**
As Zulip is using a StartCOM SSL certificate that is not recognized by
default in the Java installation shipped with JIRA, you will need to
tell JIRA about the certificate.
1. Navigate to `Administration > System > Configure SSL` and in the
`Import SSL Certificates` field, enter `{{ external_api_uri_subdomain }}`.
2. After clicking `Save Certificates`, follow the on-screen
instructions and restart JIRA for it to recognize the proper
certificates.
**Zulip Integration**
1. Copy the folder `integrations/jira/org/` (from the tarball you
downloaded above) to your JIRA `classes` folder. For self-contained
JIRA installations, this will be `atlassian-jira/WEB-INF/classes/`,
but this may be different in your deployment.
2. Edit the constants at the top of
`org/zulip/jira/ZulipListener.groovy` and fill them with the
appropriate values:
```Python
String zulipEmail = "jira-notifications-bot@example.com"
String zulipAPIKey = "0123456789abcdef0123456789abcdef"
String zulipStream = "JIRA"
String issueBaseUrl = "https://jira.COMPANY.com/browse/"
```
3. In the Administrators page, navigate to `Plugins > Other > Script Listeners`.
4. In the `Add Listener` section, click on the `Custom Listener`
option. Select the events you wish the Zulip integration to fire for,
and the projects you wish Zulip to be notified for.
5. In the `Name of groovy class` field, enter
`org.zulip.jira.ZulipListener`.
6. Click `Add Listener`, and JIRA will now notify your Zulip of
changes to your issues! Updates from JIRA will be sent to the stream
you've configured.
{! congrats.md !}
![](/static/images/integrations/jira/001.png)

View File

@@ -238,7 +238,7 @@ INTEGRATIONS = {
logo='static/images/integrations/logos/jira.svg', logo='static/images/integrations/logos/jira.svg',
secondary_line_text='(locally installed)', secondary_line_text='(locally installed)',
display_name='JIRA', display_name='JIRA',
doc='zerver/integrations/jira-plugin.html' doc='zerver/integrations/jira-plugin.md'
), ),
'mercurial': Integration( 'mercurial': Integration(
'mercurial', 'mercurial',