mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 21:17:23 +00:00
Merge pull request #90959 from ica10888/master
Better understanding of kubectl attach description
This commit is contained in:
commit
bb8a5d2ada
@ -41,15 +41,15 @@ import (
|
|||||||
|
|
||||||
var (
|
var (
|
||||||
attachExample = templates.Examples(i18n.T(`
|
attachExample = templates.Examples(i18n.T(`
|
||||||
# Get output from running pod 123456-7890, using the first container by default
|
# Get output from running pod mypod, using the first container by default
|
||||||
kubectl attach 123456-7890
|
kubectl attach mypod
|
||||||
|
|
||||||
# Get output from ruby-container from pod 123456-7890
|
# Get output from ruby-container from pod mypod
|
||||||
kubectl attach 123456-7890 -c ruby-container
|
kubectl attach mypod -c ruby-container
|
||||||
|
|
||||||
# Switch to raw terminal mode, sends stdin to 'bash' in ruby-container from pod 123456-7890
|
# Switch to raw terminal mode, sends stdin to 'bash' in ruby-container from pod mypod
|
||||||
# and sends stdout/stderr from 'bash' back to the client
|
# and sends stdout/stderr from 'bash' back to the client
|
||||||
kubectl attach 123456-7890 -c ruby-container -i -t
|
kubectl attach mypod -c ruby-container -i -t
|
||||||
|
|
||||||
# Get output from the first pod of a ReplicaSet named nginx
|
# Get output from the first pod of a ReplicaSet named nginx
|
||||||
kubectl attach rs/nginx
|
kubectl attach rs/nginx
|
||||||
|
Loading…
Reference in New Issue
Block a user