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

Merge pull request #127 from YunoHost-Apps/testing

Testing - portable format
This commit is contained in:
Salamandar 2024-01-30 10:32:08 +01:00 committed by GitHub
commit 8509ffaa39
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 5 deletions

View file

@ -44,7 +44,7 @@ if [ -d "/var/lib/influxdb/data/opentsdb" ]; then
ynh_print_warn --message="The InfluxDB database will not be saved, because 'do_not_backup_data' is set." ynh_print_warn --message="The InfluxDB database will not be saved, because 'do_not_backup_data' is set."
fi fi
else else
influxd backup -database opentsdb influxdb_data influxd backup -portable influxdb_data
fi fi
fi fi

View file

@ -59,10 +59,7 @@ ynh_script_progression --message="Restoring the InfluxDB database..." --weight=1
# That happens when passing automated tests (NetData not present) # That happens when passing automated tests (NetData not present)
ynh_systemd_action --service_name=influxdb --action="stop" ynh_systemd_action --service_name=influxdb --action="stop"
if [ "$(ls -A ./influxdb_data)" ] ; then if [ "$(ls -A ./influxdb_data)" ] ; then
influxd restore -metadir /var/lib/influxdb/meta ./influxdb_data influxd restore -portable ./influxdb_data
if [ "$(ls -A ./influxdb_data/opentsdb*)" ] ; then
influxd restore -database opentsdb -data_dir /var/lib/influxdb/data ./influxdb_data
fi
fi fi
#================================================= #=================================================