SmolBox.Machine (SmolBox v0.1.0)

Copy Markdown View Source

Validated observation of an offline disposable machine.

Additive response fields are ignored. Safety-relevant fields must be present; enabled networking, mounts, ports, GPU or CUDA fail decoding and cannot be treated as an owned machine observation. created_at has only second precision upstream and is not a cryptographic or immutable ownership token.

Summary

Functions

Compare creation evidence and allocations; requires exclusive namespace control.

Types

t()

@type t() :: %SmolBox.Machine{
  cpus: pos_integer(),
  created_at: non_neg_integer(),
  memory_mb: pos_integer(),
  name: String.t(),
  overlay_gb: pos_integer(),
  state: :created | :running | :stopped,
  storage_gb: pos_integer()
}

Functions

from_wire(arg1)

@spec from_wire(term()) :: {:ok, t()} | {:error, SmolBox.Error.t()}

same_incarnation?(expected, observed)

@spec same_incarnation?(t(), t()) :: boolean()

Compare creation evidence and allocations; requires exclusive namespace control.