{"id":45125892,"url":"https://github.com/wcatz/dashboard-generator","last_synced_at":"2026-03-07T16:08:17.802Z","repository":{"id":337433427,"uuid":"1153471408","full_name":"wcatz/dashboard-generator","owner":"wcatz","description":"Config-driven Grafana dashboard generator. YAML in, interlinked JSON dashboards out.","archived":false,"fork":false,"pushed_at":"2026-03-06T12:19:47.000Z","size":354,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-03-06T15:48:59.166Z","etag":null,"topics":["dashboard","devops","grafana","grafana-dashboard","monitoring","prometheus","python","yaml"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wcatz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-09T10:40:11.000Z","updated_at":"2026-03-06T12:18:28.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/wcatz/dashboard-generator","commit_stats":null,"previous_names":["wcatz/dashboard-generator"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/wcatz/dashboard-generator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wcatz%2Fdashboard-generator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wcatz%2Fdashboard-generator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wcatz%2Fdashboard-generator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wcatz%2Fdashboard-generator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wcatz","download_url":"https://codeload.github.com/wcatz/dashboard-generator/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wcatz%2Fdashboard-generator/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30221193,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T14:02:48.375Z","status":"ssl_error","status_checked_at":"2026-03-07T14:02:43.192Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dashboard","devops","grafana","grafana-dashboard","monitoring","prometheus","python","yaml"],"created_at":"2026-02-19T23:06:42.581Z","updated_at":"2026-03-07T16:08:17.753Z","avatar_url":"https://github.com/wcatz.png","language":"Go","readme":"# dashboard-generator\n\nConfig-driven Grafana dashboard generator. Write YAML, get interlinked JSON dashboards.\n\n## Why\n\nHand-editing Grafana JSON is painful. Clicking through the UI doesn't scale. This tool lets you define dashboards declaratively in YAML and generates production-ready Grafana JSON with automatic navigation links, layout, and consistent styling.\n\n**One config file. Any number of dashboards. Zero clicking.**\n\n## Features\n\n- **14 panel types**: stat, gauge, timeseries, bargauge, heatmap, histogram, table, piechart, state-timeline, status-history, text, logs, row, comparison\n- **Auto-layout engine**: panels flow left-to-right across a 24-unit grid, wrapping automatically\n- **Navigation links**: every dashboard links to every other dashboard in the set\n- **Reference system**: reusable colors (`$green`), thresholds (`$percent_usage`), selectors (`${by_ns}`), and constants (`${rate_interval}`)\n- **Template variables**: query, custom, datasource, and interval types with chaining support\n- **Metric discovery**: query Prometheus and get suggested YAML config snippets\n- **Two-datasource comparison**: compare metrics across Prometheus instances side-by-side\n- **Profiles**: generate subsets of dashboards (e.g. `--profile infra` for infra-only)\n- **Push to Grafana**: deploy dashboards directly via the Grafana API\n- **Web UI**: edit config, browse metrics, visual dashboard preview with panel detail drawer, interactive palette editor, generate and push from a browser\n\n## Quick Start\n\n### Binary\n\n```bash\n# download from GitHub releases\n# https://github.com/wcatz/dashboard-generator/releases\n\n# generate dashboard JSON\n./dashboard-generator generate --config example-config.yaml --dry-run --verbose\n\n# start web UI\n./dashboard-generator serve --config example-config.yaml --port 8080\n\n# push to Grafana\n./dashboard-generator push --config example-config.yaml --grafana-url http://localhost:3000 --grafana-token $TOKEN\n```\n\n### Docker\n\n```bash\n# run web UI on localhost:8080, write generated dashboards to ./output\ndocker run --rm -p 8080:8080 \\\n  -v $(pwd)/example-config.yaml:/data/config.yaml:ro \\\n  -v $(pwd)/output:/data/output \\\n  wcatz/dashboard-generator:latest\n\n# open http://localhost:8080\n```\n\n### Build from Source\n\n```bash\nmake build\nmake test\nmake docker-build\nmake docker-run    # serves on localhost:8080, outputs to ./output\n```\n\n## CLI Reference\n\n| Command | Purpose |\n|---------|---------|\n| `generate` | Generate dashboard JSON from YAML config |\n| `discover` | Query Prometheus and print suggested YAML snippets |\n| `push` | Generate and push dashboards to Grafana API |\n| `serve` | Start the web UI server |\n\n| Flag | Commands | Purpose |\n|------|----------|---------|\n| `--config` | all | Path to YAML config (required) |\n| `--profile` | generate, push | Named profile filter |\n| `--output-dir` | generate, push | Override output directory |\n| `--dry-run` | generate | Generate to memory only |\n| `--verbose` | generate, push | Print panel details |\n| `--prometheus-url` | discover | Prometheus URL for metric discovery |\n| `--grafana-url` | push, serve | Grafana URL for push |\n| `--grafana-user` | push | Basic auth user |\n| `--grafana-pass` | push | Basic auth password |\n| `--grafana-token` | push | Bearer token for Grafana API |\n| `--port` | serve | HTTP port (default 8080) |\n\n## Helm Chart\n\nPublished to `oci://ghcr.io/wcatz/helm-charts/dashboard-generator` on every push to master and version tag.\n\n```bash\n# install from OCI registry\nhelm install dashboard-generator oci://ghcr.io/wcatz/helm-charts/dashboard-generator --version 0.1.0\n\n# or use in helmfile\nchart: oci://ghcr.io/wcatz/helm-charts/dashboard-generator\nversion: 0.1.0\n```\n\n## Docker Image\n\nPublished to `wcatz/dashboard-generator` on Docker Hub.\n\n| Tag Pattern | Trigger |\n|-------------|---------|\n| `latest` | push to master or version tag |\n| `master` | push to master |\n| `0.1.0` | git tag `v0.1.0` |\n| `0.1` | git tag `v0.1.x` |\n| `0` | git tag `v0.x.x` |\n\n## Config Structure\n\n```yaml\ngenerator:          # global settings (refresh, time range, output dir)\ndatasources:        # named Prometheus/other datasources\npalettes:           # named color palettes (hex colors)\nactive_palette:     # which palette to use\nthresholds:         # reusable threshold definitions\nselectors:          # reusable PromQL label selectors\nvariables:          # template variable definitions\nconstants:          # string constants for DRY queries\ndiscovery:          # metric auto-discovery settings\nprofiles:           # named dashboard subsets\ndashboards:         # dashboard definitions with sections and panels\n```\n\nSee `example-config.yaml` for a complete working example and `CLAUDE.md` for full schema documentation.\n\n## Panel Types\n\n| Type | Default Size | Best For |\n|------|-------------|----------|\n| `stat` | 3x4 | single value with threshold coloring |\n| `gauge` | 3x4 | percentage/bounded values |\n| `timeseries` | 12x7 | time-series line/bar/area charts |\n| `bargauge` | 6x5 | horizontal/vertical bar comparisons |\n| `heatmap` | 12x8 | distribution over time |\n| `histogram` | 12x7 | value distribution |\n| `table` | 24x8 | tabular data with filtering |\n| `piechart` | 6x6 | proportional breakdowns |\n| `state-timeline` | 12x5 | state changes over time |\n| `status-history` | 12x5 | status changes grid |\n| `text` | 24x3 | markdown/html content |\n| `logs` | 24x8 | log viewer |\n| `comparison` | 12x8 | multi-datasource metric comparison |\n\n## Releasing\n\n```bash\n# 1. bump helm-chart/Chart.yaml version + appVersion\n# 2. commit and push\ngit tag v0.2.0\ngit push origin v0.2.0\n# CI builds: Docker image (Docker Hub), Helm chart (ghcr.io), GitHub release (goreleaser)\n```\n\n## License\n\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwcatz%2Fdashboard-generator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwcatz%2Fdashboard-generator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwcatz%2Fdashboard-generator/lists"}