update generate functions
Signed-off-by: Haiyan Meng <hmeng@redhat.com>
This commit is contained in:
parent
18112081c2
commit
0bb2fb04d9
1 changed files with 2 additions and 7 deletions
|
@ -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.
|
||||||
|
|
Loading…
Reference in a new issue