Skip to content

Commit 75258f2

Browse files
committed
Prevent generating a kernel_secret in the standalone image if it already exists or is defined through an environment variable
1 parent 435130a commit 75258f2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/Docker/Standalone/InitTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function testKernelSecretGenerated(): void
4040
public function testKernelSecretNotRegeneratedOnRestart(): void
4141
{
4242
$this->filesystem->mkdir(__DIR__ . '/config/secrets');
43-
$this->filesystem->chmod(__DIR__ . '/config/secrets', 0777);
43+
$this->filesystem->chmod(__DIR__ . '/config', 0777, recursive: true);
4444

4545
// Generate kernel secret first
4646
$this->container = (new GenericContainer('dirigent-standalone'))
@@ -74,7 +74,7 @@ public static function kernelSecretEnvVarProvider(): array
7474
public function testKernelSecretNotGeneratedIfEnvVarExists(string $varName, string $varValue): void
7575
{
7676
$this->filesystem->mkdir(__DIR__ . '/config/secrets');
77-
$this->filesystem->chmod(__DIR__ . '/config/secrets', 0777);
77+
$this->filesystem->chmod(__DIR__ . '/config', 0777, recursive: true);
7878

7979
$this->container = (new GenericContainer('dirigent-standalone'))
8080
->withMount(__DIR__ . '/config', '/srv/config')

0 commit comments

Comments
 (0)