A kubectl
plugin for directly modifying Pods' ephemeralContainers
spec.
An ephemeral container is a temporary container that is injected into existing Pods for some user-initiated actions, for example, troubleshooting. However, ephemeral container specs must be handled as a Pod's ephemeralcontainers
subresource. Consequently, kubectl edit
cannot be used for modifying pod.spec.ephemeralcontainers
.
This project is a plugin (i.e. an extension) to kubectl
that allows such direct editing, bringing back the experience of kubectl edit
. For more information on how to extend kubectl
, see guides.
Download the binary from the release page and copy it to a directory on PATH
.
In addition to released binaries, you can install the plugin from source.
go install github.com/k8s-crafts/ephemeral-containers-plugin@latest
Note: The binary will be installed under GOBIN
(i.e. go env GOBIN
) as ephemeral-containers-plugin
. It must be renamed to kubectl-ephemeral_containers
to register the plugin with kubectl
.
git clone git@github.com:k8s-crafts/ephemeral-containers-plugin.git
cd ephemeral-containers-plugin
# Build the plugin and install it on PATH
# Default to $HOME/bin
make build install
For details on how to use the plugin, see User Guides.
For details on how to contribute, see Contributing Guides and Developer Guides.
The project follows MIT License. Feel free to use, experiment and distribute the project as per terms in the license!