Use published Docker image for Binder

So far I use a Dockerfile in my GitHub repo to define my Binder environment. I wonder if it would be better to build & publish (on Dockerhub) the corresponding image, so that Binder can pull it without having to build it?

1 Like

I would recommend that you use this GitHub Action to achieve this GitHub - jupyterhub/repo2docker-action: GitHub Action for repo2docker

3 Likes

Noting that this issue was also raised in the binderhub repo:

I’m not sure it is fully solved by the repo2docker GitHub action. That solution still requires a “passthrough” one-liner binder Dockerfile (i.e. FROM myorg/myimage:latest). What @fortierq is asking for is the same thing I asked for in that issue: BinderHub directly launching a container from dockerhub, rather than its own private container inventory.

Also raised here:

In case it’s helpful, I was able to partially workaround the issue somewhat by using a GitHub Actions workflow to create a new commit on a special branch every time a new cached image is built (https://github.com/microsoft/Quantum/blob/8118f183e5ae7efed823c4ef20f747f7666ce69f/.github/workflows/prebuild-docker.yml). It’s not quite directly launching from a given DockerHub image, but it at least allows for prebuilding from a GitHub Actions workflow.

1 Like