Skip to content

buildkit + gcr.io private repos (credHelpers) do not stack #720

@haizaar

Description

@haizaar

Docker 18.09-ce here.

I have FROM directive in my dockerfile pointing to a private registry:

FROM gcr.io/...

Running DOCKER_BUILDKIT=1 docker build . with this Dockerfile never finishes (after 5 minutes I hit CTRL-C).
Without buildkit it builds fine in seconds.

My ~/.docker/config.json is as follows:

{
  "credHelpers": {
    "us.gcr.io": "gcloud",
    "staging-k8s.gcr.io": "gcloud",
    "asia.gcr.io": "gcloud",
    "gcr.io": "gcloud",
    "marketplace.gcr.io": "gcloud",
    "eu.gcr.io": "gcloud"
  }
}

After waiting long time and pressing CTRL-C, the following error is printed (exact image names scrambled with ...):

------
 > [stage-1 1/4] FROM gcr.io/...:
------
failed to copy: httpReaderSeeker: failed open: unexpected status code https://gcr.io/v2/...: 403 Forbidden

Bug?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions