update generate functions

Signed-off-by: Haiyan Meng <hmeng@redhat.com>
This commit is contained in:
Haiyan Meng 2016-08-01 18:43:24 -04:00 committed by Mrunal Patel
parent 18112081c2
commit 0bb2fb04d9

View file

@ -83,9 +83,7 @@ func (s *Server) CreatePodSandbox(ctx context.Context, req *pb.CreatePodSandboxR
return nil, err return nil, err
} }
if err := g.AddBindMount(fmt.Sprintf("%s:/etc/resolv.conf", resolvPath)); err != nil { g.AddBindMount(resolvPath, "/etc/resolv.conf", "ro")
return nil, err
}
labels := req.GetConfig().GetLabels() labels := req.GetConfig().GetLabels()
s.sandboxes = append(s.sandboxes, &sandbox{ s.sandboxes = append(s.sandboxes, &sandbox{
@ -96,10 +94,7 @@ func (s *Server) CreatePodSandbox(ctx context.Context, req *pb.CreatePodSandboxR
annotations := req.GetConfig().GetAnnotations() annotations := req.GetConfig().GetAnnotations()
for k, v := range annotations { for k, v := range annotations {
err := g.AddAnnotation(fmt.Sprintf("%s=%s", k, v)) g.AddAnnotation(k, v)
if err != nil {
return nil, err
}
} }
// TODO: double check cgroupParent. // TODO: double check cgroupParent.