text: apiVersion: v1
  kind: ServiceAccount
  metadata:
    name: dashboard
    namespace: arena-system
  
  ---
  kind: ClusterRoleBinding
  apiVersion: rbac.authorization.k8s.io/v1
  metadata:
    name: dashboard-extended
  subjects:
    - kind: ServiceAccount
      name: dashboard
      namespace: arena-system
  roleRef:
    kind: ClusterRole
    name: view
    apiGroup: rbac.authorization.k8s.io
  
  ---
  
  kind: RoleBinding
  apiVersion: rbac.authorization.k8s.io/v1
  metadata:
    name: dashboard-default
    namespace: default
  subjects:
    - kind: ServiceAccount
      name: cluster-admin
      namespace: arena-system
  roleRef:
    kind: ClusterRole
    name: view
    apiGroup: rbac.authorization.k8s.io
  
  ---
  
  kind: Deployment
  apiVersion: apps/v1
  metadata:
    labels:
      app: kubernetes-dashboard
    name: kubernetes-dashboard
    namespace: arena-system
  spec:
    replicas: 1
    selector:
      matchLabels:
        app: kubernetes-dashboard
    template:
      metadata:
        labels:
          app: kubernetes-dashboard
        # Comment the following annotaion if Dashboard must not be deployed on master
        annotations:
          scheduler.alpha.kubernetes.io/tolerations: |
            [
              {
                "key": "dedicated",
                "operator": "Equal",
                "value": "master",
                "effect": "NoSchedule"
              }
            ]
      spec:
        serviceAccountName: dashboard
        hostNetwork: true
        hostPID: true
        dnsPolicy: ClusterFirstWithHostNet
        containers:
        - name: kubernetes-dashboard
          image: registry.cn-zhangjiakou.aliyuncs.com/kube-ai/kubernetes-dashboard-amd64:v1.6.0
          imagePullPolicy: Always
          ports:
          - containerPort: 9090
            protocol: TCP
          args:
            # Uncomment the following line to manually specify Kubernetes API server Host
            # If not specified, Dashboard will attempt to auto discover the API server and connect
            # to it. Uncomment only if the default does not work.
            # - --apiserver-host=http://my-address:port
          livenessProbe:
            httpGet:
              path: /
              port: 9090
            initialDelaySeconds: 30
            timeoutSeconds: 30
  ---
  kind: Service
  apiVersion: v1
  metadata:
    labels:
      kubernetes.io/cluster-service: "true"
      app: kubernetes-dashboard
    name: kubernetes-dashboard
    namespace: arena-system
  spec:
    type: NodePort
    ports:
    - port: 80
      targetPort: 9090
    selector:
      app: kubernetes-dashboard
  