how to access local kubernetes minikube dashboard remotely

前端 未结 9 475
离开以前
离开以前 2021-01-30 14:46

Kubernetes newbie (or rather basic networking) question: Installed single node minikube (0.23 release) on a ubuntu box running in my lan (on IP address 192.168

9条回答
  •  无人及你
    2021-01-30 15:17

    Thanks for your valuable answers, If you have to use the kubectl proxy command unable to view permanently, using the below "Service" object in YAML file able to view remotely until you stopped it. Create a new yaml file minikube-dashboard.yaml and write the code manually, I don't recommend copy and paste it.

    apiVersion : v1
    kind: Service
    metadata:
      labels:
        app: kubernetes-dashboard
      name: kubernetes-dashboard-test
      namespace: kube-system
    spec:
      ports:
      - port: 80
        protocol: TCP
        targetPort: 9090
        nodePort: 30000
      selector:
        app: kubernetes-dashboard
      type: NodePort
    

    Execute the command,

    $ sudo kubectl apply -f minikube-dashboard.yaml
    

    Finally, open the URL: http://your-public-ip-address:30000/#!/persistentvolume?namespace=default

提交回复
热议问题