Ruby on rails Production mode on apache2 - ruby-on-rails

I am trying to switch from development mode to production my project in ruby on rails. Do I really need to install passenger? I have already apache server running in the system. Please advise. Thanks.

Yes, You need to install passenger to configure your rails app with Apache server. Here is the step by step solution for the same.

Related

Rails application running on Apache HTTPD

Is there a way to run Ruby on Rails app on Apache HTTPD (CentOS)?
Is this just a matter of setting up httpd.conf with VirtualHost?
Passenger is probably the easiest way to get that running. Here's a tutorial on installing Passenger on CentOS6, and here are prebuilt rpms.
http://rubyonrails.org/deploy
Check Rails site, I think you have to use a Proxy, unless I'm misunderstanding what you mean by HTTPD. Seems like you want a simple Apache setup, Rails should be able to help.
EDIT: James answer looks perfect. Same as mine, but he has real CENTOS tutorials... I've never used CENTOS, just done this through Ubuntu.
You can run mod_rails aka Passenger or a Mongrel Cluster or Thin Cluster.
I find passenger the easiest, you can download it Here
The Steps are quite easy
sudo gem install passenger
sudo passenger-install-apache2-module
Follow instructions on screen.

Running nginx in rails automatically

I am using rails 2.3.9, rubygems 1.8.24, ruby 1.9.3 and Windows 7 ultimate 64-bit
I just installed nginx as my web server through passenger. Now I want to run nginx as my default server such that when i run ruby script/server, it runs instead of the default WeBrick. Is there any way to do this? Thanks a million.
Nginx doesn't work the way you described. Once it is started, you won't need to run script/server, the rails app will be run at the same time when the Nginx/Apache started.
So, just deploy your rails app following the 'Passenger' manual( in development mode), and you will get your app always running.
so, as conclusion, we can tell that, when deploying a Rails app, Nginx and Apache is in the same group( work together with Passenger), and Mongrel/Webrick/Thin is another group(script/server approach).
You may want to take a look at Foreman.

Special Steps for Rails Deployment?

I'm Deploying a rails app on the server for production? What are the special steps, I should follow in production installation, that is different from development.
I've installed passenger, passenger-apache2-module
I've also run bundle install --deployment
What are other special treatments, I should use for production?
Thanks.
With our deployment servers we have a fairly easy setup
ubuntu
apache + passenger
a rails user from where the apps are
actually run "/home/rails/apps/fancy_app_name"
and we have a webistrano app running to handle the deployments (so our development
machines don't have to be aware of all production steps)

How to run ruby on apache?

I'm very new to ruby and I can run ruby scripts on command line easily, but I want to output my script to a browser, not just using the command line.
Your help will be much appreciated, thanks.
Passenger is probably the easiest way to run Rails applications.
I'd recommend either Passenger or Unicorn, both of which are extremely popular in production environments. Passenger is typically easier to setup.
See this blog post:
"Install RVM, Passenger, Nginx and Rails 3 on Ubuntu Lucid Lynx". You can use WEBrick/Thin for development perhaps.

How can I deploy Ruby On Rails Application in Apache in LAMP on ubuntu without installing Ruby and rails

Please provide me the guidance for deploying the ruby on rails application in apache in lamp without installing Ruby or rails?
You need it. Install ruby with all dependencies and install Phusion Passanger. The way I read your question was like this, lets go ride the bicycle with no wheels, let me check my email with no browser - it does not make sense.
you may use Phusion Passenger with Apache for deploying the ruby on rails application.
If it is Ubuntu, all the dependencies are just an apt-get line of code away, so it is well worth install it someway

Resources