Closed bpfrd closed 9 months ago
Hey @bpfrd did you have a stable network connection when trying to pull/build the image? I was able to reproduce the same error when I turned off networking on my computer. 😉
Hi, Thanks for your repsonse. I think the network is stable on my server. here is the result of pulling an image.
docker run hello-world Unable to find image 'hello-world:latest' locally latest: Pulling from library/hello-world 719385e32844: Pull complete Digest: sha256:c79d06dfdfd3d3eb04cafd0dc2bacab0992ebc243e083cabe208bac4dd7759e0 Status: Downloaded newer image for hello-world:latest
Hello from Docker! This message shows that your installation appears to be working correctly.
To generate this message, Docker took the following steps:
To try something more ambitious, you can run an Ubuntu container with: $ docker run -it ubuntu bash
Share images, automate workflows, and more with a free Docker ID: https://hub.docker.com/
For more examples and ideas, visit: https://docs.docker.com/get-started/
And what if you try this?
docker pull cerit.io/hubs/nbgrader-hub:10-11-2023
it works.
Well... it it works through docker, then it should also work in your K8s cluster. If it doesn't, then the issue is most probably somewhere else, not in the image/image repo. From the docker build
logs you posted it looks like network or DNS problems.
Yes, the problem is pulling image in minikube. Here i ssh into minikube and try to pull image but it fails:
$minikube ssh docker@minikube:~$ docker@minikube:~$ docker run hello-world Unable to find image 'hello-world:latest' locally docker: Error response from daemon: Get "https://registry-1.docker.io/v2/": net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers). See 'docker run --help'.
Would you have any idea how to fix it?
there was a problem with docker. now it works. But I have another question.
I have set up the ingress as in the example: ingress:
enabled: true
hosts:
- nbgrader.example.com #replaced by my own domain
tls:
- hosts:
- nbgrader.example.com
secretName: nbgrader-example-com-tls
but proxy-public is still of type clusterip and I can not access the service using in the browser
It is the correct behavior for the "proxy-public" service to be ClusterIP. If you are running it on minikube, then I recommend checking out this: https://kubernetes.io/docs/tasks/access-application-cluster/ingress-minikube/
Thanks for your suggestion. I should have enabled ingress addons. But now the ingress IP is different from the IP that the host points to. Is it possible to set specific IP to ingress?
For testing purposes, isn't it easier to just modify the IP in /etc/hosts
?
I'm not very familiar with networking. The problem is I would like to deploy it using minikube and jupyterhub should be accessible from browser. The domain resolves to some IP starting from 10.xxx on the server while ingress address for the same host is another IP starting from 192.xxx. I think if ingress address could be the same address 10.xxx it would work. How is it possible?
It should work with the 192.xxx. Just put the following line in the /etc/hosts
file:
192.x.x.x your.domain.com
Where your.domain.com
is the same, as you've set in the ingress configuration. Then you should be able to access jupyterhub on this domain.
I added 192.xxx mydomain
but it didn't work. do i need to reboot the server?
maybe this information helps.
ping mydomain (10.xxx) from local computer works $kubectl get ingress gives HOST=mydomain and address 192.xxx
the server is remote and different from my local computer. I tried to put c.JupyterHub.bind_url=http://10.xxx:80
but it didn't work either.
more info:
$kubectl get ingress
NAME CLASS HOSTS ADDRESS PORTS AGE
jupyterhub <none> domain.com my_minikube_ip(192.xxx) 80, 443 3h56m
$kubectl get ingress -o yaml
...
spec:
rules:
- host: domain.com
http:
paths:
- backend:
service:
name: proxy-public
port:
name: http
path: /
pathType: Prefix
tls:
- hosts:
- domain.com
secretName: my-tls-secret
status:
loadBalancer:
ingress:
- ip: my_minikube_ip
and the domain.com resolves to 10.xxx
What server? Minikube is intended to be used only in a local environment. Are you trying to run minikube on a remote server? Please do not try to run a production application on minikube.
It can probably be done by port-forwarding/tunneling/something, but it is definitely not what minikube is designed for.
I see. Even if we allocate enough resources CPU and memory and the class is small, I shouldn't run minikube in production? What would you suggest? (I mean own server not a cloud-based).
You can check k3s, MicroK8s or kubeadm for example. But they are a little harder to setup than minikube.
I'm closing the issue, since the discussion diverged from the original topic.
Hello,
I keep getting an error while it's pulling jupyterhub image.
When I try to build the images/hub.Dockerfile I get the below error:
best