Commit Graph

6 Commits

Author SHA1 Message Date
Niels de Vos
8d9961e637 build: add --without-server option
With Gluster 4.0 we will not provide the server components for EL6 and
older. At one point Gluster 4.x will get GlusterD2, which requires
Golang tools in the distribution. EL6 does not contain these at the
moment.

With this change, it is possible to `./configure --without-server` which
prevents building glusterd and the xlators for the bricks. Building RPMs
can pass `--without server` and the glusterfs-server sub-package will
not be created.

Change-Id: I97f5ccf9f2c76e60d9af83915fc59fae57ad6d25
BUG: 1074947
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2018-02-19 17:38:55 +00:00
Milan Zink
f9e6be05bc extras/hooks: Fix S10selinux-label-brick.sh hook script
* script was failng due to syntax error
* shellcheck issues fixed
* improved performance: semanage & restorecon is being run on unique path

Change-Id: I58b357d9fd37586004a2a518f7a5d1c5c9ddd7e3
BUG: 1533342
Signed-off-by: Milan Zink <zeten30@gmail.com>
2018-01-31 07:03:58 +00:00
Anoop C S
39ac511a5d extras/hooks: Fix getopt usage
`getopt` does not have an optional argument as '-name'. It should
be either '-n' or '--name'(see man getopt(1)). This wrong usage
resulted in setting the script name as 'ame' instead of $PROGNAME
in most of the hook-scripts.

Additionally the following line from DESCRIPTION given for `getopt`
shell command expects short options for almost every kind of usage
mentioned in SYNOPSIS:

. . .
If  no  '-o'  or '--options' option is found in the first part, the
first parameter of the second part is used as the short options string.
. . .

Refer http://man7.org/linux/man-pages/man1/getopt.1.html for more
clarity on its usage.

Change-Id: I95baf5fa8c99025e66b2d83656dd838d4f6048ce
BUG: 1503983
Signed-off-by: Anoop C S <anoopcs@redhat.com>
2017-10-30 15:49:02 +00:00
Anoop C S
087703fae4 extras/hooks: Fix errors reported via shellcheck utility
Change-Id: I217c6b2a39955f1709bb3452b00d33c2dcb60faa
BUG: 1500649
Signed-off-by: Anoop C S <anoopcs@redhat.com>
2017-10-18 14:27:41 +00:00
Kaleb S. KEITHLEY
be28cbc5f8 extras/hookscripts: non-portable shell syntax
use of "function" is not portable to other shells

Reported-by: Patrick Matthäi <pmatthaei@debian.org>
Change-Id: I13a0482b387cc3b7a7a57df424e673850603da37
BUG: 1457812
Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com>
Reviewed-on: https://review.gluster.org/17443
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.org>
2017-06-02 12:13:33 +00:00
Brian Foster
859669759f extras/hook-scripts: SELinux brick file context management scripts
The SELinux policy for gluster defines the glusterd_brick_t type to
support server side SELinux (e.g., server side labels). Add
convenience hook scripts that users/packagers can install to ensure
that new bricks are labeled correctly.

The volume create hook script adds a new SELinux file context for
each brick path and runs a restorecon to label the brick. The
volume delete hook removes the per-brick SELinux file context.

Change-Id: I5f102db5382d813c4d822ff74e873a7a669b41db
BUG: 1047975
Signed-off-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com>
Reviewed-on: https://review.gluster.org/6630
Smoke: Gluster Build System <jenkins@build.gluster.org>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
2017-05-01 09:30:01 +00:00