diff --git a/scripts/install b/scripts/install index 847e658..f325c6a 100755 --- a/scripts/install +++ b/scripts/install @@ -62,6 +62,10 @@ sed -i "s@MYSQL_USER@$dbuser@g" $monitorix_conf sed -i "s@MYSQL_PASSWORD@$dbpass@g" $monitorix_conf sudo cp $monitorix_conf /etc/monitorix/monitorix.conf +# register yunohost service +sudo yunohost service add monitorix + # Reload services -sudo service nginx reload sudo service monitorix restart +sudo yunohost app ssowatconf +sudo service nginx reload diff --git a/scripts/remove b/scripts/remove index 9b4b75c..00e3b35 100755 --- a/scripts/remove +++ b/scripts/remove @@ -24,5 +24,7 @@ ynh_mysql_drop_user "$dbuser" || true # Autoremove package ynh_package_autoremove monitorix +sudo yunohost service remove monitorix + # Reload nginx service sudo service nginx reload diff --git a/scripts/restore b/scripts/restore index 07da963..93b69b0 100755 --- a/scripts/restore +++ b/scripts/restore @@ -117,5 +117,6 @@ sudo cp -a ./data/. "/var/lib/monitorix/." # Restart webserver -sudo service nginx reload -sudo service monitorix restart \ No newline at end of file +sudo service monitorix restart +sudo yunohost app ssowatconf +sudo service nginx reload \ No newline at end of file diff --git a/scripts/upgrade b/scripts/upgrade index bbe5634..190d412 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -47,5 +47,6 @@ sed -i "s@MYSQL_PASSWORD@$dbpass@g" $monitorix_conf sudo cp $monitorix_conf /etc/monitorix/monitorix.conf # Reload services -sudo service nginx reload sudo service monitorix restart +sudo yunohost app ssowatconf +sudo service nginx reload