lib/grenache/http.rb in grenache-ruby-http-0.2.9 vs lib/grenache/http.rb in grenache-ruby-http-0.2.11
- old
+ new
@@ -1,8 +1,14 @@
module Grenache
class Http < Grenache::Base
+ default_conf do |conf|
+ conf.thin_threaded = true
+ conf.threadpool_size = 10
+ conf.verify_mode = Grenache::SSL_VERIFY_PEER
+ end
+
def listen(key, port, opts={}, &block)
start_http_service(port,&block)
announce(key, port, opts) do |res|
puts "#{key} announced #{res}"
@@ -30,9 +36,10 @@
server.ssl_options = {
private_key_file: config.key,
cert_chain_file: config.cert_pem,
verify_peer: true
}
+ server.backend.ca_cert = File.read config.ca
end
server.start
}
end