k8s中如何获取event的name和yaml信息

1. 获取event name

kubectl get events -o custom-columns="NAME:.metadata.name,TYPE:.type,LASTSEEN:.lastTimestamp,REASON:.reason,OBJECT:.involvedObject.name"

2. 获取event的yaml

 kubectl get event  -n   -o yaml 

你可能感兴趣的:(kubernetes,容器,云原生)