| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
…ubernetes dashboard
Codecov Report❌ Patch coverage is 0% with 7 lines in your changes missing coverage. Please review.
@@ Coverage Diff @@
## main #12776 +/- ##
=========================================
Coverage 17.92% 17.92%
- Complexity 16176 16179 +3
=========================================
Files 5949 5949
Lines 534058 534063 +5
Branches 65301 65303 +2
=========================================
+ Hits 95742 95751 +9
+ Misses 427560 427555 -5
- Partials 10756 10757 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry.
|
Sorry, something went wrong.
|
Hi @Pearl1594 it mentions the creation of token for Kubernetes dashboard |
Sorry, something went wrong.
yes the text needs to be updated https://headlamp.dev/docs/latest/installation/ cc @Pearl1594 |
Sorry, something went wrong.
Yes @weizhouapache it requires change in text, this PR isn't ready yet for review - work in progress. |
Sorry, something went wrong.
thanks @Pearl1594 it would be better consider that some users still use the old CKS ISOs which have old kubernetes dashboard bundled. |
Sorry, something went wrong.
|
Sorry, something went wrong.
|
@kiranchavala a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 17151 |
Sorry, something went wrong.
|
@Pearl1594 is it good for 4.22.1? if so, can you re-target this to 4.22. |
Sorry, something went wrong.
There was a problem hiding this comment.
This PR updates CloudStack’s Kubernetes integration and UI guidance to prefer the Headlamp dashboard for newly provisioned Kubernetes clusters, while retaining compatibility with the legacy Kubernetes Dashboard for older clusters.
Changes:
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| ui/src/views/compute/KubernetesServiceTab.vue | Adds Headlamp + legacy dashboard access/token guidance in the Kubernetes cluster UI tab. |
| scripts/util/create-kubernetes-binaries-iso.sh | Switches ISO dashboard asset from a Dashboard YAML URL to a Headlamp manifest version and bundles headlamp.yaml. |
| plugins/integrations/kubernetes-service/src/main/resources/conf/k8s-control-node.yml | Installs headlamp.yaml when present (fallback to dashboard.yaml) and uses Headlamp by default for online installs. |
| plugins/integrations/kubernetes-service/src/main/java/com/cloud/kubernetes/cluster/utils/KubernetesClusterUtil.java | Extends dashboard readiness checks to detect Headlamp first, then legacy dashboard. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Sorry, something went wrong.
| /opt/bin/kubectl create rolebinding admin-binding --role=admin --user=admin || true | ||
| /opt/bin/kubectl create clusterrolebinding cluster-admin-binding --clusterrole=cluster-admin --user=admin || true |
| /opt/bin/kubectl create serviceaccount headlamp-admin -n kube-system || true | ||
| /opt/bin/kubectl create clusterrolebinding headlamp-admin --clusterrole=cluster-admin --serviceaccount=kube-system:headlamp-admin || true |
| <p><strong>Note:</strong> CloudStack Kubernetes clusters use <strong>Headlamp</strong> dashboard (deployed in <code>kube-system</code> namespace). For backward compatibility with older clusters using Kubernetes Dashboard, please check your cluster configuration.</p> | ||
| <a-timeline> | ||
| <a-timeline-item> | ||
| <p> | ||
| {{ $t('label.run.proxy.locally') }}<br><br> | ||
| <code><b>kubectl --kubeconfig /custom/path/kube.conf proxy</b></code> | ||
| <strong>Access Headlamp Dashboard (new clusters)</strong><br><br> | ||
| <strong>Step 1:</strong> Run port-forward command:<br> | ||
| <code><b>kubectl --kubeconfig /custom/path/kube.conf port-forward -n kube-system service/headlamp 8080:80</b></code><br><br> | ||
| <strong>Step 2:</strong> Open in your browser:<br> | ||
| <a href="http://localhost:8080"><code>http://localhost:8080</code></a> | ||
| </p> | ||
| </a-timeline-item> | ||
| <a-timeline-item> | ||
| <p> | ||
| {{ $t('label.open.url') }}<br><br> | ||
| <strong>Access Kubernetes Dashboard (legacy clusters)</strong><br><br> | ||
| <strong>Step 1:</strong> {{ $t('label.run.proxy.locally') }}<br> | ||
| <code><b>kubectl --kubeconfig /custom/path/kube.conf proxy</b></code><br><br> | ||
| <strong>Step 2:</strong> {{ $t('label.open.url') }}<br> | ||
| <a href="http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/"><code>http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/</code></a> | ||
| </p> | ||
| </a-timeline-item> | ||
| <a-timeline-item> | ||
| <p> | ||
| <strong>Create Access Token for Headlamp (new clusters)</strong> | ||
| </p> | ||
| <p v-html="$t('label.kubernetes.dashboard.create.token')"></p> | ||
| <p v-html="$t('label.kubernetes.dashboard.create.token.desc')"></p> | ||
| <a-textarea :value="'kubectl --kubeconfig /custom/path/kube.conf apply -f - <<EOF\napiVersion: v1\nkind: ServiceAccount\nmetadata:\n name: kubernetes-dashboard-admin-user\n namespace: kubernetes-dashboard\n---\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n name: kubernetes-dashboard-admin-user\nroleRef:\n apiGroup: rbac.authorization.k8s.io\n kind: ClusterRole\n name: cluster-admin\nsubjects:\n- kind: ServiceAccount\n name: kubernetes-dashboard-admin-user\n namespace: kubernetes-dashboard\n---\napiVersion: v1\nkind: Secret\ntype: kubernetes.io/service-account-token\nmetadata:\n name: kubernetes-dashboard-token\n namespace: kubernetes-dashboard\n annotations:\n kubernetes.io/service-account.name: kubernetes-dashboard-admin-user\nEOF'" :rows="10" readonly /> | ||
| <a-textarea :value="'kubectl --kubeconfig /custom/path/kube.conf apply -f - <<EOF\napiVersion: v1\nkind: ServiceAccount\nmetadata:\n name: headlamp-admin\n namespace: kube-system\n---\napiVersion: rbac.authorization.k8s.io/v1\nkind: ClusterRoleBinding\nmetadata:\n name: headlamp-admin\nroleRef:\n apiGroup: rbac.authorization.k8s.io\n kind: ClusterRole\n name: cluster-admin\nsubjects:\n- kind: ServiceAccount\n name: headlamp-admin\n namespace: kube-system\n---\napiVersion: v1\nkind: Secret\ntype: kubernetes.io/service-account-token\nmetadata:\n name: headlamp-admin-token\n namespace: kube-system\n annotations:\n kubernetes.io/service-account.name: headlamp-admin\nEOF'" :rows="12" readonly /> |
| HEADLAMP_DASHBOARD_URL="https://raw.githubusercontent.com/kubernetes-sigs/headlamp/v${HEADLAMP_DASHBOARD_VERSION}/kubernetes-headlamp.yaml" | ||
| echo "Downloading Headlamp manifest from ${HEADLAMP_DASHBOARD_URL}" | ||
| headlamp_conf_file="${working_dir}/headlamp.yaml" | ||
| curl -sSL ${HEADLAMP_DASHBOARD_URL} -o ${headlamp_conf_file} |
There was a problem hiding this comment.
LGTM
./create-kubernetes-binaries-iso.sh ./ 1.33.1 1.7.1 1.33.0 https://raw.githubusercontent.com/projectcalico/calico/v3.30.0/manifests/calico.yaml 0.40.1 setupheadlamp-v1.33.1 amd64
Registered the iso
Created a cks cluster with the iso
CKS Cluster deployed successfull with text containing headlamp
╰─ k --kubeconfig /Users/kiranchavala/Desktop/kube.conf get deployments.apps -A NAMESPACE NAME READY UP-TO-DATE AVAILABLE AGE kube-system calico-kube-controllers 1/1 1 1 43m kube-system cloud-controller-manager 1/1 1 1 43m kube-system coredns 2/2 2 2 43m kube-system headlamp 1/1 1 1 43m ╭─ ~ ✔ ╱ kubernetes-admin@kubernetes ╱ 04:01:14 PM ╰─ k --kubeconfig /Users/kiranchavala/Desktop/kube.conf get pods -A NAMESPACE NAME READY STATUS RESTARTS AGE kube-system calico-kube-controllers-7bfdc5b57c-855xd 1/1 Running 0 43m kube-system calico-node-57mvt 1/1 Running 0 43m kube-system calico-node-c4sz8 1/1 Running 0 43m kube-system cloud-controller-manager-6887fc69c8-l7bld 1/1 Running 0 43m kube-system coredns-674b8bbfcf-dz86k 1/1 Running 0 43m kube-system coredns-674b8bbfcf-sdtml 1/1 Running 0 43m kube-system etcd-test-headlamp-control-19d1a14b04a 1/1 Running 0 44m kube-system headlamp-747b5f4d5-vgq64 1/1 Running 0 43m kube-system kube-apiserver-test-headlamp-control-19d1a14b04a 1/1 Running 0 43m kube-system kube-controller-manager-test-headlamp-control-19d1a14b04a 1/1 Running 0 43m kube-system kube-proxy-kq2gw 1/1 Running 0 43m kube-system kube-proxy-srkpd 1/1 Running 0 43m kube-system kube-scheduler-test-headlamp-control-19d1a14b04a 1/1 Running 0 43m
Sorry, something went wrong.
|
@kiranchavala a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
Sorry, something went wrong.
There was a problem hiding this comment.
code lgtm
Sorry, something went wrong.
|
[SF] Trillian test result (tid-15715)
|
Sorry, something went wrong.
|
I believe it's ready @DaanHoogland - however, personally, I only tested it with headlamp, but didn't test backward compatibility, i.e., for existing isos with legacy k8s dashboard if it works correctly. |
Sorry, something went wrong.
Tested the old legacy dashboard with the iso https://download.cloudstack.org/cks/setup-v1.33.1-calico-x86_64.iso The old dashboard works fine
Also deployed headlamp dashboard on cks cluster deployed with old iso (https://download.cloudstack.org/cks/setup-v1.33.1-calico-x86_64.iso) >> works fine
|
Sorry, something went wrong.
|
@Pearl1594 , will you allow us to merge now ;) |
Sorry, something went wrong.
|
Thanks @kiranchavala - all good @DaanHoogland ready to merge |
Sorry, something went wrong.
…ubernetes dashboard (apache#12776)
| Back | FazBrowse Home | New Git URL |
Description
This PR fixes: #12728
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?