views:

31

answers:

1

Is there an easy way to have backgroundrb started (restarted) when the server reboots?

Ex. What if your hosting use mongrel cluster and you have no access to it (except start/stop) One of solution i found on forums is code snippet in backgroundrb plugin with check for PID exist (if not exist start with exec or system) etc. Just your ideas.

A: 

My solution: in script/server before rails run add system call for bacgroundrb

# AUTO START BACKGROUDRB
#stop if already runing
system( "./script/backgroundrb stop")
#start
system( "./script/backgroundrb start")
u24s