gitpod icon indicating copy to clipboard operation
gitpod copied to clipboard

Unable to create a workspace from a private image from dockerhub

Open Keith-Hon opened this issue 3 years ago • 0 comments

Bug description

Reference: https://github.com/gitpod-io/gitpod/pull/8550#issuecomment-1208225358

Using a private image from dockerhub will cause the below error

Capture

Steps to reproduce

  1. Build a docker image from one of the gitpod workspace images, e.g. gitpod/workspace-full:2022-06-20-19-54-55
  2. Publish that image with scope to dockerhub, so that the image is private
  3. Create a new git repository and edit .gitpod.yml with reference of the private image
  4. Start a new workspace on such repository
  5. Error occurs

Workspace affected

No response

Expected behavior

It should successfully start a new workspave with a private docker image from dockerhub

Example repository

No response

Anything else?

No response

Keith-Hon avatar Aug 09 '22 03:08 Keith-Hon

Hi! I'm playing with gitpod and I have run into exactly the same issue. I have a private repo and a private dockerhub image. Gitpod cannot build/load the image because of exactly the same error as in the original post. Sadly, neither the repo or image can be made public.

kapke avatar Aug 24 '22 16:08 kapke

Is your repo private as well @kapke? Screenshot 2022-08-25 at 10 07 56 PM

axonasif avatar Aug 25 '22 16:08 axonasif

@axonasif Yes, it is. Will Dockerfile like

FROM my-private-image

work in such case?

kapke avatar Aug 29 '22 11:08 kapke

No @kapke, I mean to put your dockerfile contents into that file, souring it externally with FROM would not help for now.

axonasif avatar Aug 29 '22 19:08 axonasif

I see. Sadly this is way beyond what's easy for the environment I need. On the other hand, Nix with flakes does the job just fine in my case, I looked at Docker mostly to have the workspace load instantly instead of having to wait couple of minutes for Nix to fetch everything.

kapke avatar Aug 30 '22 09:08 kapke