Release 1.3.5.2

- Fixed License to GPLv3+
- Generate a user dirsrv in the package install.
This commit is contained in:
Noriko Hosoi 2016-03-28 15:36:27 -07:00
parent 1d1dc675c9
commit dc711d1b02

View File

@ -36,8 +36,8 @@
Summary: 389 Directory Server (base)
Name: 389-ds-base
Version: 1.3.5.1
Release: %{?relprefix}1%{?prerel}%{?dist}
License: GPLv2 with exceptions
Release: %{?relprefix}2%{?prerel}%{?dist}
License: GPLv3+
URL: https://port389.org/
Group: System Environment/Daemons
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@ -278,6 +278,27 @@ ninst=0 # number of instances found in total
if [ -n "$DEBUGPOSTTRANS" ] ; then
output=$DEBUGPOSTTRANS
fi
has_dirsrv=`/usr/bin/egrep -i "^dirsrv\>" /etc/passwd` || :
if [ "$has_dirsrv" = "" ]; then
dirsrv_uid=389
while [ "`getent passwd | awk -F: '{print $3}' | grep $dirsrv_uid`" != "" ]; do
dirsrv_uid=`expr $dirsrv_uid + 1`
done
echo "User dirsrv does not exist, create it with uid %dirsrv_uid." >> $output 2>&1 || :
/usr/sbin/useradd -c "389-ds-base" -u $dirsrv_uid \
-s /sbin/nologin -r -d /usr/share/dirsrv dirsrv 2> /dev/null || :
fi
has_dirsrv=`/usr/bin/egrep -i "^dirsrv\>" /etc/group` || :
if [ "$has_dirsrv" = "" ]; then
dirsrv_gid=389
while [ "`getent group | grep $dirsrv_gid`" != "" ]; do
dirsrv_gid=`expr $dirsrv_gid + 1`
done
echo "Group dirsrv does not exist, create it with uid %dirsrv_gid." >> $output 2>&1 || :
/usr/sbin/groupadd -g $dirsrv_gid -r dirsrv 2> /dev/null || :
fi
echo looking for services in %{_sysconfdir}/systemd/system/%{groupname}.wants/* >> $output 2>&1 || :
for service in %{_sysconfdir}/systemd/system/%{groupname}.wants/* ; do
if [ ! -f "$service" ] ; then continue ; fi # in case nothing matches
@ -382,6 +403,11 @@ fi
%endif
%changelog
* Mon Mar 28 2016 Noriko Hosoi <nhosoi@redhat.com> - 1.3.5.1-2
- Release 1.3.5.2
- Fixed License to GPLv3+
- Generate a user dirsrv in the package install.
* Wed Mar 23 2016 Noriko Hosoi <nhosoi@redhat.com> - 1.3.5.1-1
- Release 1.3.5.1
- Ticket 47982 - improve timestamp resolution in logs