Jupyterhub z2jh ingress not working

Hi,

I deployed z2jh on a single-node microk8s cluster on a server and it is supposed to be used in production. The problem is ingress address is missing. here is some details:

# config.yaml ingress part
ingress:
    annotations:
         kubernetes.io/tls-acme: "true"
    enabled: true
    hosts:
      - mydomain
    tls:
      - hosts:
        - mydomain
        secretName: my-tls-secret

[centos@master-02 ~]$ microk8s kubectl get po -o wide
NAME                     READY   STATUS    RESTARTS   AGE     IP             NODE                  NOMINATED NODE   READINESS GATES
proxy-569b56f65c-rwng2   1/1     Running   0          7h48m   10.1.149.119   master-02.novalocal   <none>           <none>
hub-856cd55494-qcrxc     1/1     Running   0          7h48m   10.1.149.124   master-02.novalocal   <none>           <none>
[centos@master-02 ~]$
[centos@master-02 ~]$ microk8s kubectl get svc
NAME           TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)    AGE
kubernetes     ClusterIP   10.152.183.1     <none>        443/TCP    28h
course-svc     ClusterIP   None             <none>        <none>     7h48m
hub            ClusterIP   10.152.183.130   <none>        8081/TCP   7h48m
proxy-api      ClusterIP   10.152.183.185   <none>        8001/TCP   7h48m
proxy-public   ClusterIP   10.152.183.71    <none>        80/TCP     7h48m
[centos@master-02 ~]$
[centos@master-02 ~]$ microk8s kubectl get ingress
NAME         CLASS     HOSTS                 ADDRESS   PORTS     AGE
jupyterhub   traefik   mydomain                                   80, 443   7h49m

the ingress doesn’t have any external_ip

[centos@master-02 ~]$ microk8s kubectl get svc -n traefik -o wide
NAME      TYPE           CLUSTER-IP       EXTERNAL-IP   PORT(S)                      AGE     SELECTOR
traefik   LoadBalancer   10.152.183.146   <pending>     80:31447/TCP,443:32630/TCP   7h58m   app.kubernetes.io/instance=traefik-traefik,app.kubernetes.io/name=traefik

here ingress pod:

[centos@master-02 ~]$ microk8s kubectl get po -n traefik -o wide
NAME                       READY   STATUS    RESTARTS   AGE     IP            NODE                  NOMINATED NODE   READINESS GATES
traefik-857c7dbc5d-nk6vw   1/1     Running   0          7h59m   10.1.149.88   master-02.novalocal   <none>           <none>

I don’t have any loadbalancer on the server so I also assigned a nodeport to ingress but external IP was still missing.

microk8s kubectl patch svc traefik -n traefik --type='json' -p '[{"op":"replace","path":"/spec/type","value":"NodePort"}]'

Does anyone experienced the same problem? I would like to access the proxy-public using the external IP of the server in my browser. how can I resolve this issue?

best regards

The ingress controller is the responsibility of the Kubernetes cluster admin, Z2JH assumes it’s already working.

If you search this forum for microk8s you’ll find some posts from others who have tried it, e.g.