A simple cli utility for importing or exporting dashboard json definitions using the Grafana HTTP API.

Overview

grafana-dashboard-manager

CodeQL

A simple cli utility for importing or exporting dashboard json definitions using the Grafana HTTP API.

This may be useful for:

  • Backing up your dashboards that already exist within your Grafana instance, e.g. if you are migrating from the internal sqlite database to MySQL.
  • Updating dashboard files for your Infrastructure-as-Code, for use with Grafana dashboard provisioning.
  • Making tweaks to dashboard JSON files directly and updating Grafana with one command.

Notable features:

  • Mirrors the folder structure between a local set of dashboards and Grafana, creating folders where necessary.
  • Ensures links to dashboards folders in a dashlist Panel are consistent with the Folder IDs - useful for deploying one set of dashboards across mulitple Grafana instances, e.g. for dev, test, prod environments.

Workflow

The intended development process is:

  1. Develop existing dashboard, or create a new one and save it in the web UI.
  2. Ensure the dashboard is in the desired folder.
  3. Use grafana-dashboard-manager to extract the new dashboards and save them to a local directory.
  4. Dashboards can be created/updated from the local directory back into Grafana.

Usage

Installation

Dependencies are managed with poetry.

Install from pypi:

$ poetry run pip install grafana-dashboard-manager

Install from source

$ cd /path/to/grafana-dashboard-manager
$ poetry install

Note that the admin login user and password are required, and its selected organization is correct.

See the full help text with poetry run grafana-dashboard-manager --help

Download dashboards from web to solution-data

poetry run grafana-dashboard-manager \
    --host https://my.grafana.com \
    --username admin --password mypassword \
    download all \
    --destination-dir /path/to/dashboards/

Upload dashboards from solution-data to web

poetry run grafana-dashboard-manager \
    --host https://my.grafana.com \
    --username admin --password mypassword \
    upload all \
    --source-dir /path/to/dashboards/

N.B. if your Grafana is not at port 80/443 as indicated by the protocol prefix, the port needs to be specified as part of the --host argument, e.g. for a locally hosted instance on port 3000: --host http://localhost:3000

Limitations

  • The home dashboard new deployment needs the default home dashboard to be manually set in the web UI, as the API to set the organisation default dashboard seems to be broken, at least on v8.2.3.

  • Currently expects a hardcoded 'home.json' dashboard to set as the home.

  • Does not handle upload of dashboards more deeply nested than Grafana supports.

  • Does not support multi-organization deployments

Owner
Beam Connectivity
Beam Connectivity
Set of scripts & tools for converting between numbers and major system encoded words.

major-system-converter Set of scripts & tools for converting between numbers and major system encoded words. Uses phonetics instead of letters to conv

4 Aug 09, 2022
PyArmor is a command line tool used to obfuscate python scripts

PyArmor is a command line tool used to obfuscate python scripts, bind obfuscated scripts to fixed machine or expire obfuscated scripts.

Dashingsoft 2k Jan 07, 2023
AutoSub is a CLI application to generate subtitle files (.srt, .vtt, and .txt transcript) for any video file using Mozilla DeepSpeech.

AutoSub About Motivation Installation Docker How-to example How it works TO-DO Contributing References About AutoSub is a CLI application to generate

Abhiroop Talasila 414 Jan 06, 2023
Python Processing Tool for Vasp Ipnut/Output

PivotPy A Python Processing Tool for Vasp Input/Output. A CLI is available in Powershell, see Vasp2Visual. stylea{text-decoration: none !important;c

Abdul Saboor 5 Aug 16, 2022
asciinema - Terminal session recorder 📹

asciinema - Terminal session recorder 📹

asciinema 11.1k Dec 27, 2022
Todo - You could use terminal to set your todo

Python Tutorial You can learn how to build a terminal application(CLI applicatio

29 Jun 29, 2022
Python library and command line tool for interacting with Bugzilla

python-bugzilla This package provides two bits: bugzilla python module for talking to a Bugzilla instance over XMLRPC or REST /usr/bin/bugzilla comman

Python Bugzilla Project 112 Nov 05, 2022
Command-line script to upload videos to Youtube using theYoutube APIv3.

Introduction Command-line script to upload videos to Youtube using theYoutube APIv3. It should work on any platform (GNU/Linux, BSD, OS X, Windows, ..

Arnau Sanchez 1.9k Jan 09, 2023
A command line utility for tracking a stock market portfolio. Primarily featuring high resolution braille graphs.

A command line stock market / portfolio tracker originally insipred by Ericm's Stonks program, featuring unicode for incredibly high detailed graphs even in a terminal.

Conrad Selig 51 Nov 29, 2022
Project scoped command execution to just do your work

Judoka is a command line utility that lets you define project scoped commands and call them through their alias. It lets you just do (= judo) your work.

Eelke van den Bos 2 Dec 17, 2021
A simple CLI based any Download Tool, that find files and let you stream or download thorugh WebTorrent CLI or Aria or any command tool

Privateer A simple CLI based any Download Tool, that find files and let you stream or download thorugh WebTorrent CLI or Aria or any command tool How

Shreyash Chavan 2 Apr 04, 2022
CLI Utility to encode and recursively recreate directories with ffmpeg.

FFenmass CLI Utility to encode and recursively recreate directories with ffmpeg. Report Bug · Request Feature Table of Contents Getting Started Prereq

George Av. 8 May 06, 2022
A Python module and command line utility for working with web archive data using the WACZ format specification

py-wacz The py-wacz repository contains a Python module and command line utility for working with web archive data using the WACZ format specification

Webrecorder 14 Oct 24, 2022
This is a simple Termo application in command line style

my-termo This is a simple Termo application in command line style. This app run a Linux crontab task every day to get a new word. Type termo in your t

Gustavo Soares 1 Feb 14, 2022
Doro is a CLI based pomodoro app and countdown timer application built using python.

Doro - CLI based pomodoro app Doro is a CLI based pomodoro app and countdown timer application built using python. Install $ pip install doro Usage Po

Suresh Kumar 14 May 23, 2022
A simple python implementation of a reverse shell

llehs A python implementation of a reverse shell. Note for contributors The project is open for contributions and is hacktoberfest registered! llehs u

Archisman Ghosh 2 Jul 05, 2022
Pastekan adalah website paste kode / teks sederhana

Pastekan pastekan adalah website paste kode / teks sederhana. install pip install pastekan penggunaan pastekan myfile.txt atau echo "hi" | pastekan

Sekai Kode 1 Dec 24, 2021
Python codecs extension featuring CLI tools for encoding/decoding anything

CodExt Encode/decode anything. This library extends the native codecs library (namely for adding new custom encodings and character mappings) and prov

Alex 210 Dec 30, 2022
Simple Python Library to display text with color in Python Terminal

pyTextColor v1.0 Introduction pyTextColor is a simple Python Library to display colorful outputs in Terminal, etc. Note: Your Terminal or any software

Siddhesh Chavan 1 Jan 23, 2022
A command line tool to hide and reveal information inside images (works for both PNGs and JPGs)

ImgReRite A command line tool to hide and reveal information inside images (work

Jigyasu 10 Jul 27, 2022