Commit Graph

6 Commits

Author SHA1 Message Date
Lee Verberne fdd6fda024 kubectl debug: Allow mutating image names
Kubernetes-commit: ee9f11b95f01b32dade5d8dc7329625c40ac0e63
2020-10-30 18:23:34 +01:00
Lee Verberne 6a3c6f9a42 kubectl debug: add tests for Complete,Validate
Kubernetes-commit: 3cfcf3a74fc24e6b4b3f58710fe454d1bc3644cc
2020-10-30 08:54:13 +01:00
Kiyoshi Muranaka 5457c2b27c Fix index out of range panic for kubectl alpha debug
Fix containerNameToRef func to get init containers and ephemeral containers properly.

Set EphemeralContainers in generatePodCopyWithDebugContainer func to nil which means
dropping ephemeral containers from a copy of pod so that it can be created successfully,
otherwise it is rejected by the API server.

Kubernetes-commit: bf3dfaf99942eab20fac1570ca0146d32cb93b57
2020-09-07 02:43:21 +09:00
Lee Verberne 63b6f85e5d kubectl debug: add support for debugging nodes
When called with a node target, `kubectl debug` will create a run-once
pod in the target node's namespaces.

Kubernetes-commit: 7e63cc8b9d592abbb8a659205555e67b57080837
2020-04-03 18:36:32 +02:00
Aylei c73a3aa1bf Add debug by copy support for kubectl alpha debug command
Signed-off-by: Aylei <rayingecho@gmail.com>

Update staging/src/k8s.io/kubectl/pkg/cmd/debug/debug.go

Co-Authored-By: Lee Verberne <lee@verb.is>

Apply suggestions from code review

Co-Authored-By: Lee Verberne <lee@verb.is>

Kubernetes-commit: cfece3edfe8a726fc5dc65ef89b89021316837c7
2020-04-13 01:58:36 +08:00
Lee Verberne c3d84a9e1c Add kubectl debug alpha command
This first version of `kubectl alpha debug` is an import of the existing
kubectl-debug plugin, which supports adding ephemeral containers to
running pods. This attempts to follow patterns used by other kubectl
commands such as run, exec and scale.

Kubernetes-commit: e5b655938e55e0404545ff73e9239593a27a3272
2020-01-31 15:29:31 +01:00