You are not logged in.
Pages: 1
Hello all I am new to the Arch Linux forums and have a relatively simple question (I think). I just downloaded and setup openfire on my archlinux server and would like to create an rc.d script for it so I can load it at startup and learn more about rc.d scripts in general. I was wondering if anybody has created an rc.d script for openfire? If not does a tutorial regarding the making of a typical rc.d script exist for archlinux?
Thank you,
Dan
Offline
I'm not aware of the existence of such a tutorial... but I know where you can find dozens of examples! Try looking through the existing scripts in /etc/rc.d; they really aren't that complicated.
M*cr*s*ft: Who needs quality when you have marketing?
Offline
Thank you pointone for the quick reply, I will do that and try to figure it out.
Offline
i just wrote an rc.d script for dropbox; it took some fiddling but i finally got it working. i used this. there's an arch example at the end
for what it's worth here's the dropboxd script i finally got working
#!/bin/bash
PATH=/usr/sbin:/usr/bin:/sbin:/bin
DESC="Dropbox sharing service"
NAME=dropboxd
DAEMON=/home/patrick/.dropbox-dist/dropboxd
DAEMON_ARGS=""
PIDFILE=/var/run/$NAME.pid
. /etc/rc.conf
. /etc/rc.d/functions
case "$1" in
start)
stat_busy "Starting dropbox service..."
$DAEMON &
if [ $? -gt 0 ]; then
stat_fail
else
add_daemon $NAME
pidof $NAME > $PIDFILE
stat_done
fi
;;
stop)
stat_busy "Stopping dropbox service..."
if [ -a $PIDFILE ]; then
PID=`cat $PIDFILE`
kill $PID > /dev/null
if [ $? -gt 0 ]; then
stat_fail
else
rm $PIDFILE
rm_daemon $NAME
stat_done
fi
else
pkill $NAME
if [ $? -gt 0 ]; then
stat_fail
else
stat_done
fi
fi
;;
restart|force-reload)
$0 stop
sleep 1
$0 start
;;
esac
exit 0
Last edited by brisbin33 (2009-02-04 20:48:22)
//github/
Offline
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Also, abs package provides a proto version of an rc script which can be used as a template. It's located in /usr/share/pacman/rc-script.proto.
Offline
fwojciec --- you are 2 posts away from leet !!!
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
OK -- the next one is going to be my last post ever
Offline
Guys I can't you enough for the help, I did some learning about how to build packages so it's worth a try for openfire Thank you so much guys this community is awesome!!
Offline
Pages: 1