1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/grafana_ynh.git synced 2024-09-03 20:36:29 +02:00

Fix bad NetData template import for Grafana version > 5 (fixes #14) (#15)

Pre-imported dashboard was failing due to missing uid field.
Moreover, Influxdb auto-configuration to enable opentsdb wasn't working any more.

All of this was certainly due to recent versions of Grafana and Influxdb.
This commit is contained in:
JimboJoe 2018-05-26 09:28:18 +02:00 committed by GitHub
parent e5a150e077
commit cf9d6789c0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 7 deletions

File diff suppressed because one or more lines are too long

View file

@ -6,7 +6,7 @@
"en": "Beautiful metric & analytic dashboards for monitoring", "en": "Beautiful metric & analytic dashboards for monitoring",
"fr": "Tableaux de bords de supervision" "fr": "Tableaux de bords de supervision"
}, },
"version": "1.0.0", "version": "1.1.0~ynh1",
"license": "Apache-2.0", "license": "Apache-2.0",
"url": "http://grafana.org/", "url": "http://grafana.org/",
"maintainer": { "maintainer": {

View file

@ -85,14 +85,14 @@ ynh_mysql_create_db "$dbname" "$dbuser" "$dbpass"
# Configure InfluxDB # Configure InfluxDB
if [ -f /etc/influxdb/influxdb.conf ] ; then if [ -f /etc/influxdb/influxdb.conf ] ; then
sudo sed -i '/^\[\[opentsdb\]\]$/,/^\[/ s/# enabled = false/enabled = true/' /etc/influxdb/influxdb.conf sudo sed -i '/^\[\[opentsdb\]\]$/,/^\[/ s/enabled = false/enabled = true/' /etc/influxdb/influxdb.conf
else else
[ -d /etc/influxdb ] || sudo mkdir /etc/influxdb [ -d /etc/influxdb ] || sudo mkdir /etc/influxdb
sudo cp ../conf/influxdb.conf /etc/influxdb sudo cp ../conf/influxdb.conf /etc/influxdb
fi fi
# Start InfluxDB server # Start InfluxDB server
sudo systemctl start influxdb sudo systemctl restart influxdb
# Configure Grafana # Configure Grafana
sudo cp ../conf/ldap.toml /etc/grafana sudo cp ../conf/ldap.toml /etc/grafana