Put Your App Online With Ninefold
Created by Risa Batta, @mookiy
OK. You’ve got the basics down and want to show off your awesome new Rails App to the world. Great!
Preparing your app
Update your database to Postgres
In order to deploy to Ninefold, you’ll need to change your Gemfile to get your database to work properly. In the Gemfile, change the following:
group :development do gem 'sqlite3' end group :production do gem 'pg' end
Save then run
bundle install --without production to setup your dependencies. By running bundle install, the Gemfile and Gemfile.lock files will match up. By running –without production, it skips the group :production.
You’ll have to add your app to your Git repository. Type the following into the terminal:
git init git add . git commit -m "initial commit"
Deploying with Ninefold
Ninefold will be pulling your code in from GitHub, so first thing’s first.
1.Sign up for a free account at ninefold.com.
2.Click on the giant Deploy Now button.
3.Choose GitHub as your repository you want to deploy from.
4.Click on Sign in with GitHub. Of course, read the blurb about how Ninefold accesses your GitHub.
We will ask you to grant us some permissions. (Ninefold will never make changes to your codebase or read your followers or your gists. These were just set by GitHub by default. We just require this so we can redeploy your app for you.)
5.Time to select a repository and branch in the Connect Repository step. Remember to choose the Rails app you want to deploy. You will want to click on the Repo you want (e.g. railsgirls) and then the branch (e.g. master). Click Next.
6.In the next window, choose a combined server. Pick your primary region based on your location. Click Next.
7.This is the last step! Name your app (it will also become part of your deployed app name). Click Deploy App.
8.Boom, done! Grab a drink, sit back, and relax. Ninefold will deploy your app!
9.Once your app’s been deployed, you’ll want to click on View Details. You’ll see your app information. Click on the name that has yourappname1234.ninefold-apps.com (railsgirls4fcd.ninefold-apps.com in my case).
10.Celebrate! Your app is now online for the world to see!
Every time you push your changes to your github, Ninefold will automatically redeploy your app for you (just takes a few minutes)!