Skip to content

A Grafana Backend Plugin that handles rendering of panels & dashboards to PNGs using headless chrome

License

Notifications You must be signed in to change notification settings

AgnesToulet/grafana-image-renderer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

97 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A Grafana backend plugin that handles rendering panels and dashboards to PNGs using headless Chrome.

Requirements

Supported operating systems

  • Linux (x64)
  • Windows (x64)
  • Mac OS X (x64)

Dependencies

This plugin is packaged in a single executable with Node.js runtime and Chromium browser. This means that you don't need to have Node.js and Chromium installed in your system for the plugin to function.

However, Chromium browser depends on certain libraries and if you don't have all of those libraries installed in your system you may encounter errors when trying to render an image. For further details and troubleshooting help, please refer to Grafana Image Rendering documentation.

Known issue having IPv6 disabled

We've got reports regarding the plugin doesn't work if IPv6 is disabled. The current workaround is to use Remote Rendering Using Docker instead. Refer to issue for more information.

Installation

Using grafana-cli

NOTE: Installing this plugin using grafana-cli is supported from Grafana v6.4.

grafana-cli plugins install grafana-image-renderer

Install in Grafana Docker image

This plugin is not compatible with the current Grafana Docker image without installing further system-level dependencies. We recommend setting up another Docker container for rendering and using remote rendering, see Remote Rendering Using Docker for reference.

If you still want to install the plugin in the Grafana docker image we provide instructions for how to build a custom Grafana image, see Grafana Docker documentation for further instructions.

Environment variables

You can override certain settings by using environment variables and making sure that those are available for the Grafana process.

Default timezone:

Instruct headless Chrome to use a default timezone when not provided by Grafana, e.g. when rendering panel image of alert. See ICU’s metaZones.txt for a list of supported timezone IDs. Fallbacks to TZ environment variable if not set.

GF_RENDERER_PLUGIN_TZ=Europe/Stockholm

Ignore HTTPS errors:

Instruct headless Chrome whether to ignore HTTPS errors during navigation. Per default HTTPS errors is not ignored. Due to the security risk it's not recommended to ignore HTTPS errors.

GF_RENDERER_PLUGIN_IGNORE_HTTPS_ERRORS=true

gRPC port:

Change the listening port of the gRPC server. Default is 0 and will automatically assign a port not in use.

GF_RENDERER_PLUGIN_GRPC_PORT=50059

Remote Rendering Using Docker

Instead of installing and running the image renderer as a plugin, you can run it as a remote image rendering service using Docker. Read more about remote rendering using Docker.

Troubleshooting

For troubleshooting help, please refer to Grafana Image Rendering documentation.

Building from source

See Building from source.

Additional information

See docs.

About

A Grafana Backend Plugin that handles rendering of panels & dashboards to PNGs using headless chrome

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 66.3%
  • JavaScript 20.1%
  • Shell 7.0%
  • Dockerfile 4.8%
  • Makefile 1.8%