mirror of
https://github.com/getcompanion-ai/computer-host.git
synced 2026-04-15 03:00:42 +00:00
* feat: host daemon api scaffold * fix: use sparse writes * fix: unix socket length (<108 bytes)
27 lines
653 B
Go
27 lines
653 B
Go
package firecracker
|
|
|
|
import "time"
|
|
|
|
// Phase represents the lifecycle phase of a local microVM.
|
|
type Phase string
|
|
|
|
// MachineState describes the current host local state for a machine.
|
|
type MachineState struct {
|
|
ID MachineID
|
|
Phase Phase
|
|
PID int
|
|
RuntimeHost string
|
|
SocketPath string
|
|
TapName string
|
|
StartedAt *time.Time
|
|
Error string
|
|
}
|
|
|
|
const (
|
|
// PhaseRunning means the Firecracker process is live.
|
|
PhaseRunning Phase = "running"
|
|
// PhaseStopped means the VM is no longer running.
|
|
PhaseStopped Phase = "stopped"
|
|
// PhaseFailed means the runtime observed a terminal failure.
|
|
PhaseFailed Phase = "failed"
|
|
)
|