mvisonneau / gitlab-ci-pipelines-exporter

Prometheus / OpenMetrics exporter for GitLab CI pipelines insights
Apache License 2.0
1.21k stars 238 forks source link

mordenised, remove polystat dep., fix data links, remove logo dep. #824

Open R-Studio opened 2 months ago

R-Studio commented 2 months ago

What I changed:

If you need the entire commit history, take a look: https://github.com/onzack/grafana-dashboards/tree/main/grafana/gitlab-ci-pipelines-exporter

If someone uses the Grafana Operator, they can import it with a GrafanaDashboard custom resource like the following example:

---
apiVersion: grafana.integreatly.org/v1beta1
kind: GrafanaDashboard 
metadata:
  name: gitlab-ci-environments
  labels:
    app: grafana
spec:
  instanceSelector:
    matchLabels:
      grafanaInstance: main
  allowCrossNamespaceImport: true
  datasources:
    - inputName: DS_PROMETHEUS
      datasourceName: ${datasource}
    # Workaround: use "datasources" to overwrite template variable
    - inputName: VAR_GITLAB_HOST
      datasourceName: <YOUR_GITLAB_URL>
  contentCacheDuration: 1h
  folder: "GitLab"
  url: https://raw.githubusercontent.com/onzack/grafana-dashboards/main/grafana/gitlab-ci-pipelines-exporter/environments.json
mvisonneau commented 2 months ago

thanks for your contribution @R-Studio, unfortunately I did not seem to be able to get any dashboard to work out of the box with your branch? 🤔

image
R-Studio commented 2 months ago

thanks for your contribution @R-Studio, unfortunately I did not seem to be able to get any dashboard to work out of the box with your branch? 🤔

image

Yes it works out of the box for me. What are the errors you get? 🤔

mvisonneau commented 2 months ago

Here is the main error AFAICT: Failed to upgrade legacy queries Datasource ${DS_PROMETHEUS} was not found

R-Studio commented 2 months ago

Here is the main error AFAICT: Failed to upgrade legacy queries Datasource ${DS_PROMETHEUS} was not found

How do you import the dashboard, via WebUI?

mvisonneau commented 2 months ago

I'm simply trying out the examples/quickstart procedure.