diff options
Diffstat (limited to 'config/backup/backup.inc')
-rw-r--r-- | config/backup/backup.inc | 29 |
1 files changed, 2 insertions, 27 deletions
diff --git a/config/backup/backup.inc b/config/backup/backup.inc index b10fceb8..df508775 100644 --- a/config/backup/backup.inc +++ b/config/backup/backup.inc @@ -78,40 +78,15 @@ function backup_install_command() global $config; conf_mount_rw(); - if (!is_dir('/usr/local/www/packages/')) { - exec("mkdir /usr/local/www/packages/"); - } - - if (!is_dir('/usr/local/www/packages/backup/')) { - exec("mkdir /usr/local/www/packages/backup/"); - } - //create the backup directory if (!is_dir('/root/backup/')) { - exec("mkdir /root/backup/"); + @mkdir("/root/backup/"); } - //rename PHP files from .tmp to .php - exec("cp /tmp/backup.tmp /usr/local/www/packages/backup/backup.php"); - unlink_if_exists("/tmp/backup.tmp"); - - exec("cp /tmp/backup_edit.tmp /usr/local/www/packages/backup/backup_edit.php"); - unlink_if_exists("/tmp/backup_edit.tmp"); - backup_sync_package(); conf_mount_ro(); } - -function backup_deinstall_command() -{ - conf_mount_rw(); - unlink_if_exists("/usr/local/pkg/backup.xml"); - unlink_if_exists("/usr/local/pkg/backup.inc"); - exec("rm /usr/local/www/packages/backup/"); - conf_mount_ro(); -} - -?>
\ No newline at end of file +?> |