From b7ba9d058beae76dfbbab82bcfa79f435b59d1f6 Mon Sep 17 00:00:00 2001 From: Antonio Murdaca Date: Mon, 8 May 2017 09:15:00 +0200 Subject: [PATCH] server: store kubeName in annotations Signed-off-by: Antonio Murdaca --- server/sandbox_run.go | 1 + server/server.go | 1 + 2 files changed, 2 insertions(+) diff --git a/server/sandbox_run.go b/server/sandbox_run.go index 88797343..a43bd55f 100644 --- a/server/sandbox_run.go +++ b/server/sandbox_run.go @@ -265,6 +265,7 @@ func (s *Server) RunPodSandbox(ctx context.Context, req *pb.RunPodSandboxRequest g.AddAnnotation("ocid/privileged_runtime", fmt.Sprintf("%v", privileged)) g.AddAnnotation("ocid/resolv_path", resolvPath) g.AddAnnotation("ocid/hostname", hostname) + g.AddAnnotation("ocid/kube_name", kubeName) sb := &sandbox{ id: id, diff --git a/server/server.go b/server/server.go index ff265197..2fe7e3ee 100644 --- a/server/server.go +++ b/server/server.go @@ -203,6 +203,7 @@ func (s *Server) loadSandbox(id string) error { sb := &sandbox{ id: id, name: name, + kubeName: m.Annotations["ocid/kube_name"], logDir: filepath.Dir(m.Annotations["ocid/log_path"]), labels: labels, containers: oci.NewMemoryStore(),