1
0
mirror of https://github.com/anope/anope.git synced 2026-07-05 03:13:13 +02:00

BUILD : 1.7.10 (879) BUGS : n/a NOTES : The anoperc scripts is now generate for the user. By DrStein

git-svn-id: svn://svn.anope.org/anope/trunk@879 31f1291d-b8d6-0310-a050-a5561fc1590b


git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@626 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
dane dane@31f1291d-b8d6-0310-a050-a5561fc1590b
2005-09-11 13:32:53 +00:00
parent 8735d2becb
commit 22e3b01cd4
7 changed files with 1240 additions and 144 deletions
+3
View File
@@ -47,6 +47,9 @@ Provided by Trystan <trystan@nomadirc.net> - 2005
09/06 F Memory for vHosts/vIdents was not (always) being freed. [ #00]
06/04 F Removed ircd-file related code from configure(.in) [#384]
Provided by DrStein <drstein@anope.org> - 2005
08/30 A anoperc is now configured by the Config script [ #00]
Provided by Hal9000 <hal9000@musichat.net> - 2005
06/27 A Italian translations for modpack modules. [ #00]
06/25 F Updated Italian language file. [ #00]
+1
View File
@@ -98,6 +98,7 @@ distclean: clean
(cd src ; ${MAKE} ${MAKEARGS} distclean )
(cd src/tools ; ${MAKE} ${MAKEARGS} distclean )
rm -f config.log config.status config.cache Makefile
rm -f src/bin/anoperc
install: DUMMY
(cd src ; ${MAKE} ${MAKEARGS} install)
Vendored
+1093
View File
File diff suppressed because it is too large Load Diff
+1
View File
@@ -221,6 +221,7 @@ AC_ARG_WITH(encryption, [ --with-encryption Use md5 database encryption], [
])
AC_OUTPUT(Makefile)
AC_OUTPUT(src/bin/anoperc)
cat <<EOT
-143
View File
@@ -1,143 +0,0 @@
#!/bin/sh
###############################################
# Set Variables
###############################################
# PID FILE NAME (e.g. services.pid)
PIDFILE="services.pid"
# FULL PATH TO ANOPE DIRECTORY e.g. /home/ribosome/services/
# YOU MUST INCLUDE TRAILING SLASH
ANOPEBIN=""
# SERVICES EXECUTABLE NAME (e.g. services)
ANOPROG="services"
# SCRIPT VERSION NUMBER (DO NOT ALTER)
ARCVERSION="1.1"
################################################
# END OF CONFIGURATION
# YOU ARE NOT REQUIRED TO CHANGE ANYTHING BELOW
################################################
isAnopeRunning () {
if [ ! -f $ANOPEBIN$PIDFILE ] ; then
echo "Warning: Anope is not currently running"
exit 1
fi
PID=`cat $ANOPEBIN$PIDFILE`
if [ ! `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` ] ; then
echo "Warning: Anope is not currently running"
exit 1
fi
}
if [ "$ANOPEBIN" = "" ] ; then
echo "Error: Please open this file set the variables correctly";
exit 1
fi
if [ ! -f $ANOPEBIN$ANOPROG ] ; then
echo "Error: $ANOPEBIN$ANOPROG cannot be accessed"
exit 1
fi
if [ "$UID" = "0" ] ; then
echo "**********************************";
echo "Warning: Do not run anope as root!";
echo "**********************************";
exit 1
fi
if [ "$1" = "start" ] ; then
if [ -f $ANOPEBIN$PIDFILE ] ; then
PID=`cat $ANOPEBIN$PIDFILE`
if [ `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` = 1 ] ; then
echo "Warning! Anope is already running"
exit 1
fi
fi
echo "Starting Anope"
shift
$ANOPEBIN$ANOPROG $*
sleep 1
if [ ! -f $ANOPEBIN$PIDFILE ] ; then
echo "Unfortunately it seems Anope did not start successfully"
echo "This error has been logged in your Anope Log file"
echo "Located in "$ANOPEBIN"logs/"
echo "This may help you diagnose the problem"
echo "Further help may be available from http://www.anope.org"
exit 1
fi
PID=`cat $ANOPEBIN$PIDFILE`
if [ ! `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` ] ; then
echo "Unfortunately it seems Anope did not start successfully"
echo "This error has been logged in your Anope Log file"
echo "Located in "$ANOPEBIN"logs/"
echo "This may help you diagnose the problem"
echo "Further help may be available from http://www.anope.org"
exit 1
fi
elif [ "$1" = "stop" ] ; then
isAnopeRunning
echo "Terminating Anope"
PID=`cat $ANOPEBIN$PIDFILE`
kill -15 $PID
elif [ "$1" = "status" ] ; then
if [ -f $ANOPEBIN$PIDFILE ] ; then
PID=`cat $ANOPEBIN$PIDFILE`
if [ `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` = 1 ] ; then
echo "Anope is currently running"
exit 1
fi
fi
echo "Anope is not currently running"
elif [ "$1" = "restart" ] ; then
isAnopeRunning
echo "Restarting Anope"
PID=`cat $ANOPEBIN$PIDFILE`
kill -1 $PID
elif [ "$1" = "rehash" ] ; then
isAnopeRunning
echo "Saving Databases and Rehashing Configuration"
PID=`cat $ANOPEBIN$PIDFILE`
kill -12 $PID
elif [ "$1" = "version" ] ; then
$ANOPEBIN$ANOPROG -version
elif [ "$1" = "help" ] ; then
if [ "$2" = "paramlist" ] ; then
$ANOPEBIN$ANOPROG -help
else
echo "AnopeRC is a remote control script for easy"
echo "controlling of Anope from the command console"
echo "$0 start Start Anope"
echo " Additional parameters may be passed"
echo " (e.g. $0 start -nofork)"
echo " For a list of type $0 $1 paramlist"
echo "$0 stop Shutdown Anope"
echo "$0 status Show Anope's Status"
echo "$0 restart Restart Anope (Databases will be saved)"
echo "$0 rehash Rehash Configuration and Save Databases"
echo "$0 version Return Anope Version and Build Information"
echo "$0 help Show this help menu"
echo "If you need further help please check the /docs/"
echo "folder or make use of our extensive online support at"
echo "http://www.anope.org"
fi
else
echo "Anope Remote Control ($ARCVERSION)"
echo "Usage: $0 [start|stop|status|restart|rehash|version|help]"
fi
+137
View File
@@ -0,0 +1,137 @@
#!/bin/sh
#
# Configuration script for Services
#
# (C) 2003-2005 Anope Team
# Contact us at info@anope.org
#
# Please read COPYING and README for further details.
#
# Based on the original code of Epona by Lara.
# Based on the original code of Services by Andy Church.
#
# $Id$
#
ANOPEPID="@DATDEST@/services.pid"
ANOPROG="@BINDEST@/services"
LOG="@DATDEST@/logs/"
ARCVERSION="1.2"
isAnopeRunning () {
if [ ! -f $ANOPEPID ] ; then
echo "Warning: Anope is not currently running"
exit 1
fi
PID=`cat $ANOPEPID`
if [ ! `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` ] ; then
echo "Warning: Anope is not currently running"
exit 1
fi
}
if [ ! -f $ANOPROG ] ; then
echo "Error: $ANOPROG cannot be accessed"
exit 1
fi
if [ "$UID" = "0" ] ; then
echo "######################################";
echo "# Warning: Do NOT run Anope as root! #";
echo "######################################";
exit 1
fi
if [ "$1" = "start" ] ; then
if [ -f $ANOPEPID ] ; then
PID=`cat $ANOPEPID`
if [ `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` = 1 ] ; then
echo "Warning! Anope is already running"
exit 1
fi
fi
echo "Starting Anope"
shift
$ANOPROG $*
sleep 1
if [ ! -f $ANOPEPID ] ; then
echo "Unfortunately it seems Anope did not start successfully"
echo "This error has been logged in your Anope Log file"
echo "Located in "$LOG""
echo "This may help you diagnose the problem"
echo "Further help may be available from http://www.anope.org/"
exit 1
fi
PID=`cat $ANOPEPID`
if [ ! `ps auxw | grep $ANOPROG | grep $PID | grep -v -c grep` ] ; then
echo "Unfortunately it seems Anope did not start successfully"
echo "This error has been logged in your Anope Log file"
echo "Located in "$LOG""
echo "This may help you diagnose the problem"
echo "Further help may be available from http://www.anope.org/"
exit 1
fi
elif [ "$1" = "stop" ] ; then
isAnopeRunning
echo "Terminating Anope"
kill -15 `cat $ANOPEPID`
elif [ "$1" = "status" ] ; then
if [ -f $ANOPEPID ] ; then
PID=`cat $ANOPEPID`
if [ `ps auxw | grep $PID | grep -v -c grep` = 1 ] ; then
echo "Anope is currently running"
exit 1
fi
fi
echo "Anope is not currently running"
## :/ SIGUSR2 is ignored after the first restart so we stop / start Anope for now ##
elif [ "$1" = "restart" ] ; then
isAnopeRunning
echo "Restarting Anope"
kill -15 `cat $ANOPEPID`
sleep 1
$ANOPROG
elif [ "$1" = "rehash" ] ; then
isAnopeRunning
echo "Saving Databases and Rehashing Configuration"
kill -1 `cat $ANOPEPID`
elif [ "$1" = "version" ] ; then
$ANOPROG -version
elif [ "$1" = "help" ] ; then
if [ "$2" = "paramlist" ] ; then
$ANOPROG -help
else
echo "AnopeRC is a remote control script for easy"
echo "controlling of Anope from the command console"
echo "$0 start Start Anope"
echo " Additional parameters may be passed"
echo " (e.g. $0 start -nofork)"
echo " For a list of type $0 $1 paramlist"
echo "$0 stop Shutdown Anope"
echo "$0 status Show Anope's Status"
echo "$0 restart Restart Anope (Databases will be saved)"
echo "$0 rehash Rehash Configuration and Save Databases"
echo "$0 version Return Anope Version and Build Information"
echo "$0 help Show this help menu"
echo "If you need further help please check the /docs/"
echo "folder or make use of our extensive online support at"
echo "http://www.anope.org/"
fi
else
echo "Anope Remote Control ($ARCVERSION)"
echo "Usage: $0 [start|stop|status|restart|rehash|version|help]"
fi
+5 -1
View File
@@ -8,10 +8,14 @@
VERSION_MAJOR="1"
VERSION_MINOR="7"
VERSION_PATCH="10"
VERSION_BUILD="878"
VERSION_BUILD="879"
# $Log$
#
# BUILD : 1.7.10 (879)
# BUGS : n/a
# NOTES : The anoperc scripts is now generate for the user. By DrStein
#
# BUILD : 1.7.10 (878)
# BUGS :
# NOTES : Applied patch by ThaPrince to fix XLINEs with plexus