Being new to deploying Rails apps I’m having some trouble with Chapter 16 as it seems a bit vague and assumes the reader knows how to properly setup/configure Apache. Spending some time Google I feel like I know a bit more though definitely not enough to get this off the ground. Here are my current questions.
1) “The first will be to enable your freshly built module and will involve adding lines such as the following to our Apache configuration.”
LoadModule passenger_module /home/rubys/.rvm/…/ext/apache2/mod_passenger.so PassengerRoot /home/rubys/.rvm/gems/ruby-1.9.3-p0/gems/passenger-3.0.8 PassengerRuby /home/rubys/.rvm/wrappers/ruby-1.9.3-p0/ruby
Where in the configuration file does this information go? Does it matter?
2) Deploying our Application Locally <VirtualHost *:80> ServerName depot.yourhost.com DocumentRoot /home/rubys/work/depot/public/ <Directory /home/rubys/work/depot/public> AllowOverride all Options -MultiViews Order allow,deny Allow from all </Directory> </VirtualHost>
Again, where does this code go within the configuration file, does it matter? Is the server name something arbitrary, meaning I can pick anything I want so long as I map it in the hosts file? I assume the DocumentRoot is the complete file path to the Rails app so given the location of my rails app would I use the following, ~/projects/depot/public ?
3) What goes in the hosts file? 127.0.0.1 depot.yourhost.com (where depot.yourhost.com matches the ServerName from the Apache config file?)
Very confused by this setup with very vague steps and would appreciate any help which you can provide, even if it’s only a partial answer.
** Note: Everything I find about OSX and Passenger links me to Ben Ruebenstein’s guide which no longer exists due to an error.