ops icon indicating copy to clipboard operation
ops copied to clipboard

Adding ops JSON output to allow build web frontend

Open dzonerzy opened this issue 2 years ago • 4 comments

Would be nice if ops could output information like instances and so on in a JSON format this way would be possible to create a web frontend by wrapping the ops command.

dzonerzy avatar Nov 23 '21 16:11 dzonerzy

this exists for many operations already like https://github.com/nanovms/ops/blob/master/gcp/gcp_instance.go#L210

eyberg avatar Nov 23 '21 18:11 eyberg

I don't know if already exist for onprem images , but that would be awesome

dzonerzy avatar Nov 23 '21 18:11 dzonerzy

proposal here would probably just be to tack on a '--json' flag to any of the commands vs default of table output

eyberg avatar Jan 18 '22 18:01 eyberg

need to remove the RunConfig.JSON bool and put it somewhere else (possibly in a new struct that interacts with the various flags)

eyberg avatar Jan 29 '23 19:01 eyberg