Class: ServerHealthCheckRails::HealthController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- ServerHealthCheckRails::HealthController
- Defined in:
- app/controllers/server_health_check_rails/health_controller.rb
Instance Method Summary collapse
Instance Method Details
#index ⇒ Object
3 4 5 6 |
# File 'app/controllers/server_health_check_rails/health_controller.rb', line 3 def index check = ServerHealthCheckRails::HealthCheck.all render status: check.http_status, json: check.to_h end |
#show ⇒ Object
8 9 10 11 |
# File 'app/controllers/server_health_check_rails/health_controller.rb', line 8 def show check = ServerHealthCheckRails::HealthCheck.new(params[:id]) render status: check.http_status, json: check.to_h end |