diff --git a/composer.lock b/composer.lock index 442734db0f..4fc58cf873 100644 --- a/composer.lock +++ b/composer.lock @@ -3760,16 +3760,16 @@ }, { "name": "utopia-php/detector", - "version": "0.1.0", + "version": "0.1.1", "source": { "type": "git", "url": "https://github.com/utopia-php/detector.git", - "reference": "ddeee9c3e702ae10b3eb53cafe5210a0c4896c94" + "reference": "5dcabbfcf99731f3a37d86b7cb1e93c968baf64b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/detector/zipball/ddeee9c3e702ae10b3eb53cafe5210a0c4896c94", - "reference": "ddeee9c3e702ae10b3eb53cafe5210a0c4896c94", + "url": "https://api.github.com/repos/utopia-php/detector/zipball/5dcabbfcf99731f3a37d86b7cb1e93c968baf64b", + "reference": "5dcabbfcf99731f3a37d86b7cb1e93c968baf64b", "shasum": "" }, "require": { @@ -3799,9 +3799,9 @@ ], "support": { "issues": "https://github.com/utopia-php/detector/issues", - "source": "https://github.com/utopia-php/detector/tree/0.1.0" + "source": "https://github.com/utopia-php/detector/tree/0.1.1" }, - "time": "2025-03-08T16:04:33+00:00" + "time": "2025-03-08T22:25:49+00:00" }, { "name": "utopia-php/domains", diff --git a/docker-compose.yml b/docker-compose.yml index 1cf0af5078..e0a8b8ab3a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -962,7 +962,7 @@ services: hostname: exc1 <<: *x-logging stop_signal: SIGINT - image: openruntimes/executor:0.7.8 + image: openruntimes/executor:0.7.9 restart: unless-stopped networks: - appwrite diff --git a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php index 608c001b70..0e16a0040e 100644 --- a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php +++ b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php @@ -689,9 +689,9 @@ class Builds extends Action throw new \Exception('Build size should be less than ' . number_format($buildSizeLimit / 1048576, 2) . ' MBs.'); } - if ($resource->getCollection() === 'sites' && empty($resource->getAttribute('adapter'))) { + if ($resource->getCollection() === 'sites' && empty($resource->getAttribute('adapter', ''))) { // TODO: Refactor with structured command in future, using utopia library (CLI) - $listFilesCommand = "cd /usr/local/build && cd " . \escapeshellarg($resource->getAttribute('outputDirectory')) . " && find . -name 'node_modules' -prune -o -type f -print"; + $listFilesCommand = "cd /usr/local/build && cd " . \escapeshellarg($resource->getAttribute('outputDirectory', './')) . " && find . -name 'node_modules' -prune -o -type f -print"; $command = $executor->createCommand( deploymentId: $deployment->getId(), projectId: $project->getId(), diff --git a/tests/e2e/Services/Sites/SitesCustomServerTest.php b/tests/e2e/Services/Sites/SitesCustomServerTest.php index 07a9fcf46b..c5d38c1897 100644 --- a/tests/e2e/Services/Sites/SitesCustomServerTest.php +++ b/tests/e2e/Services/Sites/SitesCustomServerTest.php @@ -2068,6 +2068,14 @@ class SitesCustomServerTest extends Scope $domain = $this->getDeploymentDomain($deploymentId); $this->assertNotEmpty($domain); + + // Create second deployment to make first one a preview + $deploymentId = $this->setupDeployment($siteId, [ + 'code' => $this->packageSite('static'), + 'activate' => true + ]); + $this->assertNotEmpty($deploymentId); + $proxyClient = new Client(); $proxyClient->setEndpoint('http://' . $domain);