Whamcloud - gitweb
LU-7854 gss: install lgssc.conf under /etc/request-key.d/ 17/31317/4
authorSebastien Buisson <sbuisson@ddn.com>
Thu, 15 Feb 2018 14:24:37 +0000 (23:24 +0900)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 15 Mar 2018 13:54:48 +0000 (13:54 +0000)
GSS keys for Lustre are generated via the lgss_keyring user-space
tool. But request-key system tool needs to know how to call
lgss_keyring in order to generate keys for Lustre.
This is done by adding the file lgssc.conf file under
/etc/request-key.d/, with the following content:
create lgssc * * /usr/sbin/lgss_keyring %o %k %t %d %c %u %g %T %P %S

This file is not packaged if gss keyring is explicitely disabled at
configure time.

Test-Parameters: trivial
Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Change-Id: Ibf2eb04584f6a100a57bf00070335cf4cf2c620c
Reviewed-on: https://review.whamcloud.com/31317
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Jeremy Filizetti <jeremy.filizetti@gmail.com>
Reviewed-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre.spec.in
lustre/conf/Makefile.am
lustre/conf/lgssc.conf [new file with mode: 0644]

index 9723eb8..89f45ea 100644 (file)
@@ -379,6 +379,11 @@ echo '%{_sysconfdir}/init.d/lnet' >>lustre.files
 %endif
 %endif
 
 %endif
 %endif
 
+CONFIGURE_ARGS="%{?configure_args}"
+if [ -z "$(echo $CONFIGURE_ARGS | grep "\-\-disable\-gss\-keyring")" ]; then
+    echo '%config(noreplace) %{_sysconfdir}/request-key.d/lgssc.conf' >>lustre.files
+fi
+
 %if %{with servers}
 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib/ocf/resource.d/lustre/
 install -m 0755 contrib/scripts/pacemaker/* $RPM_BUILD_ROOT%{_prefix}/lib/ocf/resource.d/lustre/
 %if %{with servers}
 mkdir -p $RPM_BUILD_ROOT%{_prefix}/lib/ocf/resource.d/lustre/
 install -m 0755 contrib/scripts/pacemaker/* $RPM_BUILD_ROOT%{_prefix}/lib/ocf/resource.d/lustre/
index 59b1005..d452924 100644 (file)
@@ -34,7 +34,7 @@
 
 EXTRA_DIST = lustre.dtd slapd-lustre.conf lustre2ldif.xsl top.ldif \
              99-lustre.rules lustre ldev.conf ko2iblnd.conf lsvcgss \
 
 EXTRA_DIST = lustre.dtd slapd-lustre.conf lustre2ldif.xsl top.ldif \
              99-lustre.rules lustre ldev.conf ko2iblnd.conf lsvcgss \
-             lnet_routes.conf lnet.conf
+             lnet_routes.conf lnet.conf lgssc.conf
 ldapconfdir = $(sysconfdir)/openldap
 
 sysconf_DATA = lnet.conf
 ldapconfdir = $(sysconfdir)/openldap
 
 sysconf_DATA = lnet.conf
@@ -63,3 +63,8 @@ endif
 
 modprobedir = $(sysconfdir)/modprobe.d
 modprobe_DATA = ko2iblnd.conf
 
 modprobedir = $(sysconfdir)/modprobe.d
 modprobe_DATA = ko2iblnd.conf
+
+if GSS_KEYRING
+requestkeydir = $(sysconfdir)/request-key.d
+requestkey_DATA = lgssc.conf
+endif
diff --git a/lustre/conf/lgssc.conf b/lustre/conf/lgssc.conf
new file mode 100644 (file)
index 0000000..0b7b15a
--- /dev/null
@@ -0,0 +1 @@
+create lgssc * * /usr/sbin/lgss_keyring %o %k %t %d %c %u %g %T %P %S