mirror of https://github.com/status-im/consul.git
Update GH actions to create Jira issue automatically (#16656)
This commit is contained in:
parent
9c64731a56
commit
0b4dc2574e
|
@ -54,6 +54,26 @@ jobs:
|
|||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}
|
||||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
|
||||
|
||||
# Education Jira
|
||||
- name: Create ticket in Education board an issue is filed, or if PR not by a team member is opened
|
||||
if: github.event.action == 'opened' && ("${{ contains(github.event.issue.labels.*.name, 'type/docs') }}" == "true")
|
||||
uses: tomhjp/gh-action-jira-create@v0.2.0
|
||||
with:
|
||||
project: CE
|
||||
issuetype: "${{ steps.set-ticket-type.outputs.TYPE }}"
|
||||
summary: "${{ github.event.repository.name }} [${{ steps.set-ticket-type.outputs.TYPE }} #${{ github.event.issue.number }}]: ${{ github.event.issue.title }}"
|
||||
description: "${{ github.event.issue.body || github.event.pull_request.body }}\n\n_Created in GitHub by ${{ github.actor }}._"
|
||||
# customfield_10089 is "Issue Link", customfield_10371 is "Source" (use JIRA API to retrieve)
|
||||
extraFields: '{ "customfield_10089": "${{ github.event.issue.html_url || github.event.pull_request.html_url }}",
|
||||
"customfield_10371": { "value": "GitHub" },
|
||||
"customfield_10535": [{ "value": "Service Mesh" }],
|
||||
"components": [{ "name": "${{ github.event.repository.name }}" }],
|
||||
"labels": ${{ steps.set-ticket-labels.outputs.LABELS }} }'
|
||||
env:
|
||||
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }}
|
||||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}
|
||||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
|
||||
|
||||
- name: Search
|
||||
if: github.event.action != 'opened'
|
||||
id: search
|
||||
|
|
|
@ -72,6 +72,22 @@ jobs:
|
|||
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }}
|
||||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }}
|
||||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
|
||||
|
||||
# Education Jira
|
||||
- name: Create ticket in Education board an issue is filed, or if PR not by a team member is opened
|
||||
if: github.event.action == 'opened' && ("${{ contains(github.event.issue.labels.*.name, 'type/docs') }}" == "true")
|
||||
uses: tomhjp/gh-action-jira-create@v0.2.0
|
||||
with:
|
||||
project: CE
|
||||
issuetype: "${{ steps.set-ticket-type.outputs.TYPE }}"
|
||||
summary: "${{ github.event.repository.name }} [${{ steps.set-ticket-type.outputs.TYPE }} #${{ github.event.issue.number }}]: ${{ github.event.issue.title }}"
|
||||
description: "${{ github.event.issue.body || github.event.pull_request.body }}\n\n_Created in GitHub by ${{ github.actor }}._"
|
||||
# customfield_10089 is "Issue Link", customfield_10371 is "Source" (use JIRA API to retrieve)
|
||||
extraFields: '{ "customfield_10089": "${{ github.event.issue.html_url || github.event.pull_request.html_url }}",
|
||||
"customfield_10371": { "value": "GitHub" },
|
||||
"customfield_10535": [{ "value": "Service Mesh" }],
|
||||
"components": [{ "name": "${{ github.event.repository.name }}" }],
|
||||
"labels": ${{ steps.set-ticket-labels.outputs.LABELS }} }'
|
||||
|
||||
- name: Search
|
||||
if: github.event.action != 'opened'
|
||||
|
|
Loading…
Reference in New Issue