mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 02:41:25 +00:00
Simply modify the Kubectl logs information
This commit is contained in:
parent
6a9182c944
commit
1995f28c64
@ -58,7 +58,7 @@ var (
|
||||
kubectl logs nginx --all-containers=true
|
||||
|
||||
# Return snapshot logs from all containers in pods defined by label app=nginx
|
||||
kubectl logs -lapp=nginx --all-containers=true
|
||||
kubectl logs -l app=nginx --all-containers=true
|
||||
|
||||
# Return snapshot of previous terminated ruby container logs from pod web-1
|
||||
kubectl logs -p -c ruby web-1
|
||||
@ -67,7 +67,7 @@ var (
|
||||
kubectl logs -f -c ruby web-1
|
||||
|
||||
# Begin streaming the logs from all containers in pods defined by label app=nginx
|
||||
kubectl logs -f -lapp=nginx --all-containers=true
|
||||
kubectl logs -f -l app=nginx --all-containers=true
|
||||
|
||||
# Display only the most recent 20 lines of output in pod nginx
|
||||
kubectl logs --tail=20 nginx
|
||||
|
Loading…
Reference in New Issue
Block a user