Merge pull request #39396 from Arhell/zh-upd

[zh] Update ConfigMap data extraction to use jsonpath instead of grep…
This commit is contained in:
Kubernetes Prow Robot 2023-02-11 17:09:30 -08:00 committed by GitHub
commit ff29e084bf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -475,7 +475,7 @@ it off regardless. Doing so will disable the ability to use the `--discovery-tok
* 从 API 服务器获取 `cluster-info` 文件:
```shell
kubectl -n kube-public get cm cluster-info -o yaml | grep "kubeconfig:" -A11 | grep "apiVersion" -A10 | sed "s/ //" | tee cluster-info.yaml
kubectl -n kube-public get cm cluster-info -o jsonpath='{.data.kubeconfig}' | tee cluster-info.yaml
```
<!--