From 0d7c11f19bfe3300fa3a27de3f5dff337c978478 Mon Sep 17 00:00:00 2001 From: shimon Date: Tue, 28 Feb 2023 09:35:57 +0200 Subject: [PATCH] folder backup --- src/Appwrite/Platform/Tasks/Backup.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/Appwrite/Platform/Tasks/Backup.php b/src/Appwrite/Platform/Tasks/Backup.php index 7169663888..b3814f2931 100644 --- a/src/Appwrite/Platform/Tasks/Backup.php +++ b/src/Appwrite/Platform/Tasks/Backup.php @@ -30,7 +30,7 @@ class Backup extends Action while (!connection_aborted() || PHP_SAPI == "cli") { $now = new \DateTime(); $now->setTimezone(new \DateTimeZone(date_default_timezone_get())); - $next = new \DateTime($now->format("Y-m-d 11:30.0")); + $next = new \DateTime($now->format("Y-m-d 16:0.0")); $next->setTimezone(new \DateTimeZone(date_default_timezone_get())); $sleep = $next->getTimestamp() - $now->getTimestamp(); @@ -68,14 +68,13 @@ class Backup extends Action $stdout = ''; $stderr = ''; - Console::execute( - 'cd ' . $folder . ' && tar --exclude ' . $filename . ' -zcf ' . $source . '*', + 'cd ' . $folder . ' && tar --exclude ' . $filename . ' -zcf ' . $source . ' *', '', $stdout, $stderr ); - + var_dump($local->exists($source)); try { if (!$local->exists($source)) { continue;