Skip to content

Instantly share code, notes, and snippets.

@phil-monroe
Created September 23, 2011 23:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save phil-monroe/1238715 to your computer and use it in GitHub Desktop.
Save phil-monroe/1238715 to your computer and use it in GitHub Desktop.
Routes file for App-Runway
AppRunway::Application.routes.draw do
constraints(:subdomain => "") do
devise_for :users do
get "/login" => "devise/sessions#new"
delete "/logout" => "devise/sessions#destroy"
end
resources :users do
resources :apps do
resources :emails, only: [:index]
end
end
resources :apps, only: :index do
resources :emails, only: :create
end
end
constraints(Subdomain) do
match '/' => 'apps#show'
end
root :to => 'apps#show'
match 'about' => 'website#about', :as => :about
match 'pricing' => 'website#pricing', :as => :pricing
match 'support' => 'website#support', :as => :support
match 'tour' => 'website#tour', :as => :tour
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment