<p>I am access my kubernetes dashboard using this url:</p>

<pre><code>https://kubernetes.example.com/api/v1/namespaces/kube-system/services/kubernetes-dashboard/#/workload?namespace=default
</code></pre>

<p>what make me confusing is the return content just json string, not the login page. The json content is :</p>

<pre><code>   {
  "kind": "Service",
  "apiVersion": "v1",
  "metadata": {
    "name": "kubernetes-dashboard",
    "namespace": "kube-system",
    "selfLink": "/api/v1/namespaces/kube-system/services/kubernetes-dashboard",
    "uid": "884240d7-8f3f-41a4-a3a0-a89649545c82",
    "resourceVersion": "133822",
    "creationTimestamp": "2019-09-21T16:21:19Z",
    "labels": {
      "addonmanager.kubernetes.io/mode": "Reconcile",
      "k8s-app": "kubernetes-dashboard",
      "kubernetes.io/cluster-service": "true"
    },
    "annotations": {
      "kubectl.kubernetes.io/last-applied-configuration": "{\"apiVersion\":\"v1\",\"kind\":\"Service\",\"metadata\":{\"annotations\":{},\"labels\":{\"addonmanager.kubernetes.io/mode\":\"Reconcile\",\"k8s-app\":\"kubernetes-dashboard\",\"kubernetes.io/cluster-service\":\"true\"},\"name\":\"kubernetes-dashboard\",\"namespace\":\"kube-system\"},\"spec\":{\"ports\":[{\"port\":443,\"targetPort\":8443}],\"selector\":{\"k8s-app\":\"kubernetes-dashboard\"},\"type\":\"NodePort\"}}\n"
    }
  },
  "spec": {
    "ports": [
      {
        "protocol": "TCP",
        "port": 443,
        "targetPort": 8443,
        "nodePort": 31085
      }
    ],
    "selector": {
      "k8s-app": "kubernetes-dashboard"
    },
    "clusterIP": "10.254.75.193",
    "type": "NodePort",
    "sessionAffinity": "None",
    "externalTrafficPolicy": "Cluster"
  },
  "status": {
    "loadBalancer": {

    }
  }
}
</code></pre>

<p>this is my nginx forward config:</p>

<pre><code>upstream  kubernetes{
    server  172.19.104.231:8001;
}
</code></pre>

<p>this is my kubernetes cluster proxy command:</p>

<pre><code>kubectl proxy --address=0.0.0.0 --port=8001 --accept-hosts='^*$'
</code></pre>

Dolphin
<p>You are accessing the Kubernetes API to get the <code>kubernetes-dashboard</code> Service resource manifest. This is the JSON that you get back.</p>

<p>If you want to access the Service, you need to access the Service itself, not the Kubernetes API. You can do this for example with port forwarding:</p>

<pre><code>kubectl port-forward svc/kubernetes-dashboard 8443:443
</code></pre>

<p>And then access the Service with:</p>

<pre><code>curl localhost:8443/#/workload?namespace=default
</code></pre>
