Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

continuously resolve pods matching pattern #91

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

benbertrands
Copy link

Plz review and feedback.
A subshell now checks for matching pods every second and pipes a new list of pods if changes.
Pipe is being listened on by main, every time a new list of pods comes through tails get remade

issues:

  • new pods appearing are still in initializing state, and should not be picked up by subshell.
  • pipe /tmp/kubetail-matching_pods_pipe.$$ can be used for arbitrary code execution
  • don't like the "kill %t"
  • colours of existing pods shouldn't change when the list of pods changes

@johanhaleby
Copy link
Owner

Wow this is so cool! I've tried to get this working several times but failed to do so. Unfortunately this doesn't really work for me. When I run kubetail my-pod -c my-container I get:

./kubetail: line 278: /tmp/kubetail-matching_pods_pipe.82906: No such file or directory

@benbertrands
Copy link
Author

yea sorry. Didn't test after changing the pipe location, should be fixed now

@johanhaleby
Copy link
Owner

Hmm, now it gives me:

./kubetail: line 278: readarray: command not found

@benbertrands
Copy link
Author

readarray was added somewhere in bash 4.
Also working on a mac ?

@benbertrands
Copy link
Author

benbertrands commented May 7, 2019

There also seems to be an issue in the subshells filtering. Looking into it after work

edit: seems to have been #76

@benbertrands
Copy link
Author

should I get rid of the readarray to support bash 3?

@johanhaleby
Copy link
Owner

Yes I'm using a Mac (zsh). I think it would be good to support bash 3 since afaik that's what we're trying to support atm.

@benbertrands
Copy link
Author

looks to be easier to have the subshell put out containers iso pods

@johanhaleby
Copy link
Owner

One thing that I notice is that the colors are not working if there are multiple pods. Could we get that working again somehow?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants