Containerd client integration

This commit:
1) Replaces the usage of containerd GRPC APIs with the containerd client for all operations related to containerd.
2) Updated containerd to v1.0alpha4+
3) Updated runc to v1.0.0

Signed-off-by: Abhinandan Prativadi <abhi@docker.com>
This commit is contained in:
Abhinandan Prativadi
2017-08-04 09:55:36 -07:00
parent 2427d332f0
commit 32e0313418
170 changed files with 5819 additions and 7262 deletions

View File

@@ -20,7 +20,6 @@ import (
"fmt"
"golang.org/x/net/context"
healthapi "google.golang.org/grpc/health/grpc_health_v1"
"k8s.io/kubernetes/pkg/kubelet/apis/cri/v1alpha1/runtime"
)
@@ -38,9 +37,8 @@ func (c *criContainerdService) Status(ctx context.Context, r *runtime.StatusRequ
Type: runtime.RuntimeReady,
Status: true,
}
// Use containerd grpc server healthcheck service to check its readiness.
resp, err := c.healthService.Check(ctx, &healthapi.HealthCheckRequest{})
if err != nil || resp.Status != healthapi.HealthCheckResponse_SERVING {
serving, err := c.client.IsServing(ctx)
if err != nil || !serving {
runtimeCondition.Status = false
runtimeCondition.Reason = runtimeNotReadyReason
if err != nil {
@@ -49,7 +47,6 @@ func (c *criContainerdService) Status(ctx context.Context, r *runtime.StatusRequ
runtimeCondition.Message = "Containerd grpc server is not serving"
}
}
networkCondition := &runtime.RuntimeCondition{
Type: runtime.NetworkReady,
Status: true,