![](/img/trans.png)
[英]How can I get node's memory with kubernetes-client lib in python
[英]How can I get the node where the pod is located using kubernetes python client?
我有一个 Pod 名称,我想使用 kube.netes python 客户端知道 Pod 的位置。 是否可以使用 kube.netes python 客户端来通过 Pod 获取节点名称? (就像kubectl get pod -o wide
中的 NODE 列一样)
我参考了文档https://github.com/kube.netes-client/python/blob/master/kube.netes/README.md 。 但是我没有找到解决办法。
我认为read_namespaced_pod
有信息( spec.nodeName
)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.