-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Cannot create image stream from private hub.docker.com registry #18449
Comments
@openshift/sig-developer-experience |
@juanvallejo is this the issue w/ docker secret being created in the wrong format? (what level did that issue exist in, what level is it fixed in, and assuming it is that issue, is there a workaround we can give @feedm3 ?) |
Hi @feedm3 :) I'm assuming that with the username and password that you're using, a docker login / docker pull will work? Please make sure. I think the issue is probably down to the --docker-server argument: it must match the remote server otherwise OpenShift won't select the secret when it's trying to pull the image down. Please could you try each of the following arguments (one at a time) and see if either works? The
|
This looks likely to be the same issue. I believe only We did address part of the problem in 3.7: #18062 |
Yep, works. I tried both
I'm always getting the same unauthorized error :(
Can you go a little bit more in detail what you mean? |
I can confirm the docker-server value should be "docker.io", i was able to make the The other thing you can do is manually create the secret. First do a
That should create the secret in the right format. You may also need to delete any other secrets you've created for docker.io. |
Thanks @bparees, it works! What is important is that by default docker stores it's secrets in the credentials store and not in the config. Therefore you need to put an empty value for the So, short working conclusion:
|
Per the current state of the release-3.7 branch, The same is true of It could be that the docker server expects the new format. If that is the case, newer clients updated both of these commands to create secrets in the new |
closing this since it seems like the issue is fixed in newer code and we've got a workaround for @feedm3's env. |
@bparees I would like to reopen this issue. Unfortunately, it's currently not possible to deploy an image from a private repository form hub.docker.com. After creating the image pull secret, I was able to create an image stream. The image stream also seemed fine as the configuration and information about the image were correct. But deploying from this image stream doesn't work. I tried all commands in all combinations mentioned in the comments above but every single time the deployment failed with "Failed to pull image "docker.io/feedme/learning-openshift": rpc error: code = Unknown desc = unauthorized: authentication required". |
@feedm3—I just confirmed the same thing you're seeing, and it seems specific to docker.io. Something about how docker.io is doing authentication is not playing nicely with OpenShift feeding the right secrets. Seeing as the new issue is not with image stream creation but rather with pod creation (and failed image pull), I created a new wall of text to document it. Head on over: #18932 |
I can confirm the same issue. I can get the image metadata from |
@feedm3 @mxxk @membrive if your pod can't pull the image you have not setup your service account secrets properly. that is unrelated to imagestreams. if you'd like help w/ that issue, please open a new issue and describe how you've created your secret and pod, preferably w/o imagestreams just to keep the configuration simple (just a pod referencing the docker hub image directly). |
I want to deploy a docker image which I have pushed to
hub.docker.com
but whenever I import the private registry as image stream I get an unauthenticated error although I have created a docker secret within openshift (related docs).Version
Steps To Reproduce
docker-server
parameter is correct, official openshift docs are very unclear about that)Current Result
Expected Result
I expect the registry to be imported so that I can later on create an app.
The text was updated successfully, but these errors were encountered: