pub struct ContainerInfo {Show 19 fields
pub sandbox_id: String,
pub id: String,
pub engine: String,
pub vm_hosted: bool,
pub name: String,
pub image: String,
pub state: String,
pub status_text: String,
pub created_ms: Option<u64>,
pub started_ms: Option<u64>,
pub finished_ms: Option<u64>,
pub exit_code: Option<i64>,
pub oom_killed: Option<bool>,
pub restart_count: Option<u32>,
pub cpu_total_ns: Option<u64>,
pub stats_at_ms: Option<u64>,
pub size_rw: Option<u64>,
pub size_root_fs: Option<u64>,
pub labels: BTreeMap<String, String>,
}Expand description
What a container engine (Docker API: Docker, Docker Desktop, OrbStack, Colima, Rancher Desktop, Podman)
reports about one container, running or not. Running containers are also crate::model::Sandboxes
with the same sandbox_id.
Fields§
§sandbox_id: String<runtime>:<12 hex>, as crate::model::Sandbox::id.
id: StringFull container id.
engine: StringEngine runtime (“docker”, “docker-desktop”, “orbstack”, “colima”, “rancher-desktop”, “podman”).
vm_hosted: boolThe engine runs containers inside a VM (its host cost is the VM’s).
name: String§image: String§state: String“running” | “exited” | “created” | “paused” | “restarting” | “dead”.
status_text: StringEngine status text (“Up 3 hours”, “Exited (137) 2 days ago”).
created_ms: Option<u64>§started_ms: Option<u64>§finished_ms: Option<u64>§exit_code: Option<i64>§oom_killed: Option<bool>State.OOMKilled: the container’s last run ended in a kernel OOM kill.
restart_count: Option<u32>§cpu_total_ns: Option<u64>Cumulative CPU time (cpu_stats.cpu_usage.total_usage, ns) and when it was read.
stats_at_ms: Option<u64>§size_rw: Option<u64>Writable layer / whole filesystem size, only when the engine reported them (size=1 listings).
size_root_fs: Option<u64>§labels: BTreeMap<String, String>Allowlisted labels only (LABEL_PREFIXES).