]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blame - src/initscripts/packages/freeradius
frr: Add initscript
[people/pmueller/ipfire-2.x.git] / src / initscripts / packages / freeradius
CommitLineData
71f578bb
MT
1#!/bin/sh
2########################################################################
3# Begin $rc_base/init.d/freeradius
4#
5# Description : Initscript for the FreeRADIUS Server
6########################################################################
7
8. /etc/sysconfig/rc
9. ${rc_functions}
10
11case "${1}" in
12 start)
13 # Create necessary directories
14 mkdir -p /var/run/radiusd
15
16 boot_mesg "Starting FreeRADIUS server..."
17 loadproc /usr/sbin/radiusd -d /etc/raddb
18 ;;
19
20 stop)
21 boot_mesg "Stopping FreeRADIUS server..."
22 killproc /usr/sbin/radiusd
23 ;;
24
25 reload)
26 boot_mesg "Reloading FreeRADIUS server..."
27 reloadproc /usr/sbin/radiusd
28 ;;
29
30 restart)
31 ${0} stop
32 sleep 1
33 ${0} start
34 ;;
35
36 status)
37 statusproc /usr/sbin/radiusd
38 ;;
39
40 *)
41 echo "Usage: ${0} {start|stop|reload|restart|status}"
42 exit 1
43 ;;
44esac
45
46# End $rc_base/init.d/freeradius