summaryrefslogtreecommitdiff
path: root/share/hooks/lxc/1050-selinux.hook.chroot
diff options
context:
space:
mode:
Diffstat (limited to 'share/hooks/lxc/1050-selinux.hook.chroot')
-rwxr-xr-xshare/hooks/lxc/1050-selinux.hook.chroot8
1 files changed, 8 insertions, 0 deletions
diff --git a/share/hooks/lxc/1050-selinux.hook.chroot b/share/hooks/lxc/1050-selinux.hook.chroot
new file mode 100755
index 000000000..450f61911
--- /dev/null
+++ b/share/hooks/lxc/1050-selinux.hook.chroot
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+set -e
+
+# Disable SELinux
+mkdir -p /sys/fs/selinux
+echo 0 > /sys/fs/selinux/enforce.tmp
+mv /sys/fs/selinux/enforce.tmp /sys/fs/selinux/enforce