-
Notifications
You must be signed in to change notification settings - Fork 149
dashing rails under Apache Passenger
So it looks like I was able to get dashing-rails to run under Apache and Passenger. Why would I want to do this?
- I have an existing Apache infrastructure.
- Puma under Apache is extremely hacky (and not in a good way). Each Puma instance must run under its own port. And restarting Apache wont restart Puma...yuck.
- I like being able to assign vhosts on the fly and have everything run under port 80
By default Passenger likes to kill off threads to save on resources. And when it kills off the thread that the Rufus scheduler is running under then Dashing dies. So I had to add the following to my httpd.conf to make it function properly:
RailsAppSpawnerIdleTime 0
PassengerMinInstances 1
This basically prevents Passenger from killing the scheduler thread. So far, so good. I can pull up the dashboard on multiple browsers simultaneously and it doesn't die now after a few minutes.
I don't have a service that's going to be hit by a large number of users. So buyer beware. This works for me but it may or may not work for you.
7/28/15 - Solution above doesn't work for me: RHEL 6.5 64bit, Server Version: Apache/2.2.15 (Unix) DAV/2 Phusion_Passenger/5.0.14
I had to use this option to make rufus scheduler works:
PassengerSpawnMethod direct