From 8d85976ac0de817149f948082a87ab16f9f38756 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Mon, 24 Jun 2024 23:47:55 +0200 Subject: [PATCH] revert savecomposeconfig --- app/Models/Service.php | 40 ++++++++++++++++++++-------------------- config/sentry.php | 2 +- config/version.php | 2 +- versions.json | 2 +- 4 files changed, 23 insertions(+), 23 deletions(-) diff --git a/app/Models/Service.php b/app/Models/Service.php index 9cc3b8287e..05c380a4c1 100644 --- a/app/Models/Service.php +++ b/app/Models/Service.php @@ -840,26 +840,26 @@ public function saveComposeConfigs() $json = Yaml::parse($this->docker_compose); $envs_from_coolify = $this->environment_variables()->get(); - foreach ($json['services'] as $service => $config) { - if (data_get($config, 'environment') === null) { - data_set($json, "services.$service.environment", []); - $envs = collect([]); - } else { - $envs = collect($config['environment']); - } - // $envs->put('COOLIFY_CONTAINER_NAME', "$service-{$this->uuid}"); - foreach ($envs_from_coolify as $env) { - $envs = $envs->map(function ($value) use ($env) { - if (str($value)->startsWith($env->key)) { - return "{$env->key}={$env->real_value}"; - } - - return $value; - }); - } - $envs = $envs->unique(); - data_set($json, "services.$service.environment", $envs->toArray()); - } + // foreach ($json['services'] as $service => $config) { + // if (data_get($config, 'environment') === null) { + // data_set($json, "services.$service.environment", []); + // $envs = collect([]); + // } else { + // $envs = collect($config['environment']); + // } + // // $envs->put('COOLIFY_CONTAINER_NAME', "$service-{$this->uuid}"); + // foreach ($envs_from_coolify as $env) { + // $envs = $envs->map(function ($value) use ($env) { + // if (str($value)->startsWith($env->key)) { + // return "{$env->key}={$env->real_value}"; + // } + + // return $value; + // }); + // } + // $envs = $envs->unique(); + // data_set($json, "services.$service.environment", $envs->toArray()); + // } $this->docker_compose = Yaml::dump($json, 10, 2, Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK); $docker_compose_base64 = base64_encode($this->docker_compose); diff --git a/config/sentry.php b/config/sentry.php index ecd7011659..17e51ddb77 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.303', + 'release' => '4.0.0-beta.304', // 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 708bf7f507..1221a84286 100644 --- a/config/version.php +++ b/config/version.php @@ -1,3 +1,3 @@