Update to the latest upstream API
Signed-off-by: Mrunal Patel <mpatel@redhat.com>
This commit is contained in:
parent
9540eb9d2b
commit
b62a150151
21 changed files with 2723 additions and 1306 deletions
|
@ -405,16 +405,16 @@ func ListContainers(client pb.RuntimeServiceClient, opts listOptions) error {
|
|||
filter.PodSandboxId = &opts.podID
|
||||
}
|
||||
if opts.state != "" {
|
||||
st := pb.ContainerState_UNKNOWN
|
||||
st := pb.ContainerState_CONTAINER_UNKNOWN
|
||||
switch opts.state {
|
||||
case "created":
|
||||
st = pb.ContainerState_CREATED
|
||||
st = pb.ContainerState_CONTAINER_CREATED
|
||||
filter.State = &st
|
||||
case "running":
|
||||
st = pb.ContainerState_RUNNING
|
||||
st = pb.ContainerState_CONTAINER_RUNNING
|
||||
filter.State = &st
|
||||
case "stopped":
|
||||
st = pb.ContainerState_EXITED
|
||||
st = pb.ContainerState_CONTAINER_EXITED
|
||||
filter.State = &st
|
||||
default:
|
||||
log.Fatalf("--state should be one of created, running or stopped")
|
||||
|
|
|
@ -324,13 +324,13 @@ func ListPodSandboxes(client pb.RuntimeServiceClient, opts listOptions) error {
|
|||
filter.Id = &opts.id
|
||||
}
|
||||
if opts.state != "" {
|
||||
st := pb.PodSandBoxState_NOTREADY
|
||||
st := pb.PodSandboxState_SANDBOX_NOTREADY
|
||||
switch opts.state {
|
||||
case "ready":
|
||||
st = pb.PodSandBoxState_READY
|
||||
st = pb.PodSandboxState_SANDBOX_READY
|
||||
filter.State = &st
|
||||
case "notready":
|
||||
st = pb.PodSandBoxState_NOTREADY
|
||||
st = pb.PodSandboxState_SANDBOX_NOTREADY
|
||||
filter.State = &st
|
||||
default:
|
||||
log.Fatalf("--state should be ready or notready")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue