MCPcopy Create free account
hub / github.com/containers/common / DeleteByPath

Method DeleteByPath

pkg/cgroups/cgroups.go:564–574  ·  view source on GitHub ↗

DeleteByPath deletes the specified cgroup path

(path string)

Source from the content-addressed store, hash-verified

562
563// DeleteByPath deletes the specified cgroup path
564func (c *CgroupControl) DeleteByPath(path string) error {
565 if c.systemd {
566 conn, err := systemdDbus.NewWithContext(context.TODO())
567 if err != nil {
568 return err
569 }
570 defer conn.Close()
571 return c.DeleteByPathConn(path, conn)
572 }
573 return c.DeleteByPathConn(path, nil)
574}
575
576// Update updates the cgroups
577func (c *CgroupControl) Update(resources *spec.LinuxResources) error {

Callers 1

DeleteMethod · 0.95

Calls 2

DeleteByPathConnMethod · 0.95
CloseMethod · 0.80

Tested by

no test coverage detected