From b405629e68fef0350fcdf4b17a4417ce1ef3209e Mon Sep 17 00:00:00 2001 From: Yifan Gu Date: Mon, 26 Sep 2016 14:32:59 -0700 Subject: [PATCH] CRI: Add more docs abount pod sandbox config in CreateContainerRequest. Makes it clear that the config will not change during the pod lifecycle. The field is only for convenience. --- pkg/kubelet/api/v1alpha1/runtime/api.pb.go | 5 ++++- pkg/kubelet/api/v1alpha1/runtime/api.proto | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/pkg/kubelet/api/v1alpha1/runtime/api.pb.go b/pkg/kubelet/api/v1alpha1/runtime/api.pb.go index c53f283a6f..61bfbaaa8a 100644 --- a/pkg/kubelet/api/v1alpha1/runtime/api.pb.go +++ b/pkg/kubelet/api/v1alpha1/runtime/api.pb.go @@ -1523,7 +1523,10 @@ type CreateContainerRequest struct { PodSandboxId *string `protobuf:"bytes,1,opt,name=pod_sandbox_id,json=podSandboxId" json:"pod_sandbox_id,omitempty"` // The config of the container Config *ContainerConfig `protobuf:"bytes,2,opt,name=config" json:"config,omitempty"` - // The config of the PodSandbox + // The config of the PodSandbox. This is the same config that was passed + // to RunPodSandboxRequest to create the PodSandbox. It is passed again + // here just for easy reference. The PodSandboxConfig is immutable and + // remains the same throughout the lifetime of the pod. SandboxConfig *PodSandboxConfig `protobuf:"bytes,3,opt,name=sandbox_config,json=sandboxConfig" json:"sandbox_config,omitempty"` XXX_unrecognized []byte `json:"-"` } diff --git a/pkg/kubelet/api/v1alpha1/runtime/api.proto b/pkg/kubelet/api/v1alpha1/runtime/api.proto index 4c623d9eaf..9a07b8e06a 100644 --- a/pkg/kubelet/api/v1alpha1/runtime/api.proto +++ b/pkg/kubelet/api/v1alpha1/runtime/api.proto @@ -456,7 +456,10 @@ message CreateContainerRequest { optional string pod_sandbox_id = 1; // The config of the container optional ContainerConfig config = 2; - // The config of the PodSandbox + // The config of the PodSandbox. This is the same config that was passed + // to RunPodSandboxRequest to create the PodSandbox. It is passed again + // here just for easy reference. The PodSandboxConfig is immutable and + // remains the same throughout the lifetime of the pod. optional PodSandboxConfig sandbox_config = 3; }