Skip to content

Commit ddec230

Browse files
authored
Merge pull request #441 from jolicode/fix-bake-fs-entitlement
Grant bake read access to the repository root in docker:push
2 parents eacd162 + 7cf30dd commit ddec230

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎.castor/docker.php‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,10 @@ function push(bool $dryRun = false): void
562562
->withWorkingDirectory(variable('root_dir') . '/infrastructure/docker')
563563
;
564564

565-
$command = ['docker', 'buildx', 'bake'];
565+
// Additional build contexts may live outside of the compose files directory (e.g. the
566+
// repository root): grant bake the read access explicitly, or it asks for it interactively
567+
// (and waits forever in the CI, castor running it with a pty)
568+
$command = ['docker', 'buildx', 'bake', '--allow=fs.read=' . variable('root_dir')];
566569

567570
foreach ($c['docker_compose_files'] as $file) {
568571
$command[] = '-f';

0 commit comments

Comments
 (0)