new changes
This commit is contained in:
22
control-plane-go/pkg/contracts/command.go
Normal file
22
control-plane-go/pkg/contracts/command.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package contracts
|
||||
|
||||
type CommandEnvelope struct {
|
||||
CommandID string `json:"cmd_id"`
|
||||
JobID string `json:"job_id"`
|
||||
TenantID string `json:"tenant_id"`
|
||||
ServerID string `json:"server_id"`
|
||||
Type string `json:"type"`
|
||||
Args map[string]any `json:"args"`
|
||||
TimeoutSec int `json:"timeout_sec"`
|
||||
IdempotencyKey string `json:"idempotency_key"`
|
||||
RequiredCaps []string `json:"required_capabilities"`
|
||||
RequestedByUserID string `json:"requested_by_user_id"`
|
||||
}
|
||||
|
||||
type CommandResult struct {
|
||||
CommandID string `json:"cmd_id"`
|
||||
Status string `json:"status"`
|
||||
ExitCode int `json:"exit_code"`
|
||||
Output map[string]any `json:"output"`
|
||||
Error string `json:"error,omitempty"`
|
||||
}
|
||||
Reference in New Issue
Block a user