monitor server check auth with get verb (#5239)

This commit is contained in:
Jiahui
2024-11-27 11:11:25 +08:00
committed by GitHub
parent ebb51e5568
commit aa3eff0ae6
+1 -1
View File
@@ -96,7 +96,7 @@ func Authenticate(ns, kc string) error {
return fmt.Errorf("ping apiserver is no ok: %v", string(res))
}
if err := CheckResourceAccess(client, ns, "update", "pods"); err != nil {
if err := CheckResourceAccess(client, ns, "get", "pods"); err != nil {
// fmt.Println(err.Error())
return fmt.Errorf("check resource access error: %v", err)
}