Class: Skydrive::EmberController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- Skydrive::EmberController
- Defined in:
- app/controllers/skydrive/ember_controller.rb
Instance Method Summary collapse
- #generate_authentication ⇒ Object
- #health_check ⇒ Object
- #index ⇒ Object
- #new_authentication ⇒ Object
Instance Method Details
#generate_authentication ⇒ Object
13 14 15 16 17 18 19 20 21 |
# File 'app/controllers/skydrive/ember_controller.rb', line 13 def generate_authentication @account = Account.new(account_params) @account.key = SecureRandom.uuid @account.secret = SecureRandom.hex if !@account.save render 'new_authentication', layout: false end render layout: false end |
#health_check ⇒ Object
23 24 25 26 27 28 29 |
# File 'app/controllers/skydrive/ember_controller.rb', line 23 def health_check if database_healthy? head 200 else head 500 end end |
#index ⇒ Object
5 6 |
# File 'app/controllers/skydrive/ember_controller.rb', line 5 def index end |
#new_authentication ⇒ Object
8 9 10 11 |
# File 'app/controllers/skydrive/ember_controller.rb', line 8 def new_authentication @account = Account.new render layout: false end |