eldadru / ksniff

Kubectl plugin to ease sniffing on kubernetes pods using tcpdump and wireshark
Apache License 2.0
3.13k stars 186 forks source link

Handle CTRL+C and cleanup privileged sniffer pods #147

Closed bostrt closed 2 years ago

bostrt commented 2 years ago

This is partially addressing a few other issues:

Cleanup of the static-tcpdump process is going to need to be handled in another PR. I believe the only way to kill that process is to send a ctrl+c via the remotecommand/SPDY connection which is tricky (source) which is the workaround until this is resolved.

I'll also submit another PR for properly closing Wireshark upon a CTRL+C along with an option like --keep-wireshark to keep wireshark open after closing ksniff.

bostrt commented 2 years ago

@MichaelWasher would you mind reviewing this?

Noksa commented 1 year ago

@bostrt will it be released? It is not in 1.6.2 as I can see