liatrio / liatrio-otel-collector

The Liatrio distribution of the OpenTelemetry Collector
https://openo11y.dev
Apache License 2.0
38 stars 4 forks source link

Add GHAS security vulnerability counts to Git Provider Receiver #368

Closed adrielp closed 6 months ago

adrielp commented 6 months ago

Overview

Add a metric for number of GHAS identified security vulnerabilities. This should be achievable through a GraphQL query and incorporated into the github scraper.

A quick vulnerability count per repository GraphQL query could mirror what is below but requires some TLC.

query getRepo($name: String!, $owner: String!){
  repository(name: $name, owner: $owner) {
    id
    vulnerabilityAlerts(first: 100) {
      edges {
        node {
          id
        }
      }
    }
  }
}

Things to note:

adrielp commented 6 months ago

This should be attached to a new milestone focused around engineering defaults & opinions. Will do that later