Browse Source

Fix backup

Ernesto Nicolás Carrea 5 years ago
parent
commit
b954cf3625
1 changed files with 2 additions and 1 deletions
  1. 2 1
      bin/module/func.inc

+ 2 - 1
bin/module/func.inc

@@ -26,11 +26,12 @@ hestia_module_getvariant() {
 }
 }
 
 
 # Backup config files (usually prior to module install)
 # Backup config files (usually prior to module install)
+# hestia_config_backup 'prefix' file1 file2 file3 ...
 hestia_config_backup() {
 hestia_config_backup() {
     dest=$HESTIA/data/backup/
     dest=$HESTIA/data/backup/
     filename=${1}-$(date +%Y%m%d%H%M%S)
     filename=${1}-$(date +%Y%m%d%H%M%S)
     shift
     shift
 
 
     mkdir -p $dest
     mkdir -p $dest
-    tar -zcf ${filename}.tar.gz $@
+    tar -zc --warning=none --ignore-failed-read -f $dest/${filename}.tar.gz $@
 }
 }