233933
From 421743b7cfa6a249544f6abb4cca5a612bd20ea1 Mon Sep 17 00:00:00 2001
233933
From: Atin Mukherjee <amukherj@redhat.com>
233933
Date: Tue, 11 Dec 2018 16:21:43 +0530
233933
Subject: [PATCH 23/52] hooks: remove selinux hooks
233933
233933
Label: DOWNSTREAM ONLY
233933
233933
Change-Id: I810466a0ca99ab21f5a8eac8cdffbb18333d10ad
233933
Signed-off-by: Atin Mukherjee <amukherj@redhat.com>
233933
Reviewed-on: https://code.engineering.redhat.com/gerrit/135800
233933
Tested-by: RHGS Build Bot <nigelb@redhat.com>
233933
Reviewed-by: Jiffin Thottan <jthottan@redhat.com>
233933
Reviewed-by: Milind Changire <mchangir@redhat.com>
233933
---
233933
 configure.ac                                | 20 --------------------
233933
 extras/hook-scripts/Makefile.am             |  2 +-
233933
 extras/hook-scripts/create/Makefile.am      |  1 -
233933
 extras/hook-scripts/create/post/Makefile.am |  8 --------
233933
 extras/hook-scripts/delete/Makefile.am      |  1 -
233933
 extras/hook-scripts/delete/pre/Makefile.am  |  8 --------
233933
 glusterfs.spec.in                           |  2 --
233933
 7 files changed, 1 insertion(+), 41 deletions(-)
233933
 delete mode 100644 extras/hook-scripts/create/Makefile.am
233933
 delete mode 100644 extras/hook-scripts/create/post/Makefile.am
233933
 delete mode 100644 extras/hook-scripts/delete/Makefile.am
233933
 delete mode 100644 extras/hook-scripts/delete/pre/Makefile.am
233933
233933
diff --git a/configure.ac b/configure.ac
233933
index 2f341de..0d06f5a 100644
233933
--- a/configure.ac
233933
+++ b/configure.ac
233933
@@ -214,10 +214,6 @@ AC_CONFIG_FILES([Makefile
233933
                 extras/hook-scripts/add-brick/Makefile
233933
                 extras/hook-scripts/add-brick/pre/Makefile
233933
                 extras/hook-scripts/add-brick/post/Makefile
233933
-                extras/hook-scripts/create/Makefile
233933
-                extras/hook-scripts/create/post/Makefile
233933
-                extras/hook-scripts/delete/Makefile
233933
-                extras/hook-scripts/delete/pre/Makefile
233933
                 extras/hook-scripts/start/Makefile
233933
                 extras/hook-scripts/start/post/Makefile
233933
                 extras/hook-scripts/set/Makefile
233933
@@ -909,21 +905,6 @@ fi
233933
 AM_CONDITIONAL([BUILD_CLOUDSYNC], [test "x$BUILD_CLOUDSYNC" = "xyes"])
233933
 dnl end cloudsync section
233933
 
233933
-dnl SELinux feature enablement
233933
-case $host_os in
233933
-  linux*)
233933
-    AC_ARG_ENABLE([selinux],
233933
-                  AC_HELP_STRING([--disable-selinux],
233933
-                                 [Disable SELinux features]),
233933
-                  [USE_SELINUX="${enableval}"], [USE_SELINUX="yes"])
233933
-    ;;
233933
-  *)
233933
-    USE_SELINUX=no
233933
-    ;;
233933
-esac
233933
-AM_CONDITIONAL(USE_SELINUX, test "x${USE_SELINUX}" = "xyes")
233933
-dnl end of SELinux feature enablement
233933
-
233933
 AC_CHECK_HEADERS([execinfo.h], [have_backtrace=yes])
233933
 if test "x${have_backtrace}" = "xyes"; then
233933
    AC_DEFINE(HAVE_BACKTRACE, 1, [define if found backtrace])
233933
@@ -1599,7 +1580,6 @@ echo "XML output           : $BUILD_XML_OUTPUT"
233933
 echo "Unit Tests           : $BUILD_UNITTEST"
233933
 echo "Track priv ports     : $TRACK_PRIVPORTS"
