dark

module
v0.10.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 12, 2023 License: MIT

README

DARK

codecov

Dashboards As Resources in Kubernetes.

DARK provides a way to define and deploy Grafana dashboards via Kubernetes, next to the services they monitor.

If you are looking for a way to version your dashboards and deploy them across all environments, like you would do with your services, then this project is meant for you.

In addition to dashboards, DARK can also manage:

Design goals

  • full description of dashboards via YAML
  • integration with kubectl
  • seamless integration with Grafana
  • delegate YAML decoding and dashboard generation to Grabana

Non-goals

Example dashboard

apiVersion: k8s.kevingomez.fr/v1
kind: GrafanaDashboard
metadata:
  name: example-dashboard
  namespace: monitoring
  annotations:
    dark/folder: "Awesome folder"
spec:
  title: Awesome dashboard
  shared_crosshair: true
  tags: [generated, yaml]
  auto_refresh: 10s

  variables:
    - interval:
        name: interval
        label: interval
        default: 1m
        values: [30s, 1m, 5m, 10m, 30m, 1h, 6h, 12h]

  rows:
    - name: Prometheus
      panels:
        - timeseries:
            title: HTTP Rate
            datasource: prometheus-default
            targets:
              - prometheus:
                  query: "rate(promhttp_metric_handler_requests_total[$interval])"
                  legend: "{{ handler }} - {{ code }}"
        
        - graph:
            title: Heap allocations
            datasource: prometheus-default
            targets:
              - prometheus:
                  query: "go_memstats_heap_alloc_bytes"
                  legend: "{{ job }}"

More examples can be found in the examples/ folder

Installation & usage

Check out the documentation to dig deeper into how to set up and use DARK.

Adopters

Companies using DARK.

They talk about DARK

License

This library is under the MIT license.

Directories

Path Synopsis
api
v1
Package v1 contains API Schema definitions for the v1 API group +kubebuilder:object:generate=true +groupName=k8s.kevingomez.fr
Package v1 contains API Schema definitions for the v1 API group +kubebuilder:object:generate=true +groupName=k8s.kevingomez.fr
v1alpha1
Package v1alpha1 contains API Schema definitions for the v1alpha1 API group +kubebuilder:object:generate=true +groupName=k8s.kevingomez.fr
Package v1alpha1 contains API Schema definitions for the v1alpha1 API group +kubebuilder:object:generate=true +groupName=k8s.kevingomez.fr
cmd
internal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL