server/shared/types.go

21 lines
469 B
Go
Raw Permalink Normal View History

2020-12-11 20:32:30 +00:00
package shared
2020-12-11 20:23:16 +00:00
2020-12-11 20:32:30 +00:00
// Instruction is a structured way of sending commands
2020-12-11 20:23:16 +00:00
type Instruction struct {
Command string `json:"command"`
Args []string `json:"args"`
}
2020-12-11 20:32:30 +00:00
// CmdResponse is a response from the client to the server
2020-12-11 20:23:16 +00:00
type CmdResponse struct {
Stdout string `json:"stdout"`
Stderr string `json:"stderr"`
ExitCode int `json:"exitcode"`
}
2020-12-11 20:32:30 +00:00
// OSInfo needs a comment
2020-12-11 20:23:16 +00:00
type OSInfo struct {
OSType string `json:"os_type"`
OSArch string `json:"os_arch"`
}