diff --git a/scripts/restore b/scripts/restore index 2b6b602..bb93d92 100644 --- a/scripts/restore +++ b/scripts/restore @@ -15,8 +15,7 @@ source /usr/share/yunohost/helpers #================================================= ynh_script_progression --message="Validating restoration parameters..." --weight=1 -test ! -d "/etc/influxdb" \ - || ynh_die --message="InfluxDB / Grafana are already installed" +test ! -d "/etc/influxdb" || ynh_die --message="InfluxDB/Grafana are already installed" #================================================= # STANDARD RESTORATION STEPS @@ -46,7 +45,7 @@ ynh_restore_file --origin_path="/var/lib/grafana/plugins" --not_mandatory # Set permission with the new grafana user (id could have been changed) chown -R root:grafana "/etc/grafana" if [ -d "/var/lib/grafana/plugins" ]; then - chown -R grafana:grafana "/var/lib/grafana/plugins" + chown -R $app:$app "/var/lib/grafana/plugins" fi #=================================================