summaryrefslogtreecommitdiff
path: root/libpod/runtime_ctr.go
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@gmail.com>2018-08-08 16:27:48 -0400
committerAtomic Bot <atomic-devel@projectatomic.io>2018-08-08 21:03:20 +0000
commit9bd991f477ab2bb4428df6286452516c3deb970e (patch)
treed7fdad97dfbfe496183fcfb06be48f67c41077a7 /libpod/runtime_ctr.go
parentbb45de5605e263cba6d869eeba5426551c940346 (diff)
downloadpodman-9bd991f477ab2bb4428df6286452516c3deb970e.tar.gz
podman-9bd991f477ab2bb4428df6286452516c3deb970e.tar.bz2
podman-9bd991f477ab2bb4428df6286452516c3deb970e.zip
Fix CGroupFS cgroup manager cgroup creation for pods
Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #1237 Approved by: rhatdan
Diffstat (limited to 'libpod/runtime_ctr.go')
-rw-r--r--libpod/runtime_ctr.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/libpod/runtime_ctr.go b/libpod/runtime_ctr.go
index 709775e4a..ffad9d649 100644
--- a/libpod/runtime_ctr.go
+++ b/libpod/runtime_ctr.go
@@ -85,6 +85,9 @@ func (r *Runtime) NewContainer(ctx context.Context, rSpec *spec.Spec, options ..
if err != nil {
return nil, errors.Wrapf(err, "error retrieving pod %s cgroup", pod.ID())
}
+ if podCgroup == "" {
+ return nil, errors.Wrapf(ErrInternal, "pod %s cgroup is not set", pod.ID())
+ }
ctr.config.CgroupParent = podCgroup
} else {
ctr.config.CgroupParent = CgroupfsDefaultCgroupParent