1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/monitorix_ynh.git synced 2024-09-03 19:46:06 +02:00

Update to monitorix 3.10.0

This commit is contained in:
Josué Tille 2017-10-30 21:59:43 +01:00
parent 94d5f0df77
commit 16f7951681
4 changed files with 8 additions and 7 deletions

View file

@ -6,7 +6,7 @@
"en": "A monitoring tools",
"fr": "Un outils de monitoring"
},
"version": "3.9.0",
"version": "3.10.0",
"url": "http://monitorix.org",
"license": "GPL-2.0",
"maintainer": {

View file

@ -3,8 +3,8 @@
app=$YNH_APP_INSTANCE_NAME
## Adapt md5sum while you update app
md5sum="7314ad6fcd014a34c2e4e8a95455bcaa"
monitorix_version="3.9.0"
sha256sum="3fb8b4a4f7aeeeafccc6dc5b232f82d5761be80fe8e82008bc768f805fe5a744"
monitorix_version="3.10.0"
install_dependances() {
ynh_install_app_dependencies rrdtool perl libwww-perl libmailtools-perl libmime-lite-perl librrds-perl libdbi-perl libxml-simple-perl libhttp-server-simple-perl libconfig-general-perl pflogsumm
@ -17,7 +17,7 @@ install_dependances() {
get_source() {
wget -q -O '/tmp/monitorix.deb' "http://www.monitorix.org/monitorix_${monitorix_version}-izzy1_all.deb"
if [[ ! -e '/tmp/monitorix.deb' ]] || [[ $(md5sum '/tmp/monitorix.deb' | cut -d' ' -f1) != $md5sum ]]
if [[ ! -e '/tmp/monitorix.deb' ]] || [[ $(sha256sum '/tmp/monitorix.deb' | cut -d' ' -f1) != $sha256sum ]]
then
ynh_die "Error : can't get monitorix debian package"
fi

View file

@ -25,6 +25,9 @@ dbuser=$app
ynh_mysql_drop_db "$dbname" || true
ynh_mysql_drop_user "$dbuser" || true
# Remove data
ynh_secure_remove /var/lib/monitorix
# Autoremove package
ynh_remove_app_dependencies
ynh_package_autoremove monitorix

View file

@ -19,9 +19,6 @@ ynh_webpath_available $domain $path || ynh_die "$domain/$path is not available,
# Download package
get_source
# Download package
get_source
# Install package
install_dependances
@ -32,6 +29,7 @@ ynh_mysql_create_user $dbuser $dbpass
# Restore all config and data
ynh_secure_remove /etc/monitorix # we remove the directory because if it is not empty the ynh_restore cmd fail
ynh_secure_remove /var/lib/monitorix
ynh_restore
# Reload nginx