I am running prometheus in Kubernetes and trying to login to the running pod using the command below.
kubectl exec -it POD_NAME /bash
Error
ERRO[0000] exec failed: container_linux.go:346: starting container process caused "exec: \"bash\": executable file not found in $PATH" exec failed: container_linux.go:346: starting container process caused "exec: \"bash\": executable file not found in $PATH"
How to login to this running prometheus pod?
Container image doesn't contain /bin/bash, which is what Kube defaults to use to exec into the running container.
As a workaround you can try use kubectl and use /bin/sh.
Example: kubectl exec -it -- /bin/sh