233933
 echo "POSIX ACLs           : $BUILD_POSIX_ACLS"
233933
-echo "SELinux features     : $USE_SELINUX"
233933
 echo "firewalld-config     : $BUILD_FIREWALLD"
233933
 echo "Events               : $BUILD_EVENTS"
233933
 echo "EC dynamic support   : $EC_DYNAMIC_SUPPORT"
233933
diff --git a/extras/hook-scripts/Makefile.am b/extras/hook-scripts/Makefile.am
233933
index 26059d7..771b37e 100644
233933
--- a/extras/hook-scripts/Makefile.am
233933
+++ b/extras/hook-scripts/Makefile.am
233933
@@ -1,5 +1,5 @@
233933
 EXTRA_DIST = S40ufo-stop.py S56glusterd-geo-rep-create-post.sh
233933
-SUBDIRS = add-brick create delete set start stop reset
233933
+SUBDIRS = add-brick set start stop reset
233933
 
233933
 scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/gsync-create/post/
233933
 if USE_GEOREP
233933
diff --git a/extras/hook-scripts/create/Makefile.am b/extras/hook-scripts/create/Makefile.am
233933
deleted file mode 100644
233933
index b083a91..0000000
233933
--- a/extras/hook-scripts/create/Makefile.am
233933
+++ /dev/null
233933
@@ -1 +0,0 @@
233933
-SUBDIRS = post
233933
diff --git a/extras/hook-scripts/create/post/Makefile.am b/extras/hook-scripts/create/post/Makefile.am
233933
deleted file mode 100644
233933
index fd1892e..0000000
233933
--- a/extras/hook-scripts/create/post/Makefile.am
233933
+++ /dev/null
233933
@@ -1,8 +0,0 @@
233933
-EXTRA_DIST = S10selinux-label-brick.sh
233933
-
233933
-scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/create/post/
233933
-if WITH_SERVER
233933
-if USE_SELINUX
233933
-scripts_SCRIPTS = S10selinux-label-brick.sh
233933
-endif
233933
-endif
233933
diff --git a/extras/hook-scripts/delete/Makefile.am b/extras/hook-scripts/delete/Makefile.am
233933
deleted file mode 100644
233933
index c98a05d..0000000
233933
--- a/extras/hook-scripts/delete/Makefile.am
233933
+++ /dev/null
233933
@@ -1 +0,0 @@
233933
-SUBDIRS = pre
233933
diff --git a/extras/hook-scripts/delete/pre/Makefile.am b/extras/hook-scripts/delete/pre/Makefile.am
233933
deleted file mode 100644
233933
index 4fbfbe7..0000000
233933
--- a/extras/hook-scripts/delete/pre/Makefile.am
233933
+++ /dev/null
233933
@@ -1,8 +0,0 @@
233933
-EXTRA_DIST = S10selinux-del-fcontext.sh
233933
-
233933
-scriptsdir = $(GLUSTERD_WORKDIR)/hooks/1/delete/pre/
233933
-if WITH_SERVER
233933
-if USE_SELINUX
233933
-scripts_SCRIPTS = S10selinux-del-fcontext.sh
233933
-endif
233933
-endif
233933
diff --git a/glusterfs.spec.in b/glusterfs.spec.in
233933
index ec06176..db50b8e 100644
233933
--- a/glusterfs.spec.in
233933
+++ b/glusterfs.spec.in
233933
@@ -1413,7 +1413,6 @@ exit 0
233933
             %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/add-brick/pre/S28Quota-enable-root-xattr-heal.sh
233933
        %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create
233933
        %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/post
233933
-            %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/post/S10selinux-label-brick.sh
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/create/pre
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/copy-file
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/copy-file/post
233933
@@ -1422,7 +1421,6 @@ exit 0
233933
        %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/post
233933
                             %{_sharedstatedir}/glusterd/hooks/1/delete/post/S57glusterfind-delete-post
233933
        %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/pre
233933
-            %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/delete/pre/S10selinux-del-fcontext.sh
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick/post
233933
 %ghost %dir %attr(0755,-,-) %{_sharedstatedir}/glusterd/hooks/1/remove-brick/pre
233933
-- 
233933
1.8.3.1
233933