Skip to content

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub Action for Telemetry

Name: cloudposse/github-action-telemetry

This GitHub Action will scrape the event for JIRA tickets and an assortment of relevant metadata and post it to a webhook endpoint

Usage instructions

Create a workflow file (e.g. .github/workflows/github-telemetry.yml) that contains a step that uses: cloudposse/github-action-telemetry@v1.0.0. Here's an example workflow file:

name: GitHub Telemetry
on: pull_request
    types: [opened]
jobs:
  telemetry:
    runs-on: ubuntu-latest
    steps:
    - uses: cloudposse/github-action-telemetry@v1.0.0
      with:
        collector_endpoint: "https://awesome-endpoint.net"
        collector_token: ${{ secrets.token }}
        jira_keys: "DEV,OPS,SECOPS,IT"

Inputs

  • collector_endpoint: This is the HTTP(S) address of a webhook that is expecting POST payloads that conform to the specifications in the next section.
  • collector_token: This is an optional token the will be passed in a token= header attached to the HTTP POST payload sent to the collector_endpoint.
  • jira_keys: This is a comma-separated, (space-free) list of JIRA codes to look for in the GitHub event JSON. For example, if jira_keys: "INTERNAL", then cloudposse/github-action-telemetry will extract all strings matching the regular expression \bINTERNAL-\d+ from the GitHub event JSON.

Payload Specification

{
  repo_org: // e.g. cloudposse
  repo_name: // e.g. infra
  repo_url: // full URL to repo
  event_type: // github event type
  jira_tickets: [] // extracted from event payload
  pull_request { // if the event is a pull_request
    created_at:
    number:
    url:
    title:
    author:
    description:
  }
}

Use-case

This event could facilitate automatic annotation of JIRA tickets based on the contents of GitHub pull requests, to improve task tracking between these two platforms when using the native Jira GitHub interaction is not an option.

About

GitHub Action for telemetry harvesting from repos

Resources

Code of conduct

Contributing

Security policy

Stars

2 stars

Watchers

0 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages