From 392c1650db38351c81e7718f70087eadf4d4a513 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Thu, 17 Aug 2023 15:32:40 +0200 Subject: [PATCH] separate backups on fs & s3 layer --- app/Jobs/DatabaseBackupJob.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Jobs/DatabaseBackupJob.php b/app/Jobs/DatabaseBackupJob.php index 8694eff0d..eed6c5de8 100644 --- a/app/Jobs/DatabaseBackupJob.php +++ b/app/Jobs/DatabaseBackupJob.php @@ -69,12 +69,12 @@ class DatabaseBackupJob implements ShouldQueue return; } $this->container_name = $this->database->uuid; - $this->backup_dir = backup_dir() . "/" . Str::of($this->team->name)->slug() . '-' .$this->team->id . '/' . $this->container_name; + $this->backup_dir = backup_dir() . "/databases/" . Str::of($this->team->name)->slug() . '-' . $this->team->id . '/' . $this->container_name; if ($this->database->name === 'coolify-db') { $this->container_name = "coolify-db"; $ip = Str::slug($this->server->ip); - $this->backup_dir = backup_dir() . "/" . Str::of($this->team->name)->slug() . '-' .$this->team->id . "/coolify-db-$ip"; + $this->backup_dir = backup_dir() . "/coolify" . "/coolify-db-$ip"; } $this->backup_file = "/dumpall-" . Carbon::now()->timestamp . ".sql"; $this->backup_location = $this->backup_dir . $this->backup_file;