summaryrefslogtreecommitdiff
path: root/libpod/options.go
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@gmail.com>2018-03-21 12:19:26 -0400
committerAtomic Bot <atomic-devel@projectatomic.io>2018-05-11 14:43:57 +0000
commit853c5c41f1a0f65815674cce0777a20de24c8309 (patch)
tree76d7c1569b1a08f2b0b738c9a96e7f8fceb4b254 /libpod/options.go
parentdf83d361e4fe3c1fc1939b096cb21aa2e7ec3d74 (diff)
downloadpodman-853c5c41f1a0f65815674cce0777a20de24c8309.tar.gz
podman-853c5c41f1a0f65815674cce0777a20de24c8309.tar.bz2
podman-853c5c41f1a0f65815674cce0777a20de24c8309.zip
Add --cgroup-manager flag to Podman binary
Signed-off-by: Matthew Heon <matthew.heon@gmail.com> Closes: #507 Approved by: baude
Diffstat (limited to 'libpod/options.go')
-rw-r--r--libpod/options.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/libpod/options.go b/libpod/options.go
index 2b3ad2eb4..90b376668 100644
--- a/libpod/options.go
+++ b/libpod/options.go
@@ -152,6 +152,11 @@ func WithCgroupManager(manager string) RuntimeOption {
return ErrRuntimeFinalized
}
+ if manager != CgroupfsCgroupsManager && manager != SystemdCgroupsManager {
+ return errors.Wrapf(ErrInvalidArg, "CGroup manager must be one of %s and %s",
+ CgroupfsCgroupsManager, SystemdCgroupsManager)
+ }
+
rt.config.CgroupManager = manager
return nil