-
Notifications
You must be signed in to change notification settings - Fork 289
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Registry authentication with credential stores/helpers is not available while cloning a repo to a volume #7184
Comments
@chrmarti @bamurtaugh This originated from a Twitter conversation for reference (https://twitter.com/ForSpareParts/status/1569746805797322752) and affects the "continue on" flow as well. To resolve, we'd likely need to inspect docker config and if |
Thanks for flagging @Chuxel. Just to ensure I understand, what do we mean by "Continue on" in this case? |
@bamurtaugh This relates to the continue on experience in vscode.dev that was designed to open up in a container volume. The "Remote - Containers | Open" badge is the same thing. If the repo just has a Dockerfile that references a public image (or just refs a public image directly), there's no issue - its pre-built private images that require a docker sign in to access. Given the recommendation to pre-build images for perf (and how easy it is to do with GHCR and Actions), that's problematic. So, it affects Remote - Containers "Clone Repository in Container Volume" locally, vscode.dev => Remote - Containers, and README badge => Remote - Containers. I'm not sure if we originally pulled the image first on the host which avoided this and some refactoring caused a regression, or if this is a gap. |
Nitpick -- it'd be great if we had the ability to always pull before bootstrapping, even if the image is already available. I build my devcontainer image in CI, and ideally users would just get the newest thing by default whenever they rebuild. The way I'm planning to handle this right now is to have the devcontainer itself pull the newest version of its own image upon startup, such that the next rebuild will always be up-to-date, but being able to pull at the time of container creation would be even better. |
I have the same problem with VS Code 1.74.1 on Mac OS 13.1. The use case is also exactly the same (using a container from a private ghcr registry as a base for a devcontainer, and wanting to use the "clone in volume" functionality for better performance). |
Adding a Docker credential helper to fix this. This will also be available in regular dev containers. |
This is exciting! How will it work -- is it effectively a proxy to the host's credential helpers? Also, when will it be released? |
I'm adding a "credsStore" to the temporary container's |
Published with Dev Containers 0.269.0-pre-release. Let me know if it works for you, thanks! |
Thanks for these efforts! I have been trying to test private images with the preview version of the extension, but I'm having trouble. My // For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/docker-existing-dockerfile
{
"name": "with dockerfile",
"build": {
// Sets the run context to one level up instead of the .devcontainer folder.
"context": "..",
// Update the 'dockerFile' property if you aren't using the standard 'Dockerfile' filename.
"dockerfile": "./Dockerfile"
}
} The Opening this devcontainer with the regular "Open in Dev Container" works. Opening a devcontainer with "Clone repository in container volume" works when the dockerfile contains "FROM alpine" (a public image). Opening the devcontainer with "Clone repository in container volume" does not work when the image referred to by the dockerfile is in a private registry. The log output is below, it seems to be failing when trying to inspect the image from the private registry. The Dev Containers extension is v0.269.0 (in preview, referred to above). VS Code version info:
[2023-01-11T14:43:21.211Z] Dev Containers 0.269.0 in VS Code 1.74.3 (97dec172d3256f8ca4bfb2143f3f76b503ca0534).
[2023-01-11T14:43:21.211Z] Start: Resolving Remote
[2023-01-11T14:43:21.218Z] Start: Check Docker is running
[2023-01-11T14:43:21.218Z] Start: Run: docker version --format {{.Server.APIVersion}}
[2023-01-11T14:43:21.267Z] Stop (49 ms): Run: docker version --format {{.Server.APIVersion}}
[2023-01-11T14:43:21.267Z] Server API version: 1.41
[2023-01-11T14:43:21.268Z] Stop (50 ms): Check Docker is running
[2023-01-11T14:43:21.268Z] Start: Run: docker volume ls -q
[2023-01-11T14:43:21.293Z] Stop (25 ms): Run: docker volume ls -q
[2023-01-11T14:43:21.293Z] Start: Run: docker volume create --label vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --label vsch.local.repository.unique=true --label vsch.local.repository.branch=private-image devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9
[2023-01-11T14:43:21.324Z] Stop (31 ms): Run: docker volume create --label vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --label vsch.local.repository.unique=true --label vsch.local.repository.branch=private-image devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9
[2023-01-11T14:43:21.325Z] Start: Run: docker build -f /var/folders/fz/fhrx3nn51x72zbm9b6q7xxtm0000gn/T/vsch/bootstrap-image/0.269.0/bootstrap.Dockerfile -t vsc-volume-bootstrap /var/folders/fz/fhrx3nn51x72zbm9b6q7xxtm0000gn/T/vsch/bootstrap-image/0.269.0
[2023-01-11T14:43:21.642Z] [+] Building 0.0s (0/1)
[2023-01-11T14:43:21.793Z] [+] Building 0.2s (2/3)
=> [internal] load build definition from bootstrap.Dockerfile 0.0s
=> => transferring dockerfile: 47B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for mcr.microsoft.com/devcontainers/base:0-a 0.1s
[2023-01-11T14:43:21.912Z] [+] Building 0.3s (3/3)
=> [internal] load build definition from bootstrap.Dockerfile 0.0s
=> => transferring dockerfile: 47B 0.0s
=> [internal] load .dockerignore 0.0s
[2023-01-11T14:43:21.912Z] => => transferring context: 2B 0.0s
=> [internal] load metadata for mcr.microsoft.com/devcontainers/base:0-a 0.2s
[2023-01-11T14:43:21.927Z] [+] Building 0.3s (10/10) FINISHED
=> [internal] load build definition from bootstrap.Dockerfile 0.0s
=> => transferring dockerfile: 47B 0.0s
[2023-01-11T14:43:21.928Z] => [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for mcr.microsoft.com/devcontainers/base:0-a 0.2s
=> [internal] load build context 0.0s
=> => transferring context: 5.90kB 0.0s
=> [1/5] FROM mcr.microsoft.com/devcontainers/base:0-alpine-3.16@sha256: 0.0s
=> CACHED [2/5] RUN echo "@old https://dl-cdn.alpinelinux.org/alpine/v3. 0.0s
=> CACHED [3/5] RUN apk add --no-cache nodejs python3 npm make g++ 0.0s
=> CACHED [4/5] RUN cd && npm i node-pty 0.0s
=> CACHED [5/5] COPY .vscode-remote-containers /root/.vscode-remote-cont 0.0s
=> exporting to image 0.0s
=> => exporting layers
[2023-01-11T14:43:21.928Z] 0.0s
=> => writing image sha256:ed12442b5b138d46854d65f2dc57585948bb0799d1109 0.0s
=> => naming to docker.io/library/vsc-volume-bootstrap 0.0s
[2023-01-11T14:43:21.929Z] Stop (604 ms): Run: docker build -f /var/folders/fz/fhrx3nn51x72zbm9b6q7xxtm0000gn/T/vsch/bootstrap-image/0.269.0/bootstrap.Dockerfile -t vsc-volume-bootstrap /var/folders/fz/fhrx3nn51x72zbm9b6q7xxtm0000gn/T/vsch/bootstrap-image/0.269.0
[2023-01-11T14:43:21.929Z] Cloning Github repository: josteinbf/devcontainer-testrepo into /workspaces/devcontainer-testrepo
[2023-01-11T14:43:21.930Z] Start: Run: docker run -d --mount type=volume,src=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9,dst=/workspaces -v /var/run/docker.sock:/var/run/docker.sock vsc-volume-bootstrap sleep infinity
[2023-01-11T14:43:22.209Z] Stop (279 ms): Run: docker run -d --mount type=volume,src=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9,dst=/workspaces -v /var/run/docker.sock:/var/run/docker.sock vsc-volume-bootstrap sleep infinity
[2023-01-11T14:43:22.209Z] Start: Run in container: /bin/sh
[2023-01-11T14:43:22.211Z] Start: Launching Dev Containers helper.
[2023-01-11T14:43:22.211Z] ssh-agent: SSH_AUTH_SOCK in container (/tmp/vscode-ssh-auth-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.sock) forwarded to local host (/private/tmp/com.apple.launchd.HffS6Gwc8C/Listeners).
[2023-01-11T14:43:22.211Z] X11 forwarding: DISPLAY not set on host.
[2023-01-11T14:43:22.211Z] Start: Run: gpgconf --list-dir agent-extra-socket
[2023-01-11T14:43:22.221Z] Stop (10 ms): Run: gpgconf --list-dir agent-extra-socket
[2023-01-11T14:43:22.221Z] /Users/jostein/.gnupg/S.gpg-agent.extra
[2023-01-11T14:43:22.222Z]
[2023-01-11T14:43:22.222Z] Start: Run in container: gpgconf --list-dir agent-socket
[2023-01-11T14:43:22.280Z] /root/.gnupg/S.gpg-agent
[2023-01-11T14:43:22.280Z]
[2023-01-11T14:43:22.280Z] Stop (58 ms): Run in container: gpgconf --list-dir agent-socket
[2023-01-11T14:43:22.280Z] Start: Run in container: gpgconf --list-dir homedir
[2023-01-11T14:43:22.282Z] /root/.gnupg
[2023-01-11T14:43:22.282Z]
[2023-01-11T14:43:22.282Z] Stop (2 ms): Run in container: gpgconf --list-dir homedir
[2023-01-11T14:43:22.282Z] Start: Run in container: ls '/root/.gnupg/private-keys-v1.d' 2>/dev/null
[2023-01-11T14:43:22.284Z]
[2023-01-11T14:43:22.285Z]
[2023-01-11T14:43:22.285Z] Exit code 2
[2023-01-11T14:43:22.285Z] Stop (3 ms): Run in container: ls '/root/.gnupg/private-keys-v1.d' 2>/dev/null
[2023-01-11T14:43:22.285Z] Start: Run in container: mkdir -p -m 700 '/root/.gnupg'
[2023-01-11T14:43:22.287Z]
[2023-01-11T14:43:22.287Z]
[2023-01-11T14:43:22.287Z] Stop (2 ms): Run in container: mkdir -p -m 700 '/root/.gnupg'
[2023-01-11T14:43:22.287Z] Start: Run in container: command -v docker >/dev/null 2>&1
[2023-01-11T14:43:22.287Z] Start: Run: gpgconf --list-dir homedir
[2023-01-11T14:43:22.288Z]
[2023-01-11T14:43:22.288Z]
[2023-01-11T14:43:22.288Z] Stop (1 ms): Run in container: command -v docker >/dev/null 2>&1
[2023-01-11T14:43:22.288Z] Start: Run in container: /bin/sh
[2023-01-11T14:43:22.289Z] Stop (78 ms): Launching Dev Containers helper.
[2023-01-11T14:43:22.289Z] Start: Run in container: echo ~
[2023-01-11T14:43:22.294Z] Stop (7 ms): Run: gpgconf --list-dir homedir
[2023-01-11T14:43:22.294Z] /Users/jostein/.gnupg
[2023-01-11T14:43:22.294Z]
[2023-01-11T14:43:22.295Z] Start: Run in container: gpgconf --list-dir homedir
[2023-01-11T14:43:22.296Z] /root/.gnupg
[2023-01-11T14:43:22.296Z]
[2023-01-11T14:43:22.296Z] Stop (1 ms): Run in container: gpgconf --list-dir homedir
[2023-01-11T14:43:22.297Z] Start: Run in container: # Test for /root/.gnupg/pubring.kbx and gpg
[2023-01-11T14:43:22.299Z]
[2023-01-11T14:43:22.299Z]
[2023-01-11T14:43:22.299Z] Stop (2 ms): Run in container: # Test for /root/.gnupg/pubring.kbx and gpg
[2023-01-11T14:43:22.299Z] Start: Run in container: # Copy /Users/jostein/.gnupg/pubring.kbx to /root/.gnupg/pubring.kbx
[2023-01-11T14:43:22.302Z]
[2023-01-11T14:43:22.302Z]
[2023-01-11T14:43:22.302Z] Stop (3 ms): Run in container: # Copy /Users/jostein/.gnupg/pubring.kbx to /root/.gnupg/pubring.kbx
[2023-01-11T14:43:22.303Z] Start: Run in container: # Test for /root/.gnupg/trustdb.gpg and gpg
[2023-01-11T14:43:22.304Z]
[2023-01-11T14:43:22.305Z]
[2023-01-11T14:43:22.305Z] Stop (2 ms): Run in container: # Test for /root/.gnupg/trustdb.gpg and gpg
[2023-01-11T14:43:22.305Z] Start: Run in container: # Copy /Users/jostein/.gnupg/trustdb.gpg to /root/.gnupg/trustdb.gpg
[2023-01-11T14:43:22.308Z]
[2023-01-11T14:43:22.308Z]
[2023-01-11T14:43:22.308Z] Stop (3 ms): Run in container: # Copy /Users/jostein/.gnupg/trustdb.gpg to /root/.gnupg/trustdb.gpg
[2023-01-11T14:43:22.308Z] Start: Run: gpg-connect-agent updatestartuptty /bye
[2023-01-11T14:43:22.337Z] Stop (29 ms): Run: gpg-connect-agent updatestartuptty /bye
[2023-01-11T14:43:22.372Z] /root
[2023-01-11T14:43:22.372Z]
[2023-01-11T14:43:22.372Z] Stop (83 ms): Run in container: echo ~
[2023-01-11T14:43:22.372Z] Start: Run in container: cat <<'EOF-/tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js' >/tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js
[2023-01-11T14:43:22.375Z]
[2023-01-11T14:43:22.375Z]
[2023-01-11T14:43:22.375Z] Stop (3 ms): Run in container: cat <<'EOF-/tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js' >/tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js
[2023-01-11T14:43:22.375Z] Start: Run in container: mkdir -p /usr/local/bin && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2' >/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2
[2023-01-11T14:43:22.379Z]
[2023-01-11T14:43:22.379Z]
[2023-01-11T14:43:22.379Z] Stop (4 ms): Run in container: mkdir -p /usr/local/bin && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2' >/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2
[2023-01-11T14:43:22.379Z] Start: Run in container: chmod +x /usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2
[2023-01-11T14:43:22.381Z]
[2023-01-11T14:43:22.381Z]
[2023-01-11T14:43:22.381Z] Stop (2 ms): Run in container: chmod +x /usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2
[2023-01-11T14:43:22.381Z] Start: Run in container: cat ~/.docker/config.json || echo "{
[2023-01-11T14:43:22.383Z] {
}
[2023-01-11T14:43:22.383Z] cat: /root/.docker/config.json: No such file or directory
[2023-01-11T14:43:22.383Z] Stop (2 ms): Run in container: cat ~/.docker/config.json || echo "{
[2023-01-11T14:43:22.384Z] Start: Run in container: mkdir -p ~/.docker && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2' >~/.docker/config.json
[2023-01-11T14:43:22.387Z]
[2023-01-11T14:43:22.387Z]
[2023-01-11T14:43:22.387Z] Stop (3 ms): Run in container: mkdir -p ~/.docker && cat <<'EOF-/usr/local/bin/docker-credential-dev-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2' >~/.docker/config.json
[2023-01-11T14:43:22.387Z] Start: Run in container: cat <<'EOF-/tmp/vscode-remote-containers-server-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js' >/tmp/vscode-remote-containers-server-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js_1673448202387
[2023-01-11T14:43:22.400Z]
[2023-01-11T14:43:22.400Z]
[2023-01-11T14:43:22.401Z] Stop (14 ms): Run in container: cat <<'EOF-/tmp/vscode-remote-containers-server-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js' >/tmp/vscode-remote-containers-server-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js_1673448202387
[2023-01-11T14:43:22.402Z] Start: Run in container: # Test for /root/.gitconfig and git
[2023-01-11T14:43:22.404Z]
[2023-01-11T14:43:22.404Z]
[2023-01-11T14:43:22.404Z] Stop (2 ms): Run in container: # Test for /root/.gitconfig and git
[2023-01-11T14:43:22.404Z] Start: Run in container: # Copy /Users/jostein/.gitconfig to /root/.gitconfig
[2023-01-11T14:43:22.407Z]
[2023-01-11T14:43:22.407Z]
[2023-01-11T14:43:22.407Z] Stop (3 ms): Run in container: # Copy /Users/jostein/.gitconfig to /root/.gitconfig
[2023-01-11T14:43:22.408Z] Start: Run in container: command -v git >/dev/null 2>&1 && git config --global --replace-all credential.helper '!f() { node /tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js git-credential-helper $*; }; f' || true
[2023-01-11T14:43:22.411Z]
[2023-01-11T14:43:22.411Z]
[2023-01-11T14:43:22.411Z] Stop (3 ms): Run in container: command -v git >/dev/null 2>&1 && git config --global --replace-all credential.helper '!f() { node /tmp/vscode-remote-containers-a1d47fae6e1ac47db57e764d9f14cbee0eb8cdf2.js git-credential-helper $*; }; f' || true
[2023-01-11T14:43:22.412Z] Start: Run in container: # Test for /root/.ssh/known_hosts and ssh
[2023-01-11T14:43:22.414Z]
[2023-01-11T14:43:22.414Z]
[2023-01-11T14:43:22.414Z] Stop (2 ms): Run in container: # Test for /root/.ssh/known_hosts and ssh
[2023-01-11T14:43:22.414Z] Start: Run in container: # Copy /Users/jostein/.ssh/known_hosts to /root/.ssh/known_hosts
[2023-01-11T14:43:22.417Z]
[2023-01-11T14:43:22.417Z]
[2023-01-11T14:43:22.417Z] Stop (3 ms): Run in container: # Copy /Users/jostein/.ssh/known_hosts to /root/.ssh/known_hosts
[2023-01-11T14:43:22.488Z] Start: Run in container: git clone --depth 1 --branch private-image git@github.com:josteinbf/devcontainer-testrepo.git .
[2023-01-11T14:43:22.656Z] Cloning into '.'...
[2023-01-11T14:43:24.489Z] remote: Enumerating objects: 5, done.
remote: Counting objects: 20% (1/5)
remote: Counting objects: 40% (2/5)
remote: Counting objects: 60% (3/5)
remote: Counting objects: 80% (4/5)
remote: Counting objects: 100% (5/5)
remote: Counting objects: 100% (5/5), done.
remote: Compressing objects: 33% (1/3)
remote: Compressing objects: 66% (2/3)
remote: Compressing objects: 100% (3/3)
remote: Compressing objects: 100% (3/3), done.
remote: Total 5 (delta 0), reused 5 (delta 0), pack-reused 0
[2023-01-11T14:43:24.491Z] Receiving objects: 20% (1/5)
Receiving objects: 40% (2/5)
Receiving objects: 60% (3/5)
Receiving objects: 80% (4/5)
Receiving objects: 100% (5/5)
Receiving objects: 100% (5/5), done.
[2023-01-11T14:43:24.618Z] Stop (2130 ms): Run in container: git clone --depth 1 --branch private-image git@github.com:josteinbf/devcontainer-testrepo.git .
[2023-01-11T14:43:24.703Z] Start: Run in container: cat /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json 2>/dev/null
[2023-01-11T14:43:24.709Z] Stop (6 ms): Run in container: cat /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json 2>/dev/null
[2023-01-11T14:43:24.709Z] Start: Run in container: cat /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json 2>/dev/null
[2023-01-11T14:43:24.712Z] Stop (3 ms): Run in container: cat /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json 2>/dev/null
[2023-01-11T14:43:24.713Z] Start: Run in container: test -e "/Users/jostein" || (mkdir -p "$(dirname "/Users/jostein")" && ln -s ~ "/Users/jostein")
[2023-01-11T14:43:24.717Z]
[2023-01-11T14:43:24.717Z]
[2023-01-11T14:43:24.717Z] Stop (4 ms): Run in container: test -e "/Users/jostein" || (mkdir -p "$(dirname "/Users/jostein")" && ln -s ~ "/Users/jostein")
[2023-01-11T14:43:24.718Z] Start: Run in container: cat <<'EOF-/tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json' >/tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json_1673448204718
[2023-01-11T14:43:24.721Z]
[2023-01-11T14:43:24.721Z]
[2023-01-11T14:43:24.721Z] Stop (3 ms): Run in container: cat <<'EOF-/tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json' >/tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json_1673448204718
[2023-01-11T14:43:24.721Z] Start: Run in container: docker volume ls -q
[2023-01-11T14:43:24.863Z] Stop (142 ms): Run in container: docker volume ls -q
[2023-01-11T14:43:25.040Z] Start: Run in container: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo --filter label=vsch.quality=stable
[2023-01-11T14:43:25.131Z] Stop (91 ms): Run in container: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo --filter label=vsch.quality=stable
[2023-01-11T14:43:25.131Z] Start: Run in container: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo
[2023-01-11T14:43:25.225Z] Stop (94 ms): Run in container: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo
[2023-01-11T14:43:25.361Z] Start: Run in container: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js up --workspace-folder /workspaces/devcontainer-testrepo --workspace-mount-consistency cached --id-label vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --id-label vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --id-label vsch.local.repository.folder=devcontainer-testrepo --log-level debug --log-format json --config /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root true --terminal-columns 94 --terminal-rows 94
[2023-01-11T14:43:25.619Z] (node:161) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
[2023-01-11T14:43:25.619Z] (Use `node --trace-deprecation ...` to show where the warning was created)
[2023-01-11T14:43:25.622Z] @devcontainers/cli 0.26.0. Node.js v16.17.1. linux 5.15.49-linuxkit arm64.
[2023-01-11T14:43:25.622Z] Start: Run: docker buildx version
[2023-01-11T14:43:25.704Z] Stop (82 ms): Run: docker buildx version
[2023-01-11T14:43:25.704Z] github.com/docker/buildx v0.8.2 6224def4dd2c3d347eee19db595348c50d7cb491
[2023-01-11T14:43:25.704Z]
[2023-01-11T14:43:25.704Z] Start: Resolving Remote
[2023-01-11T14:43:25.707Z] Start: Run: git rev-parse --show-cdup
[2023-01-11T14:43:25.710Z] Stop (3 ms): Run: git rev-parse --show-cdup
[2023-01-11T14:43:25.711Z] Start: Run: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo
[2023-01-11T14:43:25.737Z] Stop (26 ms): Run: docker ps -q -a --filter label=vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --filter label=vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --filter label=vsch.local.repository.folder=devcontainer-testrepo
[2023-01-11T14:43:25.740Z] Start: Run: docker inspect --type image ghcr.io/kron-as/jobs:4bcbe999
[2023-01-11T14:43:25.778Z] Stop (38 ms): Run: docker inspect --type image ghcr.io/kron-as/jobs:4bcbe999
[2023-01-11T14:43:25.780Z] local container features stored at: /root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/node_modules/vscode-dev-containers/container-features
[2023-01-11T14:43:25.781Z] Start: Run: tar --no-same-owner -x -f -
[2023-01-11T14:43:25.810Z] Stop (29 ms): Run: tar --no-same-owner -x -f -
[2023-01-11T14:43:25.812Z] Start: Run: docker buildx build --load --build-arg BUILDKIT_INLINE_CACHE=1 -f /tmp/devcontainercli-root/container-features/0.26.0-1673448205779/Dockerfile-with-features -t vsc-devcontainer-testrepo-f4dbc507ab174f558aaac4c84f0fbd29 --target dev_containers_target_stage --build-arg _DEV_CONTAINERS_BASE_IMAGE=dev_container_auto_added_stage_label /workspaces/devcontainer-testrepo
[2023-01-11T14:43:26.039Z]
[2023-01-11T14:43:26.039Z] [+] Building 0.0s (0/0)
[2023-01-11T14:43:26.155Z] [+] Building 0.0s (0/1)
[2023-01-11T14:43:26.306Z] [+] Building 0.2s (2/3)
=> [internal] load build definition from Dockerfile-with-features 0.0s
=> => transferring dockerfile: 240B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for ghcr.io/kron-as/jobs:4bcbe999 0.1s
[2023-01-11T14:43:26.457Z] [+] Building 0.3s (2/3)
=> [internal] load build definition from Dockerfile-with-features 0.0s
=> => transferring dockerfile: 240B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for ghcr.io/kron-as/jobs:4bcbe999 0.2s
[2023-01-11T14:43:26.593Z] Container server: {
message: 'write EPIPE',
name: 'Error',
stack: 'Error: write EPIPE\n' +
'\tat afterWriteDispatched (node:internal/stream_base_commons:160:15)\n' +
'\tat writeGeneric (node:internal/stream_base_commons:151:3)\n' +
'\tat Socket._writeGeneric (node:net:795:11)\n' +
'\tat Socket._write (node:net:807:8)\n' +
'\tat writeOrBuffer (node:internal/streams/writable:389:12)\n' +
'\tat _write (node:internal/streams/writable:330:10)\n' +
'\tat Writable.write (node:internal/streams/writable:334:10)\n' +
'\tat /Users/jostein/.vscode/extensions/ms-vscode-remote.remote-containers-0.269.0/dist/extension/extension.js:87:219\n' +
'\tat new Promise (<anonymous>)\n' +
'\tat Fe (/Users/jostein/.vscode/extensions/ms-vscode-remote.remote-containers-0.269.0/dist/extension/extension.js:86:1504)\n' +
'\tat async vk (/Users/jostein/.vscode/extensions/ms-vscode-remote.remote-containers-0.269.0/dist/extension/extension.js:67:709)\n' +
'\tat async yk (/Users/jostein/.vscode/extensions/ms-vscode-remote.remote-containers-0.269.0/dist/extension/extension.js:67:79)\n' +
'\tat async Object.rpc (/Users/jostein/.vscode/extensions/ms-vscode-remote.remote-containers-0.269.0/dist/extension/extension.js:83:901)'
}
[2023-01-11T14:43:26.608Z] [+] Building 0.5s (2/3)
=> [internal] load build definition from Dockerfile-with-features 0.0s
=> => transferring dockerfile: 240B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [internal] load metadata for ghcr.io/kron-as/jobs:4bcbe999 0.4s
[2023-01-11T14:43:26.624Z] [+] Building 0.5s (3/3) FINISHED
=> [internal] load build definition from Dockerfile-with-features 0.0s
=> => transferring dockerfile: 240B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> ERROR [internal] load metadata for ghcr.io/kron-as/jobs:4bcbe999 0.4s
------
> [internal] load metadata for ghcr.io/kron-as/jobs:4bcbe999:
------
[2023-01-11T14:43:26.625Z] error: failed to solve: rpc error: code = Unknown desc = failed to solve with frontend dockerfile.v0: failed to create LLB definition: rpc error: code = Unknown desc = error getting credentials - err: exit status 255, out: ``
[2023-01-11T14:43:26.632Z] Stop (820 ms): Run: docker buildx build --load --build-arg BUILDKIT_INLINE_CACHE=1 -f /tmp/devcontainercli-root/container-features/0.26.0-1673448205779/Dockerfile-with-features -t vsc-devcontainer-testrepo-f4dbc507ab174f558aaac4c84f0fbd29 --target dev_containers_target_stage --build-arg _DEV_CONTAINERS_BASE_IMAGE=dev_container_auto_added_stage_label /workspaces/devcontainer-testrepo
[2023-01-11T14:43:26.632Z] Error: Command failed: docker buildx build --load --build-arg BUILDKIT_INLINE_CACHE=1 -f /tmp/devcontainercli-root/container-features/0.26.0-1673448205779/Dockerfile-with-features -t vsc-devcontainer-testrepo-f4dbc507ab174f558aaac4c84f0fbd29 --target dev_containers_target_stage --build-arg _DEV_CONTAINERS_BASE_IMAGE=dev_container_auto_added_stage_label /workspaces/devcontainer-testrepo
[2023-01-11T14:43:26.632Z] at Zne (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1866:1635)
[2023-01-11T14:43:26.632Z] at processTicksAndRejections (node:internal/process/task_queues:96:5)
[2023-01-11T14:43:26.633Z] at async EF (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1865:1963)
[2023-01-11T14:43:26.633Z] at async x7 (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1865:901)
[2023-01-11T14:43:26.633Z] at async oie (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1871:2093)
[2023-01-11T14:43:26.633Z] at async qf (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1871:3239)
[2023-01-11T14:43:26.633Z] at async Mse (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1995:16211)
[2023-01-11T14:43:26.633Z] at async Lse (/root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js:1995:15965)
[2023-01-11T14:43:26.642Z] Stop (1281 ms): Run in container: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js up --workspace-folder /workspaces/devcontainer-testrepo --workspace-mount-consistency cached --id-label vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --id-label vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --id-label vsch.local.repository.folder=devcontainer-testrepo --log-level debug --log-format json --config /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root true --terminal-columns 94 --terminal-rows 94
[2023-01-11T14:43:26.643Z] Exit code 1
[2023-01-11T14:43:26.645Z] Command failed: node /root/.vscode-remote-containers/dist/dev-containers-cli-0.269.0/dist/spec-node/devContainersSpecCLI.js up --workspace-folder /workspaces/devcontainer-testrepo --workspace-mount-consistency cached --id-label vsch.local.repository=git@github.com:josteinbf/devcontainer-testrepo.git/tree/private-image --id-label vsch.local.repository.volume=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9 --id-label vsch.local.repository.folder=devcontainer-testrepo --log-level debug --log-format json --config /workspaces/devcontainer-testrepo/.devcontainer/devcontainer.json --override-config /tmp/devcontainer-e034eadb-3630-4b45-9464-ceab104929e1.json --default-user-env-probe loginInteractiveShell --mount type=volume,source=devcontainer-testrepo-private-image-2eb59be13b4a008c6f9a1fc9988aa3e9,target=/workspaces,external=true --mount type=volume,source=vscode,target=/vscode,external=true --skip-post-create --update-remote-user-uid-default off --mount-workspace-git-root true --terminal-columns 94 --terminal-rows 94
[2023-01-11T14:43:26.645Z] Exit code 1
[2023-01-11T14:43:24.618Z] Start: Run in container: git config remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
[2023-01-11T14:43:24.777Z] Stop (159 ms): Run in container: git config remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
[2023-01-11T14:43:24.777Z] Start: Run in container: git fetch --unshallow --tags
[2023-01-11T14:43:27.016Z] remote: Enumerating objects: 12, done.
remote: Counting objects: 8% (1/12)
remote: Counting objects: 16% (2/12)
remote: Counting objects: 25% (3/12)
remote: Counting objects: 33% (4/12)
remote: Counting objects: 41% (5/12)
remote: Counting objects: 50% (6/12)
remote: Counting objects: 58% (7/12)
remote: Counting objects: 66% (8/12)
remote: Counting objects: 75% (9/12)
remote: Counting objects: 83% (10/12)
remote: Counting objects: 91% (11/12)
remote: Counting objects: 100% (12/12)
remote: Counting objects: 100% (12/12), done.
remote: Compressing objects: 25% (1/4)
remote: Compressing objects: 50% (2/4)
remote: Compressing objects: 75% (3/4)
remote: Compressing objects: 100% (4/4)
remote: Compressing objects: 100% (4/4), done.
remote: Total 8 (delta 1), reused 7 (delta 0), pack-reused 0
[2023-01-11T14:43:27.019Z] Unpacking objects: 12% (1/8)
[2023-01-11T14:43:27.021Z] Unpacking objects: 25% (2/8)
Unpacking objects: 37% (3/8)
Unpacking objects: 50% (4/8)
[2023-01-11T14:43:27.021Z] Unpacking objects: 62% (5/8)
Unpacking objects: 75% (6/8)
Unpacking objects: 87% (7/8)
[2023-01-11T14:43:27.021Z] Unpacking objects: 100% (8/8)
Unpacking objects: 100% (8/8), 840 bytes | 280.00 KiB/s, done.
[2023-01-11T14:43:27.148Z] From github.com:josteinbf/devcontainer-testrepo
* [new branch] josteinbf/private-image -> origin/josteinbf/private-image
* [new branch] master -> origin/master
* [new branch] public-image -> origin/public-image
[2023-01-11T14:43:27.152Z] Stop (2375 ms): Run in container: git fetch --unshallow --tags
[2023-01-11T14:43:27.153Z] Start: Run: docker rm -f 2320bdc81bd2a00b85e499e4a0cbf72a92f3ca310a34e98207c04d28c67cbd52
[2023-01-11T14:43:27.206Z] Stop (4997 ms): Run in container: /bin/sh
[2023-01-11T14:43:27.210Z] Stop (4922 ms): Run in container: /bin/sh
[2023-01-11T14:43:27.210Z] Container server terminated (code: 137, signal: null).
[2023-01-11T14:43:27.311Z] Stop (158 ms): Run: docker rm -f 2320bdc81bd2a00b85e499e4a0cbf72a92f3ca310a34e98207c04d28c67cbd52
[2023-01-11T14:44:53.388Z] Start: Run: docker version --format {{.Server.APIVersion}}
[2023-01-11T14:44:53.442Z] Stop (54 ms): Run: docker version --format {{.Server.APIVersion}}
[2023-01-11T14:44:53.443Z] 1.41 |
The bootstrap container that VS Code uses to clone a repository for the
Clone Repository in Container Volume
feature mounts the host's docker config, but can't access configured credential stores or helpers from the host. As a result, the container can't access images that are stored in private registries unless registry authentication is configured using a plain login and no credential store, which makes it challenging to use with services that rely on credential helpers (e.g. Google Container/Artifact Registry) or even with Docker Hub if it was configured through Docker Desktop (which, at least on Mac, uses the OS' credential store).Steps to Reproduce: see repro here
Does this issue occur when you try this locally?: Yes
Does this issue occur when you try this locally and all extensions are disabled?: N/A (this is a problem with an extension)
The text was updated successfully, but these errors were encountered: