Date: Fri, 4 May 2007 12:59:49 +0100 From: "Charles Mason" <charlie.mas@gmail.com> To: freebsd-questions@freebsd.org Subject: Creating an rc.d script for Jboss Web Message-ID: <1960fb140705040459w6631adeanc901b8c09806d12a@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
I am trying to run Jboss Web on FreeBSD, which is basically a Tomcat derived web server which use APR to replace the Java based static file serving in Tomcat. This makes it much faster but requires the native modules to be complied for each platform. I have successfully managed to compile these and it appears to all work very well. My problem is creating an rc.d script to start and run it as a daemon. To start Jboss Web there is an sh script called run.sh which after a bit of config runs the JVM and the relevant JARS. I created a simple rc.d script to run this. My problem is running the script does not run Jboss Web as a daemon instead it runs it as if running ./run.sh from the terminal and halts the rc.d process. The Jboss Web server is actually working, its just not ideal. I have included the current script below. #!/bin/sh . /etc/rc.subr name="JbossWeb" rcvar=`set_rcvar` command="/etc/JbossWeb/bin/run.sh" command_interpreter="/bin/sh" load_rc_config $name run_rc_command "$1" How can I change the script to run run.sh in the background and continue the rc.d system. Charlie
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1960fb140705040459w6631adeanc901b8c09806d12a>