Skip to content

Commit 6f0de11

Browse files
committed
[zh] Update debug-pod-replication-controller.md
Signed-off-by: xin.li <[email protected]>
1 parent bee30a8 commit 6f0de11

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

content/zh/docs/tasks/debug-application-cluster/determine-reason-pod-failure.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,15 @@ the container starts.
9999
```shell
100100
kubectl get pod termination-demo -o go-template="{{range .status.containerStatuses}}{{.lastState.terminated.message}}{{end}}"
101101
```
102+
103+
<!
104+
If you are running a multi-container pod, you can use a Go template to include the container's name. By doing so, you can discover which of the containers is failing:
105+
-->
106+
如果你正在运行多容器 Pod,则可以使用 Go 模板来包含容器的名称。这样,你可以发现哪些容器出现故障:
107+
108+
```shell
109+
kubectl get pod multi-container-pod -o go-template='{{range .status.containerStatuses}}{{printf "%s:\n%s\n\n" .name .lastState.terminated.message}}{{end}}'
110+
```
102111

103112
<!--
104113
## Customizing the termination message

0 commit comments

Comments
 (0)