here is an /etc/init.d/mingled file#271
|
|
Here is a file that can be used as /etc/init.d/mingled on most Linux installations. All you need to do is The configure step adds a mingle user and sets things up so that mingled Might I suggest that the installation media include this as mingle/linux/etc/init.d/mingled in some future release. Or provide it in an RPM installer. !/bin/bash#
stop(){ status(){ restart(){
stop
start chkconfig—add mingled chkconfig mingled on chkconfig—list mingled
exit $? |
|
|
I’d like to get this over in Debian (Ubuntu 6.06 LTS) ... I think I’ll need to use “su -mingle_username ${MINGLE_USER} ${MINGLE_ROOT}/MingleServer start” to start things up. (That or use su -c… I’ve got some more reading to do). How about the chkconfig? I’ve got to figure out what that is debian’s system. I’ve been reading here [1], but if anyone has tips, please could you leave a post? Thanks, Jonathan |
|
|
Here is what we use in RedHat/Fedora Core/CentOS, I think it will work for Debian/Ubuntu Step to install/run this script: /etc/rc.d/init.d/mingle : !/bin/bash#
[ -z ”$MINGLE_USER” ] && MINGLE_USER=nobody RETVAL=0 start(){
su – $MINGLE_USER -c ”/export/users/mingle/mingle/MingleServer start” stop(){
su – $MINGLE_USER -c ”/export/users/mingle/mingle/MingleServer stop” case ”$1” in
start)
start
;;
stop)
stop
;;
restart)
stop
start
;;
*)
echo $”Usage: $0 {start|stop|restart}”
RETVAL=1 |
|
|
Here’s what I settled with, it seems to work. (apologies for the funny formatting, here’s a pastie: http://pastie.caboo.se/94705)
(you can also look at a sample /etc/init.d/scaffold script for help writing them) |
