2 # This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
5 ##### SSL - ward, 2012-10-15
7 require 'rails/commands/server'
10 require 'webrick/https'
13 class Server < ::Rack::Server
17 :environment => (ENV['RAILS_ENV'] || "development").dup,
20 :pid => File.expand_path("tmp/pids/server.pid"),
21 :config => File.expand_path("config.ru"),
23 :SSLVerifyClient => OpenSSL::SSL::VERIFY_NONE,
24 :SSLPrivateKey => OpenSSL::PKey::RSA.new(
25 File.open("config/api.clinicalfuture.com.key.pem").read),
26 :SSLCertificate => OpenSSL::X509::Certificate.new(
27 File.open("config/api.clinicalfuture.com.crt.pem").read),
28 :SSLCertName => [["CN", WEBrick::Utils::getservername]]
36 APP_PATH = File.expand_path('../../config/application', __FILE__)
37 require File.expand_path('../../config/boot', __FILE__)
38 require 'rails/commands'