Other Pages

Running Your Application Locally

Goals

  • Let's fire up the application locally

Steps

Step 1

Type this in the terminal:
rails server

Step 2

Point your web browser to http://localhost:3000

See your web app actually running!

Step 3

When at the terminal with your running rails server, type Control-C to stop rails server. You can do this now.

Expected result:
^C[2012-03-31 08:33:11] INFO  going to shutdown ...
[2012-03-31 08:33:11] INFO  WEBrick::HTTPServer#start done.
Exiting

Explanation

rails server ran your application locally just like Heroku will be running it on their servers.

This provides a very simple means to see your changes before you commit and push them to Heroku.

Control-C is a way of closing or cancelling terminal programs. Since rails server runs forever, you need to interrupt it with Control-C.

Next Step:

Back to Add The Project To A Git Repo