richard: server/kolabd/kolabd/namespace/libexec adduser.in, 1.1, 1.2 deluser.in, 1.1, 1.2 listusers.in, 1.1, 1.2 newconfig.in, 1.1, 1.2 services.in, 1.1, 1.2 showlog.in, 1.3, 1.4 showuser.in, 1.3, 1.4 start.in, 1.2, 1.3 stop.in, 1.2, 1.3
cvs at intevation.de
cvs at intevation.de
Tue Dec 13 22:10:28 CET 2005
Author: richard
Update of /kolabrepository/server/kolabd/kolabd/namespace/libexec
In directory doto:/tmp/cvs-serv7286/namespace/libexec
Modified Files:
adduser.in deluser.in listusers.in newconfig.in services.in
showlog.in showuser.in start.in stop.in
Log Message:
* adduser.in, deluser.in, listusers.in, newconfig.in,
services.in, showlog.in, showuser.in, start.in and stop.in:
Added PATH variable, removed the full path from used commands as
they are now defined by the PATH variable
Changed --showhelp to --help
Changed 'cat .. | grep .. | sed ..' into just sed -n 's/../../p'
Index: adduser.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/adduser.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- adduser.in 13 Sep 2005 14:38:22 -0000 1.1
+++ adduser.in 13 Dec 2005 21:10:26 -0000 1.2
@@ -13,8 +13,9 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Add a user mailbox"
exit 0
HASHELP
@@ -23,10 +24,10 @@
#Collect some vitals
SERVER=127.0.0.1
-BINDDN=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_dn :" | sed -e "s;bind_dn : ;;"`
-BINDPW=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_pw :" | sed -e "s;bind_pw : ;;"`
-BASEDN=`cat @sysconfdir@/kolab/kolab.conf | grep "base_dn :" | sed -e "s;base_dn : ;;"`
-HOMESERV=`cat @sysconfdir@/kolab/kolab.conf | grep "fqdnhostname :" | sed -e "s;fqdnhostname : ;;"`
+BINDDN=`sed -n 's;bind_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+BINDPW=`sed -n 's;bind_pw : ;;p' @sysconfdir@/kolab/kolab.conf`
+BASEDN=`sed -n 's;base_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+HOMESERV=`sed -n 's;fqdnhostname : ;;p' @sysconfdir@/kolab/kolab.conf`
echo "Please specify the firstname:"
read FIRSTNAME
@@ -72,7 +73,7 @@
echo "--"
#Check if the user already exists
-DN=`@bindir@/kolab showuser $EMAIL | grep dn`
+DN=`kolab showuser $EMAIL | grep dn`
if test "$DN" != ""; then
echo User already found! Or other error occurred.
exit 255
@@ -109,4 +110,5 @@
echo "userquota: $QUOTA" >> $LDIFFILE
fi
- at bindir@/ldapadd -x -D "$BINDDN" -w $BINDPW -h $SERVER -f $LDIFFILE
+ldapadd -x -D "$BINDDN" -w $BINDPW -h $SERVER -f $LDIFFILE
+
Index: deluser.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/deluser.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- deluser.in 13 Sep 2005 14:38:22 -0000 1.1
+++ deluser.in 13 Dec 2005 21:10:26 -0000 1.2
@@ -13,9 +13,9 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir:$PATH
-
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Delete a user mailbox"
exit 0
HASHELP
@@ -24,12 +24,12 @@
#Collect some vitals
SERVER=127.0.0.1
-BINDDN=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_dn :" | sed -e "s;bind_dn : ;;"`
-BINDPW=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_pw :" | sed -e "s;bind_pw : ;;"`
-BASEDN=`cat @sysconfdir@/kolab/kolab.conf | grep "base_dn :" | sed -e "s;base_dn : ;;"`
-HOMESERV=`cat @sysconfdir@/kolab/kolab.conf | grep "fqdnhostname :" | sed -e "s;fqdnhostname : ;;"`
+BINDDN=`sed -n 's;bind_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+BINDPW=`sed -n 's;bind_pw : ;;p' @sysconfdir@/kolab/kolab.conf`
+BASEDN=`sed -n 's;base_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+HOMESERV=`sed -n 's;fqdnhostname : ;;p' @sysconfdir@/kolab/kolab.conf`
-DN=`@bindir@/kolab showuser $1 | grep dn`
+DN=`kolab showuser $1 | grep dn`
if test "$DN" = ""; then
echo User not found!
exit 255
@@ -52,4 +52,5 @@
kolabdeleteflag: $HOMESERV
LDIF
- at bindir@/ldapmodify -x -D "$BINDDN" -w $BINDPW -h $SERVER -f $LDIFFILE
+ldapmodify -x -D "$BINDDN" -w $BINDPW -h $SERVER -f $LDIFFILE
+
Index: listusers.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/listusers.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- listusers.in 13 Sep 2005 14:38:22 -0000 1.1
+++ listusers.in 13 Dec 2005 21:10:26 -0000 1.2
@@ -13,18 +13,18 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@
-
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Display a list of mailboxes"
exit 0
HASHELP
fi
-server=127.0.0.1
-binddn=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_dn :" | sed -e "s;bind_dn : ;;"`
-bindpw=`cat @sysconfdir@/kolab/kolab.conf | grep "bind_pw :" | sed -e "s;bind_pw : ;;"`
-basedn=`cat @sysconfdir@/kolab/kolab.conf | grep "base_dn :" | sed -e "s;base_dn : ;;"`
+SERVER=127.0.0.1
+BINDDN=`sed -n 's;bind_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+BINDPW=`sed -n 's;bind_pw : ;;p' @sysconfdir@/kolab/kolab.conf`
+BASEDN=`sed -n 's;base_dn : ;;p' @sysconfdir@/kolab/kolab.conf`
+ldapsearch -x -LLL -b "$BASEDN" -D "$BINDDN" -w $BINDPW -h $SERVER "(&(objectClass=kolabInetOrgPerson)(mail=*))" mail | sed -n "s;mail: ;;p"
- at bindir@/ldapsearch -x -LLL -b "$basedn" -D "$binddn" -w $bindpw -h $server "(&(objectClass=kolabInetOrgPerson)(mail=*))" mail | grep mail | sed -e "s;mail: ;;"
Index: newconfig.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/newconfig.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- newconfig.in 13 Sep 2005 14:38:22 -0000 1.1
+++ newconfig.in 13 Dec 2005 21:10:26 -0000 1.2
@@ -13,11 +13,12 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@sbindir@
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Propogate changes made to Kolab templates"
exit 0
HASHELP
fi
- at sbindir@/kolabconf
+kolabconf
Index: services.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/services.in,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- services.in 13 Sep 2005 14:38:22 -0000 1.1
+++ services.in 13 Dec 2005 21:10:26 -0000 1.2
@@ -13,9 +13,9 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Display a list of services"
exit 0
HASHELP
Index: showlog.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/showlog.in,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- showlog.in 10 Dec 2005 21:57:11 -0000 1.3
+++ showlog.in 13 Dec 2005 21:10:26 -0000 1.4
@@ -13,8 +13,9 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Display the Kolab server logs"
exit 0
HASHELP
Index: showuser.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/showuser.in,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- showuser.in 12 Dec 2005 00:31:52 -0000 1.3
+++ showuser.in 13 Dec 2005 21:10:26 -0000 1.4
@@ -13,17 +13,18 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Display information on a user"
exit 0
HASHELP
fi
-server=127.0.0.1
-binddn=`sed -n "s;bind_dn : ;;p" @sysconfdir@/kolab/kolab.conf`
-bindpw=`sed -n "s;bind_pw : ;;p" @sysconfdir@/kolab/kolab.conf`
-basedn=`sed -n "s;base_dn : ;;p" @sysconfdir@/kolab/kolab.conf`
+SERVER=127.0.0.1
+BINDDN=`sed -n "s;bind_dn : ;;p" @sysconfdir@/kolab/kolab.conf`
+BINDPW=`sed -n "s;bind_pw : ;;p" @sysconfdir@/kolab/kolab.conf`
+BASEDN=`sed -n "s;base_dn : ;;p" @sysconfdir@/kolab/kolab.conf`
if [ ".$1" = "." ]; then
@@ -31,4 +32,5 @@
exit 2
fi
- at bindir@/ldapsearch -x -LLL -b "$basedn" -D "$binddn" -w $bindpw -h $server "(&(objectClass=kolabInetOrgPerson)(mail=$1))"
+ldapsearch -x -LLL -b "$BASEDN" -D "$BINDDN" -w $BINDPW -h $SERVER "(&(objectClass=kolabInetOrgPerson)(mail=$1))"
+
Index: start.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/start.in,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- start.in 12 Dec 2005 00:31:52 -0000 1.2
+++ start.in 13 Dec 2005 21:10:26 -0000 1.3
@@ -13,12 +13,14 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Start the server"
exit 0
HASHELP
fi
- at bindir@/openpkg rc all start
+openpkg rc all start
+
Index: stop.in
===================================================================
RCS file: /kolabrepository/server/kolabd/kolabd/namespace/libexec/stop.in,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- stop.in 12 Dec 2005 00:31:52 -0000 1.2
+++ stop.in 13 Dec 2005 21:10:26 -0000 1.3
@@ -13,12 +13,13 @@
## You can view the GNU General Public License, online, at the GNU
## Project's homepage; see <http://www.gnu.org/licenses/gpl.html>.
##
+PATH=@bindir@:$PATH
-if [ ".$1" = ".--showhelp" ]; then
+if [ ".$1" = ".--help" ]; then
echo "Stop the server"
exit 0
HASHELP
fi
+openpkg rc all stop
- at bindir@/openpkg rc all stop
More information about the commits
mailing list