Configure SELinux with Swarm
This procedure describes how to configure SELinux on a machine on which Cyberwatch is deployed. Only CentOS and Red Hat Enterprise Linux operating systems are supported.
Ensure that Cyberwatch is deployed and functional.
Enable SELinux on the machine.
Set the
SELINUX
variable toenforcing
in file/etc/selinux/config
:-SELINUX=disabled +SELINUX=enforcing
Reboot the machine:
sudo reboot
Verify that SELinux is enabled:
sestatus
The output should contain:
SELinux status: enabled Current mode: enforcing
Install package
container-selinux
:sudo yum install container-selinux
Enable
container_manage_cgroup
SELinux boolean:sudo setsebool container_manage_cgroup 1
Add
"selinux-enabled": true
in file/etc/docker/daemon.json
:+{ + "selinux-enabled": true +}
Restart Docker:
sudo systemctl restart docker