The Wayback Machine - https://web.archive.org/web/20201228031811/https://github.com/wercker/stern/pull/113
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

Use InClusterConfig when no config is supplied #113

Open
wants to merge 1 commit into
base: master
from

Conversation

@jimmykarily
Copy link

@jimmykarily jimmykarily commented Jul 9, 2019

This will let stern run from within a cluster without any kubeconfig file. A serviceaccount token must be mounted in the pod in order for this to work.

This will work as long as everything else fails to get a config here: https://github.com/wercker/stern/blob/master/cmd/cli.go#L290

This will let stern run from within a cluster without any kubeconfig
file. A serviceaccount token must be mounted in the pod in order for
this to work.
@jimmykarily
Copy link
Author

@jimmykarily jimmykarily commented Jul 9, 2019

To add some background to this PR, I would like to use this tool to stream logs from specific pod to another service. It would be preferable if this tool could also be used as a library to which we could provide the "output" method (currently stdout) but this is definitely more complicated. Piping the json output of stern to my binary is the next best option and this PR lets me do this.

@mudler
Copy link

@mudler mudler commented Jul 10, 2019

Seems to be similar to #84 - and other issues are refering to the same feature #87. Any chance to pick this feature up ? @flenter @hatchan

@jimmykarily
Copy link
Author

@jimmykarily jimmykarily commented Jul 10, 2019

Good catch, didn't see #84, it is a smaller change so if it works we can do that instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.