Skip to content

New jira integration #10

New jira integration

New jira integration #10

name: Sync issues to jira
on:
issues:
types: [labeled]
jobs:
create-task:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Create Jira Issue
env:
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }}
JIRA_BASE_URL: "https://droidsonroids.atlassian.net"
run: |
ISSUE_TITLE="${{ github.event.issue.title }}"
ISSUE_BODY="${{ github.event.issue.body }}"
curl -X POST \
-u "${JIRA_AUTH_EMAIL}:${JIRA_API_TOKEN}" \
-H "Content-Type: application/json" \
-d '{
"fields": {
"project": {
"key": "FT"
},
"summary": "$ISSUE_TITLE",
"description": "$ISSUE_BODY",
"name": "Task"
}
}
}' \
$JIRA_BASE_URL/rest/api/2/issue/