hyperhq / runv

Hypervisor-based Runtime for OCI
Apache License 2.0
828 stars 129 forks source link

update runv state to match OCI definition #562

Closed bergwolf closed 7 years ago

bergwolf commented 7 years ago

Per https://github.com/opencontainers/runtime-spec/blob/master/runtime.md, runv state should return something like:

{
    "ociVersion": "0.2.0",
    "id": "oci-container1",
    "status": "running",
    "pid": 4422,
    "bundle": "/containers/redis",
    "annotations": {
        "myKey": "myValue"
    }
}

So we return:

$sudo runv --root /run/containerd/runc/default state foobar
{
  "ociVersion": "1.0.0",
  "id": "foobar",
  "pid": 95193,
  "bundle": "/run/containerd/io.containerd.runtime.v1.linux/default/foobar",
  "status": "running",
  "annotations": null
}
bergwolf commented 7 years ago

dropped.