GoogleCloudPlatform / docker-credential-gcr

A Docker credential helper for GCR users
https://gcr.io
Apache License 2.0
294 stars 92 forks source link

Pulling image on a COS instance: WARNING: Unable to determine Docker version: exit status 1 #43

Closed layik closed 6 years ago

layik commented 6 years ago

The whole GCloud SDK's misleading and confusing docs is not worth our time but we are determined not to give in to your complexities. So on that negative note, you can ignore this ticket/complaint or try and convince us that you have built this tool for "human" developers.

The docs tell me to do this here are the outputs

me@att ~ $ docker-credential-gcr configure-docker

WARNING: Unable to determine Docker version: exit status 1 Configuring docker-credential-gcr as a registry-specific helper. This is only supported by Docker client versions 1.13+ /home/me/.docker/config.json configured to use this credential helper for GCR registries

me@att ~ $ docker -v

Docker version 17.03.2-ce, build f5ec1e2

me@att ~ $ docker-credential-gcr version

Google Container Registry Docker credential helper 1.4.2

me@att ~ $ cat /etc/os-release

BUILD_ID=10452.89.0 NAME="Container-Optimized OS" KERNEL_COMMIT_ID=e2e439017d740b3fbe0f4f1a2bc63af84facf535 GOOGLE_CRASH_ID=Lakitu VERSION_ID=66 BUG_REPORT_URL=https://crbug.com/new PRETTY_NAME="Container-Optimized OS from Google" VERSION=66 GOOGLE_METRICS_PRODUCT_ID=26 HOME_URL="https://cloud.google.com/compute/docs/containers/vm-image/" ID=cos

BUT...as expected

me@att ~ docker pull --rm gcr.io/project/image:tag

docker: unauthorized: authentication required.

layik commented 6 years ago

Running me@att ~ sudo docker run --rm gcr.io/google-containers/busybox echo "hello world" is fine.

dekkagaijin commented 6 years ago

Hey, sorry for your trouble, please contact gcr-contact (at) google.com with:

layik commented 6 years ago

Thanks @dekkagaijin finding an email like that is a monumental task. I will get in touch.

jonjohnsonjr commented 6 years ago

If I remember correctly, the problem ended up being the same as this stack overflow question: https://stackoverflow.com/questions/51236449/unable-to-pull-image-from-private-gcr-from-container-optimized-compute-engine

Leaving this in case anyone else stumbles here :)

Nhat002 commented 6 years ago

@jonjohnsonjr It does not work for me after trying the solution in the stack overflow question. I'm using cos-stable-67-10575-64-0 and Google Container Registry Docker credential helper 1.4.3