add selinux category range to config
This allows an admin to set the upper bounds on the category range for selinux labels. This can be useful when handling allocation of PVs or other volume types that need to be shared with selinux enabled on the hosts and volumes. Signed-off-by: Michael Crosby <michael@thepasture.io>
This commit is contained in:
@@ -44,6 +44,9 @@ func (c *criService) initPlatform() error {
|
||||
if !selinux.GetEnabled() {
|
||||
logrus.Warn("Selinux is not supported")
|
||||
}
|
||||
if r := c.config.SelinuxCategoryRange; r > 0 {
|
||||
selinux.CategoryRange = uint32(r)
|
||||
}
|
||||
} else {
|
||||
selinux.SetDisabled()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user