From 969c260d284d50060f42464b454314258f995e58 Mon Sep 17 00:00:00 2001
From: Markos Chandras <mchandras@suse.de>
Date: Wed, 16 Aug 2017 06:19:34 +0100
Subject: bifrost: scripts: Disable selinux on Centos7

We are seeing issues with selinux enabled from time to time. Having
selinux enabled has proven to be rather unstable and Centos7 not being
a gate on upstream bifrost does not help in fully testing this scenario.
As such, the best we can do right now is to disable selinux until Centos7
becomes a gate upstream.

Change-Id: I93a3414cfebc3c3ef4ac063c8e623f36f615455f
Signed-off-by: Markos Chandras <mchandras@suse.de>
---
 bifrost/scripts/bifrost-provision.sh | 10 ++++++++++
 1 file changed, 10 insertions(+)

(limited to 'bifrost')

diff --git a/bifrost/scripts/bifrost-provision.sh b/bifrost/scripts/bifrost-provision.sh
index 2b902152..ad028070 100755
--- a/bifrost/scripts/bifrost-provision.sh
+++ b/bifrost/scripts/bifrost-provision.sh
@@ -94,6 +94,16 @@ for task in syntax-check list-tasks; do
            -e testing_user=${TESTING_USER}
 done
 
+# NOTE(hwoarang): Disable selinux as we are hitting issues with it from time to
+# time. Remove this when Centos7 is a proper gate on bifrost so we know that
+# selinux works as expected.
+if [[ -e /etc/centos-release ]]; then
+    echo "*************************************"
+    echo "WARNING: Disabling selinux on CentOS7"
+    echo "*************************************"
+    sudo setenforce 0
+fi
+
 # Create the VMS
 ${ANSIBLE} ${ANSIBLE_VERBOSITY} \
        -i inventory/localhost \
-- 
cgit