Change-Id: Ica19d3acfe1a4e4e230e18bce0a67f4ba28e7b09
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/4694
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Alexey Makhalov <amakhalov@vmware.com>
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,47 @@ |
0 |
+Summary: This library exports a gssapi interface |
|
1 |
+Name: libgssglue |
|
2 |
+Version: 0.4 |
|
3 |
+Release: 1%{?dist} |
|
4 |
+License: BSD |
|
5 |
+URL: http://www.citi.umich.edu/projects/nfsv4/linux/ |
|
6 |
+Group: System Environment/Libraries |
|
7 |
+Vendor: VMware, Inc. |
|
8 |
+Distribution: Photon |
|
9 |
+Source0: http://www.citi.umich.edu/projects/nfsv4/linux/libgssglue/%{name}-%{version}.tar.gz |
|
10 |
+%define sha1 libgssglue=a8edc4f6a1d4dcd80ad52d18226fc65fa8850af1 |
|
11 |
+ |
|
12 |
+%description |
|
13 |
+This library exports a gssapi interface, but doesn't implement any gssapi mechanisms itself; instead it calls gssapi routines in other libraries, depending on the mechanism. |
|
14 |
+ |
|
15 |
+%package devel |
|
16 |
+Summary: Header and development files |
|
17 |
+Requires: %{name} = %{version} |
|
18 |
+%description devel |
|
19 |
+It contains the libraries and header files to create applications |
|
20 |
+ |
|
21 |
+%prep |
|
22 |
+%setup -q |
|
23 |
+%build |
|
24 |
+./configure --prefix=/usr --disable-static |
|
25 |
+ |
|
26 |
+make %{?_smp_mflags} |
|
27 |
+ |
|
28 |
+%install |
|
29 |
+make DESTDIR=%{buildroot} install |
|
30 |
+find %{buildroot}/%{_libdir} -name '*.la' -delete |
|
31 |
+ |
|
32 |
+%post |
|
33 |
+ |
|
34 |
+%files |
|
35 |
+%defattr(-,root,root) |
|
36 |
+%{_libdir}/libgssglue.so.* |
|
37 |
+ |
|
38 |
+%files devel |
|
39 |
+%defattr(-,root,root) |
|
40 |
+%{_includedir}/* |
|
41 |
+%{_libdir}/libgssglue.so |
|
42 |
+%{_libdir}/pkgconfig/*.pc |
|
43 |
+ |
|
44 |
+%changelog |
|
45 |
+* Mon Jan 22 2018 Xiaolin Li <xiaolinl@vmware.com> 0.4-1 |
|
46 |
+- Initial build. First version |
0 | 47 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,63 @@ |
0 |
+Summary: NFS id mapping library |
|
1 |
+Name: libnfsidmap |
|
2 |
+Version: 0.25 |
|
3 |
+Release: 1%{?dist} |
|
4 |
+License: BSD |
|
5 |
+URL: http://www.citi.umich.edu/projects/nfsv4/linux/ |
|
6 |
+Group: System/Libraries |
|
7 |
+Vendor: VMware, Inc. |
|
8 |
+Distribution: Photon |
|
9 |
+Source0: http://www.citi.umich.edu/projects/nfsv4/linux/libnfsidmap/%{name}-%{version}.tar.gz |
|
10 |
+%define sha1 libnfsidmap=f52e143d33a3a8a8138be41a90f2cc956f1acea2 |
|
11 |
+ |
|
12 |
+%description |
|
13 |
+When NFSv4 is using AUTH_GSS (which currently only supports Kerberos v5), the |
|
14 |
+NFSv4 server mapping functions MUST use secure communications. |
|
15 |
+ |
|
16 |
+We provide several mapping functions, configured using /etc/idmapd.conf |
|
17 |
+ |
|
18 |
+As of the 0.21 version of this library, mapping methods are separate |
|
19 |
+dynamically-loaded libaries. This allows the separation of any |
|
20 |
+LDAP requirements from the main libnfsidmap library. The main library |
|
21 |
+now basically loads and calls the functions in the method-specific |
|
22 |
+libaries. The method libraries are expected to be named |
|
23 |
+"libnfsidmap_<method>.so", for example, "libnfsidmap_nsswitch.so". |
|
24 |
+ |
|
25 |
+Several methods may be specified in the /etc/idmapd.conf configuration |
|
26 |
+file. Each method is called until a mapping is found. |
|
27 |
+ |
|
28 |
+%package devel |
|
29 |
+Summary: Header and development files |
|
30 |
+Requires: %{name} = %{version} |
|
31 |
+%description devel |
|
32 |
+It contains the libraries and header files to create applications |
|
33 |
+ |
|
34 |
+%prep |
|
35 |
+%setup -q |
|
36 |
+%build |
|
37 |
+./configure --prefix=/usr --disable-static |
|
38 |
+ |
|
39 |
+make %{?_smp_mflags} |
|
40 |
+ |
|
41 |
+%install |
|
42 |
+make DESTDIR=%{buildroot} install |
|
43 |
+find %{buildroot}/%{_libdir} -name '*.la' -delete |
|
44 |
+ |
|
45 |
+%post |
|
46 |
+ |
|
47 |
+%files |
|
48 |
+%defattr(-,root,root) |
|
49 |
+%{_libdir}/libnfsidmap.so.* |
|
50 |
+%{_libdir}/libnfsidmap/*.so |
|
51 |
+ |
|
52 |
+%files devel |
|
53 |
+%defattr(-,root,root) |
|
54 |
+%{_includedir}/* |
|
55 |
+%{_libdir}/pkgconfig/*.pc |
|
56 |
+%{_mandir}/man3/* |
|
57 |
+%{_mandir}/man5/* |
|
58 |
+%{_libdir}/libnfsidmap.so |
|
59 |
+ |
|
60 |
+%changelog |
|
61 |
+* Mon Jan 22 2018 Xiaolin Li <xiaolinl@vmware.com> 0.25-1 |
|
62 |
+- Initial build. First version |
0 | 63 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,48 @@ |
0 |
+Summary: This library implements rpcsec_gss |
|
1 |
+Name: librpcsecgss |
|
2 |
+Version: 0.19 |
|
3 |
+Release: 1%{?dist} |
|
4 |
+License: BSD |
|
5 |
+URL: http://www.citi.umich.edu/projects/nfsv4/linux/ |
|
6 |
+Group: System Environment/Libraries |
|
7 |
+Vendor: VMware, Inc. |
|
8 |
+Distribution: Photon |
|
9 |
+Source0: http://www.citi.umich.edu/projects/nfsv4/linux/librpcsecgss/%{name}-%{version}.tar.gz |
|
10 |
+%define sha1 librpcsecgss=28522737949977d9733e876c91ccea5ce6b1f58b |
|
11 |
+BuildRequires: libgssglue-devel |
|
12 |
+ |
|
13 |
+%description |
|
14 |
+This library implements rpcsec_gss (RFC 2203) which allows secure rpc |
|
15 |
+communication using gss-api security mechanisms. |
|
16 |
+%package devel |
|
17 |
+Summary: Header and development files |
|
18 |
+Requires: %{name} = %{version} |
|
19 |
+%description devel |
|
20 |
+It contains the libraries and header files to create applications. |
|
21 |
+ |
|
22 |
+%prep |
|
23 |
+%setup -q |
|
24 |
+%build |
|
25 |
+./configure --prefix=/usr --disable-static |
|
26 |
+ |
|
27 |
+make %{?_smp_mflags} |
|
28 |
+ |
|
29 |
+%install |
|
30 |
+make DESTDIR=%{buildroot} install |
|
31 |
+find %{buildroot}/%{_libdir} -name '*.la' -delete |
|
32 |
+ |
|
33 |
+%post |
|
34 |
+ |
|
35 |
+%files |
|
36 |
+%defattr(-,root,root) |
|
37 |
+%{_libdir}/librpcsecgss.so.* |
|
38 |
+ |
|
39 |
+%files devel |
|
40 |
+%defattr(-,root,root) |
|
41 |
+%{_includedir}/* |
|
42 |
+%{_libdir}/librpcsecgss.so |
|
43 |
+%{_libdir}/pkgconfig/*.pc |
|
44 |
+ |
|
45 |
+%changelog |
|
46 |
+* Mon Jan 22 2018 Xiaolin Li <xiaolinl@vmware.com> 0.19-1 |
|
47 |
+- Initial build. First version |
... | ... |
@@ -1,12 +1,12 @@ |
1 | 1 |
Summary: NFS client utils |
2 | 2 |
Name: nfs-utils |
3 |
-Version: 2.1.1 |
|
4 |
-Release: 7%{?dist} |
|
3 |
+Version: 2.3.1 |
|
4 |
+Release: 1%{?dist} |
|
5 | 5 |
License: GPLv2+ |
6 | 6 |
URL: http://sourceforge.net/projects/nfs |
7 | 7 |
Group: Applications/Nfs-utils-client |
8 |
-Source0: http://downloads.sourceforge.net/nfs/%{name}-%{version}.tar.bz2 |
|
9 |
-%define sha1 nfs-utils=8f86ffef3bfc954f3ef9aee805b35cdca3802b14 |
|
8 |
+Source0: http://downloads.sourceforge.net/nfs/%{name}-%{version}.tar.xz |
|
9 |
+%define sha1 nfs-utils=5eac1882041ce3ebbe98e16aeaec77ec7da4d935 |
|
10 | 10 |
Source1: nfs-client.service |
11 | 11 |
Source2: nfs-client.target |
12 | 12 |
Source3: rpc-statd.service |
... | ... |
@@ -16,13 +16,26 @@ Source6: nfs-server.service |
16 | 16 |
Source7: nfs-mountd.service |
17 | 17 |
Vendor: VMware, Inc. |
18 | 18 |
Distribution: Photon |
19 |
-BuildRequires: krb5 |
|
19 |
+BuildRequires: libtool |
|
20 |
+BuildRequires: krb5-devel |
|
21 |
+BuildRequires: libcap-devel |
|
20 | 22 |
BuildRequires: libtirpc-devel |
21 | 23 |
BuildRequires: python3-devel |
24 |
+BuildRequires: libevent-devel |
|
25 |
+BuildRequires: device-mapper-devel |
|
26 |
+BuildRequires: systemd-devel |
|
27 |
+BuildRequires: keyutils-devel |
|
28 |
+BuildRequires: sqlite-devel |
|
29 |
+BuildRequires: libgssglue-devel |
|
30 |
+BuildRequires: librpcsecgss-devel |
|
31 |
+BuildRequires: libnfsidmap-devel |
|
32 |
+BuildRequires: e2fsprogs-devel |
|
22 | 33 |
Requires: libtirpc |
23 | 34 |
Requires: rpcbind |
24 | 35 |
Requires: shadow |
25 | 36 |
Requires: python3-libs |
37 |
+Requires(pre): /usr/sbin/useradd /usr/sbin/groupadd |
|
38 |
+Requires(postun):/usr/sbin/userdel /usr/sbin/groupdel |
|
26 | 39 |
|
27 | 40 |
%description |
28 | 41 |
The nfs-utils package contains simple nfs client service |
... | ... |
@@ -35,12 +48,12 @@ sed '/unistd.h/a#include <stdint.h>' -i support/nsm/rpc.c |
35 | 35 |
find . -iname "*.py" | xargs -I file sed -i '1s/python/python3/g' file |
36 | 36 |
|
37 | 37 |
%build |
38 |
-./configure --prefix=%{_prefix} \ |
|
39 |
- --sysconfdir=%{_sysconfdir} \ |
|
40 |
- --enable-libmount-mount \ |
|
41 |
- --without-tcp-wrappers \ |
|
42 |
- --disable-nfsv4 \ |
|
43 |
- --disable-gss \ |
|
38 |
+./configure --prefix=%{_prefix} \ |
|
39 |
+ --sysconfdir=%{_sysconfdir} \ |
|
40 |
+ --enable-libmount-mount \ |
|
41 |
+ --without-tcp-wrappers \ |
|
42 |
+ --enable-gss \ |
|
43 |
+ --enable-nfsv4 \ |
|
44 | 44 |
--disable-static |
45 | 45 |
|
46 | 46 |
make |
... | ... |
@@ -60,8 +73,16 @@ install -m644 %{SOURCE3} %{buildroot}/lib/systemd/system/ |
60 | 60 |
install -m644 %{SOURCE4} %{buildroot}/lib/systemd/system/ |
61 | 61 |
install -m644 %{SOURCE5} %{buildroot}/etc/default/nfs-utils |
62 | 62 |
install -m644 %{SOURCE6} %{buildroot}/lib/systemd/system/ |
63 |
-install -m644 systemd/proc-fs-nfsd.mount %{buildroot}/lib/systemd/system/ |
|
64 | 63 |
install -m644 %{SOURCE7} %{buildroot}/lib/systemd/system/ |
64 |
+install -m644 systemd/proc-fs-nfsd.mount %{buildroot}/lib/systemd/system/ |
|
65 |
+install -m644 systemd/nfs-idmapd.service %{buildroot}/lib/systemd/system/ |
|
66 |
+install -m644 systemd/rpc_pipefs.target %{buildroot}/lib/systemd/system/ |
|
67 |
+install -m644 systemd/var-lib-nfs-rpc_pipefs.mount %{buildroot}/lib/systemd/system/ |
|
68 |
+install -m644 systemd/rpc-svcgssd.service %{buildroot}/lib/systemd/system/ |
|
69 |
+find %{buildroot}/%{_libdir} -name '*.la' -delete |
|
70 |
+ |
|
71 |
+install -vdm755 %{buildroot}/usr/lib/systemd/system-preset |
|
72 |
+echo "disable nfs-server.service" > %{buildroot}/usr/lib/systemd/system-preset/50-nfs-server.preset |
|
65 | 73 |
|
66 | 74 |
%check |
67 | 75 |
#ignore test that might require additional setup |
... | ... |
@@ -69,6 +90,25 @@ sed -i '/check_root/i \ |
69 | 69 |
exit 77' tests/t0001-statd-basic-mon-unmon.sh |
70 | 70 |
make check |
71 | 71 |
|
72 |
+%pre |
|
73 |
+if ! getent group nobody >/dev/null; then |
|
74 |
+ groupadd -r nobody |
|
75 |
+fi |
|
76 |
+if ! getent passwd nobody >/dev/null; then |
|
77 |
+ useradd -g named -s /bin/false -M -r nobody |
|
78 |
+fi |
|
79 |
+ |
|
80 |
+%post |
|
81 |
+/sbin/ldconfig |
|
82 |
+%systemd_post nfs-server.service |
|
83 |
+ |
|
84 |
+%preun |
|
85 |
+%systemd_preun nfs-server.service |
|
86 |
+ |
|
87 |
+%postun |
|
88 |
+/sbin/ldconfig |
|
89 |
+%systemd_postun_with_restart nfs-server.service |
|
90 |
+ |
|
72 | 91 |
%files |
73 | 92 |
%defattr(-,root,root) |
74 | 93 |
%{_datadir}/* |
... | ... |
@@ -78,8 +118,17 @@ make check |
78 | 78 |
/etc/default/nfs-utils |
79 | 79 |
/etc/exports |
80 | 80 |
/lib/systemd/system/* |
81 |
+%{_libdir}/libnfsidmap.so.* |
|
82 |
+%{_libdir}/libnfsidmap/nsswitch.so |
|
83 |
+%{_libdir}/libnfsidmap/static.so |
|
84 |
+%{_libdir}/systemd/system-preset/50-nfs-server.preset |
|
81 | 85 |
|
86 |
+%{_includedir}/* |
|
87 |
+%{_libdir}/libnfsidmap.so |
|
88 |
+%{_libdir}/pkgconfig/libnfsidmap.pc |
|
82 | 89 |
%changelog |
90 |
+* Fri Jan 26 2018 Xiaolin Li <xiaolinl@vmware.com> 2.3.1-1 |
|
91 |
+- Update to 2.3.1 and enable nfsv4 |
|
83 | 92 |
* Tue Oct 10 2017 Alexey Makhalov <amakhalov@vmware.com> 2.1.1-7 |
84 | 93 |
- No direct toybox dependency, shadow depends on toybox |
85 | 94 |
* Mon Sep 18 2017 Alexey Makhalov <amakhalov@vmware.com> 2.1.1-6 |