From 83a29f8d8504fb62bbfee2ad9d680b9d3c560387 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Fri, 26 Apr 2024 09:32:47 +0200 Subject: [PATCH] Refactor parseDockerComposeFile function in shared.php to escape service labels with escapeDollarSign --- bootstrap/helpers/shared.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bootstrap/helpers/shared.php b/bootstrap/helpers/shared.php index 597ecbd29..b2c34900e 100644 --- a/bootstrap/helpers/shared.php +++ b/bootstrap/helpers/shared.php @@ -1268,6 +1268,11 @@ function parseDockerComposeFile(Service|Application $resource, bool $isNew = fal $serviceLabels->push("$removedLabelName=$removedLabel"); } } + if ($serviceLabels->count() > 0) { + $serviceLabels = $serviceLabels->map(function ($value, $key) { + return escapeDollarSign($value); + }); + } $baseName = generateApplicationContainerName($resource, $pull_request_id); $containerName = "$serviceName-$baseName"; if (count($serviceVolumes) > 0) {