Skip to content

Commit 100bbcb

Browse files
committed
Only mount ~/.docker/config.json, not ~/.docker
docker buildx wants to write to ~/.docker/buildx, but since we mount the secret *entirely* (to ~/.docker/buildx), it can not. I think mounting *just* the subpath should work. Follow-up to jupyterhub/repo2docker#1402
1 parent 040c9bb commit 100bbcb

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

binderhub/build.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,11 @@ def get_builder_volumes(self):
448448

449449
if not self.registry_credentials and self.push_secret:
450450
volume_mounts.append(
451-
client.V1VolumeMount(mount_path="/root/.docker", name="docker-config")
451+
client.V1VolumeMount(
452+
mount_path="/root/.docker/config.json",
453+
name="docker-config",
454+
sub_path="config.json",
455+
)
452456
)
453457
volumes.append(
454458
client.V1Volume(

0 commit comments

Comments
 (0)