I'm trying to configure GlassFish to start within a jail.
I've written this simple script:
The script is located in the /usr/local/etc/rc.d directory. Filename is glassfish. Permission is set to 555.
I've also added
to rc.conf.
GlassFish does NOT start when I reboot the machine or restart the jail. However, when I execute the command [cmd=]/usr/local/etc/rc.d/glassfish start[/cmd] from within the jail (as the root user), it does start as it should.
What is the problem in my configuration? Why does it start on reboot or jail restart?
I've written this simple script:
Code:
#!/bin/sh
. /etc/rc.subr
name=glassfish
rcvar=glassfish_enable
start_cmd="${name}_start"
stop_cmd="${name}_stop"
glassfish_start()
{
/usr/local/glassfish/glassfish3/bin/asadmin start-domain
}
glassfish_stop()
{
/usr/local/glassfish/glassfish3/bin/asadmin stop-domain
}
load_rc_config $name
run_rc_command "$1"
The script is located in the /usr/local/etc/rc.d directory. Filename is glassfish. Permission is set to 555.
I've also added
Code:
glassfish_enable="YES"
GlassFish does NOT start when I reboot the machine or restart the jail. However, when I execute the command [cmd=]/usr/local/etc/rc.d/glassfish start[/cmd] from within the jail (as the root user), it does start as it should.
What is the problem in my configuration? Why does it start on reboot or jail restart?