k8s.io/test-infra@v0.0.0-20240520184403-27c6b4c223d8/config/prow/cluster/monitoring/mixins/grafana_dashboards/prow.jsonnet (about)

     1  local grafana = import 'grafonnet/grafana.libsonnet';
     2  local dashboard = grafana.dashboard;
     3  local graphPanel = grafana.graphPanel;
     4  local singlestat = grafana.singlestat;
     5  local prometheus = grafana.prometheus;
     6  
     7  local legendConfig = {
     8          legend+: {
     9              sideWidth: 250
    10          },
    11      };
    12  
    13  local dashboardConfig = {
    14          uid: '970b051d3adfd62eb592154c5ce80377',
    15      };
    16  
    17  dashboard.new(
    18          'prow dashboard',
    19          time_from='now-1d',
    20          schemaVersion=18,
    21        )
    22  .addPanel(
    23      (graphPanel.new(
    24          'up',
    25          description='sum by(job) (up)',
    26          datasource='prometheus',
    27          legend_alignAsTable=true,
    28          legend_rightSide=true,
    29      ) + legendConfig)
    30      .addTarget(prometheus.target(
    31          'sum by(job) (up)',
    32          legendFormat='{{job}}',
    33      )), gridPos={
    34      h: 9,
    35      w: 24,
    36      x: 0,
    37      y: 0,
    38    })
    39  + dashboardConfig