From 26fce85bb03d190aef83959ac538040122b853c2 Mon Sep 17 00:00:00 2001 From: Shivam Mishra Date: Sat, 14 Oct 2023 12:10:12 +0530 Subject: [PATCH 1/2] fix: redis URL generated --- app/Http/Livewire/Project/Database/Redis/General.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Livewire/Project/Database/Redis/General.php b/app/Http/Livewire/Project/Database/Redis/General.php index c8e15062a..866c0325f 100644 --- a/app/Http/Livewire/Project/Database/Redis/General.php +++ b/app/Http/Livewire/Project/Database/Redis/General.php @@ -80,9 +80,9 @@ public function mount() public function getDbUrl() { if ($this->database->is_public) { - $this->db_url = "redis://{$this->database->redis_password}@{$this->database->destination->server->getIp}:{$this->database->public_port}/0"; + $this->db_url = "redis://:{$this->database->redis_password}@{$this->database->destination->server->getIp}:{$this->database->public_port}/0"; } else { - $this->db_url = "redis://{$this->database->redis_password}@{$this->database->uuid}:5432/0"; + $this->db_url = "redis://:{$this->database->redis_password}@{$this->database->uuid}:6379/0"; } } public function render() From bc3e59e4ef5c7fe6a5790b5a3896bd9f35c030cc Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Sat, 14 Oct 2023 17:26:16 +0200 Subject: [PATCH 2/2] fix: delete resource if there was an error fix: do not refresh on containerStatusJob (db view) --- app/Http/Livewire/Project/Database/Heading.php | 2 -- app/Jobs/StopResourceJob.php | 3 ++- config/sentry.php | 2 +- config/version.php | 2 +- versions.json | 2 +- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/app/Http/Livewire/Project/Database/Heading.php b/app/Http/Livewire/Project/Database/Heading.php index 7b2796c85..fc867ce79 100644 --- a/app/Http/Livewire/Project/Database/Heading.php +++ b/app/Http/Livewire/Project/Database/Heading.php @@ -6,7 +6,6 @@ use App\Actions\Database\StartRedis; use App\Actions\Database\StopDatabase; use App\Jobs\ContainerStatusJob; -use App\Notifications\Application\StatusChanged; use Livewire\Component; class Heading extends Component @@ -29,7 +28,6 @@ public function check_status() { dispatch_sync(new ContainerStatusJob($this->database->destination->server)); $this->database->refresh(); - $this->emit('refresh'); } public function mount() diff --git a/app/Jobs/StopResourceJob.php b/app/Jobs/StopResourceJob.php index a702d83f3..0bfc1f2fa 100644 --- a/app/Jobs/StopResourceJob.php +++ b/app/Jobs/StopResourceJob.php @@ -45,10 +45,11 @@ public function handle() StopService::run($this->resource); break; } - $this->resource->delete(); } catch (\Throwable $e) { send_internal_notification('ContainerStoppingJob failed with: ' . $e->getMessage()); throw $e; + } finally { + $this->resource->delete(); } } } diff --git a/config/sentry.php b/config/sentry.php index 83b5e5e5f..fd7d35889 100644 --- a/config/sentry.php +++ b/config/sentry.php @@ -7,7 +7,7 @@ // The release version of your application // Example with dynamic git hash: trim(exec('git --git-dir ' . base_path('.git') . ' log --pretty="%h" -n1 HEAD')) - 'release' => '4.0.0-beta.84', + 'release' => '4.0.0-beta.85', // When left empty or `null` the Laravel environment will be used 'environment' => config('app.env'), diff --git a/config/version.php b/config/version.php index e9a5cd388..4076867dc 100644 --- a/config/version.php +++ b/config/version.php @@ -1,3 +1,3 @@