1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/roundcube_ynh.git synced 2024-09-03 20:16:28 +02:00

[enh] Update backup script to use ynh_backup helper

This commit is contained in:
Jérôme Lebleu 2016-05-07 02:11:39 +02:00
parent e304c4df63
commit 1b2aea557a
2 changed files with 5 additions and 5 deletions

View file

@ -11,14 +11,14 @@
"name": "kload", "name": "kload",
"email": "kload@kload.fr" "email": "kload@kload.fr"
}, },
"multi_instance": "true", "multi_instance": true,
"services": [ "services": [
"nginx", "nginx",
"php5-fpm", "php5-fpm",
"mysql" "mysql"
], ],
"requirements": { "requirements": {
"yunohost": ">= 2.3.10" "yunohost": ">= 2.3.15"
}, },
"arguments": { "arguments": {
"install" : [ "install" : [

View file

@ -18,11 +18,11 @@ dbpass=$(ynh_app_setting_get $app mysqlpwd)
# Copy the app files # Copy the app files
DESTDIR="/var/www/$app" DESTDIR="/var/www/$app"
sudo cp -a "$DESTDIR" ./sources ynh_backup "$DESTDIR" "sources"
# Copy the conf files # Copy the conf files
sudo cp -a "/etc/nginx/conf.d/${domain}.d/${app}.conf" ./nginx.conf ynh_backup "/etc/nginx/conf.d/${domain}.d/${app}.conf" "nginx.conf"
sudo cp -a "/etc/php5/fpm/pool.d/${app}.conf" ./php-fpm.conf ynh_backup "/etc/php5/fpm/pool.d/${app}.conf" "php-fpm.conf"
# Dump the database # Dump the database
mysqldump -u "$dbuser" -p"$dbpass" --no-create-db "$dbname" > ./dump.sql mysqldump -u "$dbuser" -p"$dbpass" --no-create-db "$dbname" > ./dump.sql