This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# name: Notify Jira | |
# on: | |
# workflow_call: | |
# inputs: | |
# title: | |
# description: 'Issue title' | |
# required: true | |
# type: string | |
# body: | |
# description: 'Body' | |
# required: true | |
# type: string | |
# html_url: | |
# description: 'URL' | |
# required: true | |
# type: string | |
# repo: | |
# description: 'Repository name' | |
# required: true | |
# type: string | |
# jobs: | |
# notify_jira: | |
# runs-on: ubuntu-latest | |
# env: | |
# JIRA_URL: "https://checkmarx.atlassian.net/" | |
# steps: | |
# - name: Jira Login | |
# uses: atlassian/gajira-login@v3 | |
# env: | |
# JIRA_BASE_URL: ${{ env.JIRA_URL }} | |
# JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }} | |
# JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }} | |
# - name: Jira Create issue | |
# id: create_jira_issue | |
# uses: atlassian/gajira-create@v3 | |
# with: | |
# project: AST | |
# issuetype: Bug | |
# summary: '${{inputs.repo}} ${{inputs.title}}' | |
# description: ${{inputs.body}} see more at ${{inputs.html_url}} | |
# fields: ${{ secrets.JIRA_FIELDS}} | |
# - name: Add comment to GitHub issue | |
# uses: actions/[email protected] | |
# with: | |
# script: | | |
# github.issues.createComment({ | |
# issue_number: context.issue.number, | |
# owner: context.repo.owner, | |
# repo: context.repo.repo, | |
# body: 'Internal Jira issue: [${{ steps.create_jira_issue.outputs.issue }}](${{ env.JIRA_URL }}/browse/${{ steps.create_jira_issue.outputs.issue }})' | |
# }) |