diff options
Diffstat (limited to 'libpod/options.go')
-rw-r--r-- | libpod/options.go | 5 |
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 |