Skip to content

Commit

Permalink
ci: SxT Jira and Github Integration (#271)
Browse files Browse the repository at this point in the history
-This workflow was requested by Jay to push Issues labeled as "bugs" to
Jira

-It will push issues that are labeled as bugs to the PSPI ticket queue
under the Epic PSPI-7. It does this by triggering the workflow located
in Jira_GitHub_Integration repo.

-This is to track bounty program related issues in Jira and have the
ability to close the Issue in GitHub by closing the ticket in Jira

-This has been tested on the repo Proof-of-SQL-Bounty (POC)

Simone Haddad
SxT Engineer
  • Loading branch information
SxTSimoneHaddad authored Oct 22, 2024
2 parents a158ba8 + afe4f22 commit d66c3f9
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/bountyissuestojira.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Origin Repository Workflow

on:
issues:
types: [opened, labeled]

jobs:
cross-repo-pipeline:
if: contains(github.event.issue.labels.*.name, 'bug')
runs-on: ubuntu-latest
steps:
- name: Trigger Target Repository
run: |
curl -X POST \
-H "Authorization: token ${{ secrets.PAT_TOKEN }}" \
-H "Accept: application/vnd.github.everest-preview+json" \
https://api.github.com/repos/spaceandtimelabs/jira-github-integration/dispatches \
-d '{
"event_type": "repository_dispatch",
"client_payload": {
"issue_title": "${{ github.event.issue.title }}",
"issue_body": "${{ github.event.issue.body }}",
"issue_url": "${{ github.event.issue.html_url }}",
"issue_number": "${{ github.event.issue.number }}",
"issue_labels": ${{ toJson(github.event.issue.labels.*.name) }}
}
}'

0 comments on commit d66c3f9

Please sign in to comment.