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

add ability to get json for "minikube sevice list" #15827

Closed
medyagh opened this issue Feb 10, 2023 · 4 comments · Fixed by #15831
Closed

add ability to get json for "minikube sevice list" #15827

medyagh opened this issue Feb 10, 2023 · 4 comments · Fixed by #15831
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/feature Categorizes issue or PR as related to a new feature. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.

Comments

@medyagh
Copy link
Member

medyagh commented Feb 10, 2023

we already have json output for many of minikube commands, for example
"minikube profile list -o=json"

we have forgotten to implement it for "service list"

"minikube service list -o=json"

should be easy to follow other examples of doing it

@medyagh medyagh added help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. kind/feature Categorizes issue or PR as related to a new feature. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. labels Feb 10, 2023
@medyagh medyagh changed the title add --output=json to "minikube sevice list" add ability to get json for "minikube sevice list" Feb 10, 2023
@OmSaran
Copy link
Contributor

OmSaran commented Feb 10, 2023

Can I take a stab at this please?

@Sajiyah-Salat
Copy link

Sajiyah-Salat commented Feb 11, 2023

Hello @medyagh I have worked on minikube many times. It would be easy for me to make changes, however the repo is large enough, can you please guide me to exact file location? Thank you.

@medyagh
Copy link
Member Author

medyagh commented Feb 11, 2023

Hi both @OmSaran and @Sajiyah-Salat
first PR come first review ! :) or if you like to cooperate that's fine too

here is the file to look at.
https://github.com/kubernetes/minikube/blob/master/cmd/minikube/cmd/service_list.go

and if you want example of list json you can look at profile list -o=json
https://github.com/kubernetes/minikube/blob/master/cmd/minikube/cmd/config/profile_list.go#L59

@OmSaran
Copy link
Contributor

OmSaran commented Feb 11, 2023

Thanks @medyagh, I've added a PR, would be great if you could review it! I also tested it locally and attached the before/after results in the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. kind/feature Categorizes issue or PR as related to a new feature. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants