Reputation: 315
Has anyone had experience supporting multiple Jira instances in Gerrit? Right now my current setup points to one Jira Instance, but we are in the process of migrating to a new Jira instance and will need to support both in one Gerrit Server.
Currently we have a commentlink configured in the gerrit.config
:
[commentlink "changeid"]
match = (I[0-9a-f]{8,40})
link = "#q,$1,n,z"
[commentlink "jira"]
match = ([a-zA-Z]+-\\d+):
link = https://jira.url.com/browse/$1
I was wondering if I needed to add a second. Also I have the jira hook plugin, wasn't sure if I needed an additional plugin. Thanks for the help!
Upvotes: 1
Views: 530
Reputation: 28951
So just hardcode the project names such as:
[commentlink "jira1"]
match = ((PRJA|PRJB|PRJC|PRJD)-\\d+):
link = https://jira1.url.com/browse/$1
[commentlink "jira2"]
match = ([a-zA-Z]+-\\d+):
link = https://jira2.url.com/browse/$1
Upvotes: 1