Accepting request 156707 from network:samba:STABLE
This requires modified Samba packages sources as submitted with https://build.openSUSE.org/request/show/156705 If possible both should be released for openSUSE 12.3 as well. - Add cifstab named configuration file to post-12.2 systems; (bnc#804822). - Really use of the existing cifs init script; (bnc#697218). - Remove superfluous restart or stop of the cifs service; (bnc#804822). - Move the cifs init script nfs dependencies from Required to Should. OBS-URL: https://build.opensuse.org/request/show/156707 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/cifs-utils?expand=0&rev=31
This commit is contained in:
commit
15c731ac77
@ -1,3 +1,14 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Feb 26 12:07:11 UTC 2013 - lmuelle@suse.com
|
||||
|
||||
- Add cifstab named configuration file to post-12.2 systems; (bnc#804822).
|
||||
- Really use of the existing cifs init script; (bnc#697218).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 21 10:34:55 UTC 2013 - lmuelle@suse.com
|
||||
|
||||
- Remove superfluous restart or stop of the cifs service; (bnc#804822).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 23 11:06:31 UTC 2013 - lmuelle@suse.com
|
||||
|
||||
@ -224,6 +235,11 @@ Tue Mar 8 08:51:37 UTC 2011 - sjayaraman@suse.de
|
||||
+ cifs-utils: infrastructure for stashing passwords in keyring.
|
||||
+ cifs-utils: moving resolve_host into separate file.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 14 15:22:51 CET 2011 - lmuelle@suse.de
|
||||
|
||||
- Move the cifs init script nfs dependencies from Required to Should.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Dec 7 13:31:05 UTC 2010 - toganm@opensuse.org
|
||||
|
||||
|
@ -24,9 +24,15 @@ License: GPL-3.0+
|
||||
Group: System/Filesystems
|
||||
Url: http://www.samba.org/linux-cifs/cifs-utils/
|
||||
Source: %{name}-%{version}.tar.bz2
|
||||
%if "%{_vendor}" == "suse"
|
||||
%define NET_CFGDIR network
|
||||
%else
|
||||
%define NET_CFGDIR network-scripts
|
||||
%endif
|
||||
Source1: cifs.init
|
||||
Source2: mkinitrd_scripts_boot-cifs.sh
|
||||
Source3: mkinitrd_scripts_setup-cifs.sh
|
||||
Source4: cifstab
|
||||
Patch: 1a01f7c4b90695211d12291d7a24bec05b1f2922.diff
|
||||
%if 0%{?suse_version}
|
||||
PreReq: insserv %{?fillup_prereq} mkinitrd
|
||||
@ -108,35 +114,47 @@ install -m 644 -p contrib/request-key.d/cifs.spnego.conf %{buildroot}%{_sysconfd
|
||||
%{__install} -m 0755 ${RPM_SOURCE_DIR}/mkinitrd_scripts_boot-cifs.sh ${RPM_BUILD_ROOT}/lib/mkinitrd/scripts/boot-cifs.sh
|
||||
%{__install} -m 0755 ${RPM_SOURCE_DIR}/mkinitrd_scripts_setup-cifs.sh ${RPM_BUILD_ROOT}/lib/mkinitrd/scripts/setup-cifs.sh
|
||||
%endif
|
||||
%if 0%{?suse_version} == 0 || 0%{?suse_version} > 1221
|
||||
mkdir -p \
|
||||
${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-{down,up}.d \
|
||||
${RPM_BUILD_ROOT}/%{_sysconfdir}/samba \
|
||||
${RPM_BUILD_ROOT}/%{_sbindir} \
|
||||
${RPM_BUILD_ROOT}/var/run
|
||||
install -m 0755 -p ${RPM_SOURCE_DIR}/cifs.init ${RPM_BUILD_ROOT}/%{_sysconfdir}/init.d/cifs
|
||||
install -m 0600 -p ${RPM_SOURCE_DIR}/cifstab ${RPM_BUILD_ROOT}/%{_sysconfdir}/samba/cifstab
|
||||
ln -s %{_sysconfdir}/init.d/${cifs_init_script} ${RPM_BUILD_ROOT}/%{_sbindir}/rccifs
|
||||
touch ${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/%{NET_CFGDIR}/if-{down,up}.d/${script} \
|
||||
${RPM_BUILD_ROOT}/var/run/cifs
|
||||
%endif
|
||||
# Hardlink duplicate files
|
||||
%if 0%{?suse_version} > 1110
|
||||
%fdupes ${RPM_BUILD_ROOT}
|
||||
%endif
|
||||
|
||||
%preun
|
||||
%if 0%{?suse_version}
|
||||
%{stop_on_removal cifs}
|
||||
%else
|
||||
if [ $1 = 0 ] ; then
|
||||
test -x /sbin/chkconfig && /sbin/chkconfig --del cifs
|
||||
%pre
|
||||
# non SUSE + post-12.2, update, no cifstab, but smbfstab
|
||||
if [ ! 0%{?suse_version} -lt 1221 -a \
|
||||
${1:-0} -gt 1 -a \
|
||||
! -e /etc/samba/cifstab -a \
|
||||
-f /etc/samba/smbfstab ]; then
|
||||
cp -a /etc/samba/smbfstab /var/adm/backup/etc_samba_smbfstab-move
|
||||
chkconfig -c smbfs && >/var/adm/backup/etc_samba_smbfs-enabled || :
|
||||
fi
|
||||
%endif
|
||||
|
||||
exit 0
|
||||
|
||||
%post
|
||||
if [ ${1:-0} -gt 1 -a -f /var/adm/backup/etc_samba_smbfstab-move ]; then
|
||||
test -f /etc/samba/cifstab && \
|
||||
mv /etc/samba/cifstab /etc/samba/cifstab.rpmnew
|
||||
mv /var/adm/backup/etc_samba_smbfstab-move /etc/samba/cifstab
|
||||
if [ -f /var/adm/backup/etc_samba_smbfs-enabled ]; then
|
||||
chkconfig -a cifs >/dev/null
|
||||
rm /var/adm/backup/etc_samba_smbfs-enabled
|
||||
fi
|
||||
fi
|
||||
[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup
|
||||
exit 0
|
||||
|
||||
%postun
|
||||
%if 0%{?suse_version}
|
||||
%{restart_on_update cifs}
|
||||
%{insserv_cleanup}
|
||||
%else
|
||||
if [ "$1" -ge "1" ]; then
|
||||
%{initdir}/cifs restart >/dev/null
|
||||
fi
|
||||
%endif
|
||||
[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup
|
||||
exit 0
|
||||
|
||||
@ -174,6 +192,13 @@ exit 0
|
||||
%{_libdir}/%{name}/idmapwb.so
|
||||
%doc %{_mandir}/man8/idmapwb.8.*
|
||||
%endif
|
||||
%if 0%{?suse_version} == 0 || 0%{?suse_version} > 1221
|
||||
%attr(0754,root,root) %config %{_sysconfdir}/init.d/cifs
|
||||
%attr(0600,root,root) %config(noreplace) %{_sysconfdir}/samba/cifstab
|
||||
%{_sbindir}/rccifs
|
||||
%dir %{_sysconfdir}/samba
|
||||
%ghost %{_localstatedir}/run/cifs
|
||||
%endif
|
||||
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
|
@ -26,9 +26,9 @@
|
||||
### BEGIN INIT INFO
|
||||
# Provides: cifs
|
||||
# Required-Start: $network $syslog
|
||||
# Should-Start: nmb
|
||||
# Should-Start: nfs nmb
|
||||
# Required-Stop: $network $syslog
|
||||
# Should-Stop: nmb
|
||||
# Should-Stop: nfs nmb
|
||||
# Default-Start: 3 5
|
||||
# Default-Stop: 0 1 2 6
|
||||
# Short-Description: Import remote SMB/ CIFS (MS Windows) file systems
|
||||
|
10
cifstab
Normal file
10
cifstab
Normal file
@ -0,0 +1,10 @@
|
||||
# This file allows you to mount SMB/ CIFS shares during system boot while
|
||||
# hiding passwords to other people than root. Use /etc/fstab for public
|
||||
# available services. You have to specify at least a service name and a mount
|
||||
# point. Current default vfstype is cifs.
|
||||
#
|
||||
# The options are explained in the manual page of mount.cifs.
|
||||
#
|
||||
# service moint-point vfstype options
|
||||
|
||||
;//fjall/test /data/test cifs username=tridge,password=foobar
|
Loading…
Reference in New Issue
Block a user