0
[root@vk-okd-01 ~]# kubectl cluster-info
Kubernetes control plane is running at https://vk-aks-061221-testing-f23f0fc1.hcp.southcentralus.azmk8s.io:443
CoreDNS is running at https://vk-aks-061221-testing-f23f0fc1.hcp.southcentralus.azmk8s.io:443/api/v1/namespaces/kube-system/services/kube-dns:dns/proxy
Metrics-server is running at https://vk-aks-061221-testing-f23f0fc1.hcp.southcentralus.azmk8s.io:443/api/v1/namespaces/kube-system/services/https:metrics-server:/proxy

如何使用 python API 或任何其他方式使用 python 以编程方式获取上述“kubectl cluster-info”命令的输出

从上面的输出中,我需要提取 Kubernetes 控制面板 URL 和 Metric 服务器 URL

4

0 回答 0