Skip to content

jeromemarc/redhat-insights

Repository files navigation

Grafana Data Source Plugin for Red Hat Insights

This template is a starting point for building a Grafana Data Source Plugin for Red Hat Insights. The content is based on the article "Integrate Grafana and Red Hat Insights through APIs" published on the Red Hat Blog.

Learn more

Overview

Plugin import:

alt text

Plugin configuration:

alt text

Sample query on Insights APIs (method passed as query parameter e.g. advisor):

alt text

Dashboard overview:

alt text

Build and install redhat-insights plugin

The code provided must be compiled before it can be recognized by Grafana. The following commands may be adapted for your particular Grafana environment:

# nvm install
# mkdir /var/lib/grafana/plugins/
# cd /var/lib/grafana/plugins/
Extract the redhat-insights github files into redhat-insights
# cd /var/lib/grafana/plugins/redhat-insights
# npm install --global yarn
# yarn install --ignore-engines
# yarn build

In order to allow unsigned plugin in your Grafana environment, /etc/grafana/grafana.ini configuration file must be modified:

app_mode = development
enable_alpha = true
allow_loading_unsigned_plugins = "redhat-insights"

Make sure your start or restart your Grafana environment after these changes:

# sudo systemctl restart grafana-server

You can then login in your Grafana environment and configure the redhat-insights plugin by adding a datasource under Home > Administration > Plugins and data > Plugins.

The provided sample dashboard can also be imported manually under Dashboards using /provisioning/dashboard/dashboard.json file.

About

Grafana Data Source Plugin for Red Hat Insights

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published