lundi 6 juillet 2015

Deploying Ruby on Rails 2.3 on Production

Am sorry for the noobness for this,

I am developing a ruby on rails application on my ubuntu 14.04. As for development, i'm starting my application using ruby script/server. Ruby -v 1.8.7 Rails -v 2.3.14 MySql

Now my question is how to deploy this on production? Am planning to use Ubuntu 14.04 Server as well.

I read about the Phusion Passenger but I did not understand what is that for.

I was hoping to make the ubuntu server as a localhost. So that if I point to the browser like myrailsapp, my application will be available (Normally I will use script/server). Do I have to use the script/server command everytime the server will restart?

Please tell me if im on the right track.

------------ I follow a tutorial --------------

I follow a tutorial like this one but I can't figure out how to make a virtual host working I created a virtual host like this: /etc/hosts 0.0.0.0 example.com

/opt/nginx/conf/nginx.conf

    server {
    listen       80;
    server_name  example.com;
    passenger_enabled on;

    location / {
        root   /opt/nginx/html/ror/blog/public;
    }
}

On my browser i get 403 Forbidden And do i have to start my rails app like script/server?

Aucun commentaire:

Enregistrer un commentaire