How to deploy a Ruby on Rails 3 application

1 de noviembre, 2015 @ 01:21 — 0 comentariosDownload PDF

In this guide we explain how to install or deploy a Ruby on Rails 3 that uses Bundler and a Gemfile to manage dependencies.

Note that you require SSH access and access to compilers.

1 - Define the app from the Hosting Panel

1 - Access your Hosting Panel

Just follow instruccions of How to access your Hosting Panel.

2 - Click on Ruby Applications

Look for and click on Ruby Applications icon.


3 - Define the app

Fill in the form and make sure you choose Ruby Hai or Ruby Kon stack:


Once you submit the form you we'll see the app creation result. Take note of the application directory as it's important for the next steps.


2 - Upload application files

You must upload application files and move them to the application directory. The application directory is the application's root folder, for example: if the app name is myapp, the application directory will be /home/username/ruby/myapp and the application's public folder will be /home/username/ruby/myapp/public

If you are developìng a new app you won't have anything to upload, so just run the following commands from the command line:

cd ruby
rm -fr myapp
rails  newmyapp

Note: The above commands supposse that your application's name is myapp

3 - Install Bundler

Now you have to install the Bundler gem, so just run:

gem install bundler

4 - Install dependencies with Bundler

Run the following:

cd ruby/myapp
bundle install

Note that you require a Gemfile in order to be able to use Bundler. If you don't have a Gemfile you will have to create it and specify all application dependencies.