From 24f923e88e930dbb701156123e9be2cf105cc4fa Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Tue, 14 May 2024 12:19:33 +0200 Subject: [PATCH] fix: docker compose dependencies for pr previews --- bootstrap/helpers/shared.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bootstrap/helpers/shared.php b/bootstrap/helpers/shared.php index b93b0ec3d..e34a58e06 100644 --- a/bootstrap/helpers/shared.php +++ b/bootstrap/helpers/shared.php @@ -1665,6 +1665,9 @@ function parseDockerComposeFile(Service|Application $resource, bool $isNew = fal }); if ($pull_request_id !== 0) { $services->each(function ($service, $serviceName) use ($pull_request_id, $services) { + $service->depends_on = $service->depends_on->map(function ($dependency) use ($pull_request_id) { + return $dependency . "-pr-$pull_request_id"; + }); $services[$serviceName . "-pr-$pull_request_id"] = $service; data_forget($services, $serviceName); });