Commit 0449b008 authored by Derek Carr's avatar Derek Carr

dockershim puts pause container in pod cgroup

parent 6edd0790
...@@ -470,6 +470,16 @@ func (ds *dockerService) makeSandboxDockerConfig(c *runtimeapi.PodSandboxConfig, ...@@ -470,6 +470,16 @@ func (ds *dockerService) makeSandboxDockerConfig(c *runtimeapi.PodSandboxConfig,
// Apply resource options. // Apply resource options.
setSandboxResources(hc) setSandboxResources(hc)
// Apply cgroupsParent derived from the sandbox config.
if lc := c.GetLinux(); lc != nil {
// Apply Cgroup options.
cgroupParent, err := ds.GenerateExpectedCgroupParent(lc.CgroupParent)
if err != nil {
return nil, fmt.Errorf("failed to generate cgroup parent in expected syntax for container %q: %v", c.Metadata.Name, err)
}
hc.CgroupParent = cgroupParent
}
// Set security options. // Set security options.
securityOpts, err := getSandboxSecurityOpts(c, ds.seccompProfileRoot, securityOptSep) securityOpts, err := getSandboxSecurityOpts(c, ds.seccompProfileRoot, securityOptSep)
if err != nil { if err != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment