diff --git a/bootstrap/helpers/docker.php b/bootstrap/helpers/docker.php index a70c85a72..a087c92c5 100644 --- a/bootstrap/helpers/docker.php +++ b/bootstrap/helpers/docker.php @@ -8,6 +8,7 @@ use Illuminate\Support\Collection; use Illuminate\Support\Str; use Spatie\Url\Url; +use Visus\Cuid2\Cuid2; function getCurrentApplicationContainerStatus(Server $server, int $id, ?int $pullRequestId = null, ?bool $includePullrequests = false): Collection { @@ -272,7 +273,7 @@ function fqdnLabelsForCaddy(string $network, string $uuid, Collection $domains, } return $labels->sort(); } -function fqdnLabelsForTraefik(string $uuid, Collection $domains, bool $is_force_https_enabled = false, $onlyPort = null, ?Collection $serviceLabels = null, ?bool $is_gzip_enabled = true, ?bool $is_stripprefix_enabled = true, ?string $service_name = null) +function fqdnLabelsForTraefik(string $uuid, Collection $domains, bool $is_force_https_enabled = false, $onlyPort = null, ?Collection $serviceLabels = null, ?bool $is_gzip_enabled = true, ?bool $is_stripprefix_enabled = true, ?string $service_name = null, bool $generate_unique_uuid = false) { $labels = collect([]); $labels->push('traefik.enable=true'); @@ -313,7 +314,9 @@ function fqdnLabelsForTraefik(string $uuid, Collection $domains, bool $is_force_ } foreach ($domains as $loop => $domain) { try { - // $uuid = new Cuid2(7); + if ($generate_unique_uuid) { + $uuid = new Cuid2(7); + } $url = Url::fromString($domain); $host = $url->getHost(); $path = $url->getPath(); diff --git a/bootstrap/helpers/shared.php b/bootstrap/helpers/shared.php index b2c34900e..0161b8c95 100644 --- a/bootstrap/helpers/shared.php +++ b/bootstrap/helpers/shared.php @@ -1620,7 +1620,8 @@ function parseDockerComposeFile(Service|Application $resource, bool $isNew = fal $serviceLabels = $serviceLabels->merge(fqdnLabelsForTraefik( uuid: $resource->uuid, domains: $fqdns, - serviceLabels: $serviceLabels + serviceLabels: $serviceLabels, + generate_unique_uuid: $resource->build_pack === 'dockercompose' )); $serviceLabels = $serviceLabels->merge(fqdnLabelsForCaddy( network: $resource->destination->network, diff --git a/resources/views/livewire/project/shared/get-logs.blade.php b/resources/views/livewire/project/shared/get-logs.blade.php index ad4e74e0c..5faf9bccd 100644 --- a/resources/views/livewire/project/shared/get-logs.blade.php +++ b/resources/views/livewire/project/shared/get-logs.blade.php @@ -77,7 +77,7 @@ class="fixed top-4 right-16" x-on:click="toggleScroll"> -