rpms/freeradius/devel freeradius-logrotate, NONE, 1.1 freeradius-pam-conf, NONE, 1.1 freeradius-radiusd.init, NONE, 1.1 freeradius-radrelay.init, NONE, 1.1 freeradius.spec, 1.57, 1.58

John Dennis (jdennis) fedora-extras-commits at redhat.com
Fri Feb 29 04:16:59 UTC 2008


Author: jdennis

Update of /cvs/pkgs/rpms/freeradius/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv3489

Modified Files:
	freeradius.spec 
Added Files:
	freeradius-logrotate freeradius-pam-conf 
	freeradius-radiusd.init freeradius-radrelay.init 
Log Message:
make our own versions of init scripts, pam.conf, logrotate
so we can edit them rather than copying from src tarball and patching



--- NEW FILE freeradius-logrotate ---
# You can use this to rotate the /var/log/radius/* files, simply copy
# it to /etc/logrotate.d/radiusd

# There are different detail-rotating strategies you can use.  One is
# to write to a single detail file per IP and use the rotate config
# below.  Another is to write to a daily detail file per IP with:
#     detailfile = ${radacctdir}/%{Client-IP-Address}/%Y%m%d-detail
# (or similar) in radiusd.conf, without rotation.  If you go with the
# second technique, you will need another cron job that removes old
# detail files.  You do not need to comment out the below for method #2.
/var/log/radius/radacct/*/detail {
	monthly
	rotate 4
	nocreate
	missingok
	compress
}

/var/log/radius/checkrad.log {
	monthly
	rotate 4
	create
	missingok
	compress
}

/var/log/radius/radius.log {
	monthly
	rotate 4
	create
	missingok
	compress
}

/var/log/radius/radutmp {
	monthly
	rotate 4
	create
	compress
	missingok
}

/var/log/radius/radwtmp {
	monthly
	rotate 4
	create
	compress
	missingok
}
/var/log/radius/sqltrace.sql {
        monthly
        rotate 4
        create
        compress
        missingok
}


--- NEW FILE freeradius-pam-conf ---
#%PAM-1.0
auth       include	system-auth
account    required	pam_nologin.so
account    include	system-auth
password   include	system-auth
session    include	system-auth


--- NEW FILE freeradius-radiusd.init ---
#!/bin/sh
#
# chkconfig: - 88 10
# description: Start/Stop the RADIUS server daemon
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program; if not, write to the Free Software
#    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
#
#    Copyright (C) 2001 The FreeRADIUS Project   http://www.freeradius.org
#

# Source function library.
. /etc/rc.d/init.d/functions

RADIUSD=/usr/sbin/radiusd
LOCKF=/var/lock/subsys/radiusd
CONFIG=/etc/raddb/radiusd.conf

[ -f $RADIUSD ] || exit 0
[ -f $CONFIG ] || exit 0

RETVAL=0

case "$1" in
  start)
	echo -n $"Starting RADIUS server: "
	daemon $RADIUSD
	RETVAL=$?
	echo
	[ $RETVAL -eq 0 ] && touch $LOCKF &&
	    ln -s /var/run/radiusd/radiusd.pid /var/run/radiusd.pid 2>/dev/null
	;;
  stop)
	echo -n $"Stopping RADIUS server: "
	killproc $RADIUSD
	RETVAL=$?
	echo
	[ $RETVAL -eq 0 ] && rm -f $LOCKF
	;;
  status)
	status radiusd
	RETVAL=$?
        ;;
  reload)
	echo -n $"Reloading RADIUS server: "
	killproc $RADIUSD -HUP
	RETVAL=$?
	echo
	;;
  restart)
	$0 stop
	sleep 3
	$0 start
	RETVAL=$?
	;;
  condrestart)
	if [ -f $LOCKF ]; then
		$0 stop
		sleep 3
		$0 start
		RETVAL=$?
	fi
	;;
  *)
	echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}"
	exit 1
esac

exit $RETVAL


--- NEW FILE freeradius-radrelay.init ---
#!/bin/sh
#
# chkconfig: - 88 10
# description: Start/Stop the RADIUS server daemon
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program; if not, write to the Free Software
#    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
#
#    Copyright (C) 2001 The FreeRADIUS Project   http://www.freeradius.org
#

# Source function library.
. /etc/rc.d/init.d/functions

RADIUSD=/usr/sbin/radiusd
LOCKF=/var/lock/subsys/radiusd
CONFIG=/etc/raddb/radiusd.conf

[ -f $RADIUSD ] || exit 0
[ -f $CONFIG ] || exit 0

RETVAL=0

case "$1" in
  start)
	echo -n $"Starting RADIUS server: "
	daemon $RADIUSD
	RETVAL=$?
	echo
	[ $RETVAL -eq 0 ] && touch $LOCKF &&
	    ln -s /var/run/radiusd/radiusd.pid /var/run/radiusd.pid 2>/dev/null
	;;
  stop)
	echo -n $"Stopping RADIUS server: "
	killproc $RADIUSD
	RETVAL=$?
	echo
	[ $RETVAL -eq 0 ] && rm -f $LOCKF
	;;
  status)
	status radiusd
	RETVAL=$?
        ;;
  reload)
	echo -n $"Reloading RADIUS server: "
	killproc $RADIUSD -HUP
	RETVAL=$?
	echo
	;;
  restart)
	$0 stop
	sleep 3
	$0 start
	RETVAL=$?
	;;
  condrestart)
	if [ -f $LOCKF ]; then
		$0 stop
		sleep 3
		$0 start
		RETVAL=$?
	fi
	;;
  *)
	echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}"
	exit 1
esac

exit $RETVAL


Index: freeradius.spec
===================================================================
RCS file: /cvs/pkgs/rpms/freeradius/devel/freeradius.spec,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -r1.57 -r1.58
--- freeradius.spec	29 Feb 2008 03:21:36 -0000	1.57
+++ freeradius.spec	29 Feb 2008 04:16:24 -0000	1.58
@@ -1,8 +1,7 @@
 # FIXME: should pki certs be moved to /etc/pki?
 # FIXME: are the group names right?
 # FIXME: need to run rpmlint
-# FIXME: need radrelay init.d script
-# FIXME: check each of the files loaded from the redhat directory
+# FIXME: edit radrelay init.d script, was copied from radiusd init
 # FIXME: check each former patch, do we still need any?
 Summary: High-performance and highly configurable free RADIUS server
 Name: freeradius
@@ -13,6 +12,10 @@
 URL: http://www.freeradius.org/
 
 Source0: ftp://ftp.freeradius.org/pub/radius/%{name}-server-%{version}.tar.bz2
+Source100: freeradius-radiusd.init
+Source101: freeradius-radrelay.init
+Source102: freeradius-logrotate
+Source103: freeradius-pam-conf
 
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
@@ -236,9 +239,11 @@
 mkdir -p $RPM_BUILD_ROOT/var/log/radius/radacct
 touch $RPM_BUILD_ROOT/var/log/radius/{radutmp,radius.log}
 
-install -m 644 redhat/radiusd-pam $RPM_BUILD_ROOT/%{_sysconfdir}/pam.d/radiusd
-install -m 644 redhat/radiusd-logrotate $RPM_BUILD_ROOT/%{_sysconfdir}/logrotate.d/radiusd
-install -m 755 redhat/rc.radiusd-redhat $RPM_BUILD_ROOT/%{_initrddir}/radiusd
+install -m 755 %{SOURCE100} $RPM_BUILD_ROOT/%{_initrddir}/radiusd
+install -m 755 %{SOURCE101} $RPM_BUILD_ROOT/%{_initrddir}/radrelay
+install -m 644 %{SOURCE102} $RPM_BUILD_ROOT/%{_sysconfdir}/logrotate.d/radiusd
+install -m 644 %{SOURCE103} $RPM_BUILD_ROOT/%{_sysconfdir}/pam.d/radiusd
+
 (cd $RPM_BUILD_ROOT/usr/sbin && ln -sf ./radiusd radrelay)
 # install dialup_admin
 DIALUPADMIN=$RPM_BUILD_ROOT%{_datadir}/dialup_admin
@@ -297,6 +302,7 @@
 %config(noreplace) %{_sysconfdir}/pam.d/radiusd
 %config(noreplace) %{_sysconfdir}/logrotate.d/radiusd
 %config(noreplace) %{_initrddir}/radiusd
+%config(noreplace) %{_initrddir}/radrelay
 %dir %attr(755,radiusd,radiusd) /var/lib/radiusd
 # configs
 %dir %attr(750,-,radiusd) /etc/raddb




More information about the fedora-extras-commits mailing list