Merge branch 'next' into feat/healthcheck-cmd

This commit is contained in:
Aditya Tripathi 2025-12-26 04:05:36 +05:30 committed by GitHub
commit 362b43a806
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 10 deletions

View file

@ -5,7 +5,6 @@
use App\Helpers\SslHelper; use App\Helpers\SslHelper;
use App\Models\SslCertificate; use App\Models\SslCertificate;
use App\Models\StandaloneKeydb; use App\Models\StandaloneKeydb;
use Illuminate\Support\Facades\Storage;
use Lorisleiva\Actions\Concerns\AsAction; use Lorisleiva\Actions\Concerns\AsAction;
use Symfony\Component\Yaml\Yaml; use Symfony\Component\Yaml\Yaml;
@ -270,10 +269,9 @@ private function add_custom_keydb()
return; return;
} }
$filename = 'keydb.conf'; $filename = 'keydb.conf';
Storage::disk('local')->put("tmp/keydb.conf_{$this->database->uuid}", $this->database->keydb_conf); $content = $this->database->keydb_conf;
$path = Storage::path("tmp/keydb.conf_{$this->database->uuid}"); $content_base64 = base64_encode($content);
instant_scp($path, "{$this->configuration_dir}/{$filename}", $this->database->destination->server); $this->commands[] = "echo '{$content_base64}' | base64 -d | tee $this->configuration_dir/{$filename} > /dev/null";
Storage::disk('local')->delete("tmp/keydb.conf_{$this->database->uuid}");
} }
private function buildStartCommand(): string private function buildStartCommand(): string

View file

@ -5,7 +5,6 @@
use App\Helpers\SslHelper; use App\Helpers\SslHelper;
use App\Models\SslCertificate; use App\Models\SslCertificate;
use App\Models\StandaloneRedis; use App\Models\StandaloneRedis;
use Illuminate\Support\Facades\Storage;
use Lorisleiva\Actions\Concerns\AsAction; use Lorisleiva\Actions\Concerns\AsAction;
use Symfony\Component\Yaml\Yaml; use Symfony\Component\Yaml\Yaml;
@ -316,9 +315,8 @@ private function add_custom_redis()
return; return;
} }
$filename = 'redis.conf'; $filename = 'redis.conf';
Storage::disk('local')->put("tmp/redis.conf_{$this->database->uuid}", $this->database->redis_conf); $content = $this->database->redis_conf;
$path = Storage::path("tmp/redis.conf_{$this->database->uuid}"); $content_base64 = base64_encode($content);
instant_scp($path, "{$this->configuration_dir}/{$filename}", $this->database->destination->server); $this->commands[] = "echo '{$content_base64}' | base64 -d | tee $this->configuration_dir/{$filename} > /dev/null";
Storage::disk('local')->delete("tmp/redis.conf_{$this->database->uuid}");
} }
} }