Skip to content
Browse files

Initial commit

  • Loading branch information...
0 parents commit 9127fb3c4e4a7bbcdfe3c40af13aa6cd102eafd1 @EricR committed Sep 13, 2012
Showing with 29 additions and 0 deletions.
  1. +8 −0 README.md
  2. +16 −0 app.rb
  3. +5 −0 config.ru
8 README.md
@@ -0,0 +1,8 @@
+Smallest Rails App
+===============
+
+The smallest Rails app possible. To run:
+
+```bash
+bundle exec RAILS_ENV=production rackup -p 3000 -s thin
+```
16 app.rb
@@ -0,0 +1,16 @@
+class App < Rails::Application
+ config.cache_classes = true
+ config.secret_token = "sf05239_%424db42#AR-BRS53fsa6YRe22!$3tfae33"
+
+ routes.append do
+ root :to => "pages#hello"
+ end
+end
+
+class PagesController < ActionController::Metal
+ include ActionController::Rendering
+
+ def hello
+ render :text => "Hello world!"
+ end
+end
5 config.ru
@@ -0,0 +1,5 @@
+require "rails"
+require "action_controller/railtie"
+require "./app.rb"
+
+App.initialize!; run App

0 comments on commit 9127fb3

Please sign in to comment.
Something went wrong with that request. Please try again.