Permalink
Browse files

use heroku ssl cert

  • Loading branch information...
1 parent e5523c9 commit dcc180fcc167cd6cd5a2d72d3347a10b7401f483 @qrush qrush committed May 6, 2011
Showing with 47 additions and 3 deletions.
  1. +36 −0 data/heroku.crt
  2. +9 −1 lib/daikon.rb
  3. +2 −2 lib/daikon/client.rb
View
@@ -0,0 +1,36 @@
+-----BEGIN CERTIFICATE-----
+MIIGLjCCBRagAwIBAgIQBW45cqDTT/6c02Tq4xlhcTANBgkqhkiG9w0BAQUFADBm
+MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
+d3cuZGlnaWNlcnQuY29tMSUwIwYDVQQDExxEaWdpQ2VydCBIaWdoIEFzc3VyYW5j
+ZSBDQS0zMB4XDTEwMDgyNjAwMDAwMFoXDTEzMDgyOTIzNTk1OVowaDELMAkGA1UE
+BhMCVVMxEzARBgNVBAgTCkNhbGlmb3JuaWExFjAUBgNVBAcTDVNhbiBGcmFuY2lz
+Y28xFTATBgNVBAoTDEhlcm9rdSwgSW5jLjEVMBMGA1UEAxQMKi5oZXJva3UuY29t
+MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDFNwvpUS9ZWlQrnZzLht9DT4s2
+nSnjxBoL9k4HN6zag0OrkcJS4bcr1l6/WiPDYzBESRoRW0nZlhA6oHVJY0eeyfLY
+7F9FQxJ/EXz8inC17nquEey7H7+enD/NLZL+Vzc3pZWYp0+dTRs6k9oe7ClCU9pB
+RPfmeoh/qKj9tR6VWQIDAQABo4IDWDCCA1QwHwYDVR0jBBgwFoAUUOpzidsp+xCP
+nuUBINTeeZlIg/cwHQYDVR0OBBYEFL8FTPxKuZKTrYKeRZQ7j4HifKSZMCMGA1Ud
+EQQcMBqCDCouaGVyb2t1LmNvbYIKaGVyb2t1LmNvbTB/BggrBgEFBQcBAQRzMHEw
+JAYIKwYBBQUHMAGGGGh0dHA6Ly9vY3NwLmRpZ2ljZXJ0LmNvbTBJ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CULi9RVBOLcFZW/bGFF++7HGpaJXRDS5eQP/e5qCfdtHvWiX+6ATIGSMg2F
+ZAMPAo0wVmrMYkQaVNpmxEmyYdEJp8oxjyMahjVsDUptCPqMTmY2nFm7bRM89D/6
+fIqWtKWH1nfGK3IIYlQN13GIN5p26GrF139Hq9Ndu5ABl/oLFkaM+qu6CyDY5Y26
+KNE9hEj2Zvtw2btKLtP0w2ROlxU+AIQb1mbYrldVIkYMmuHfDt8MUI4TwR+Ip6uT
+638=
+-----END CERTIFICATE-----
View
@@ -29,5 +29,13 @@
require 'daikon/daemons_hacks'
module Daikon
- VERSION = "0.9.1"
+ VERSION = "0.9.2"
+
+ def self.data_dir(path)
+ if datadir = Gem.datadir("daikon")
+ File.join(datadir, path)
+ else
+ ""
+ end
+ end
end
View
@@ -36,9 +36,9 @@ def request(method, path, options = {})
url = "#{config.server_prefix}#{path}"
options[:head] ||= {}
options[:head]['Authorization'] = config.api_key
- options[:ssl] = {:verify_peer => true}
+ options[:ssl] = {:verify_peer => true, :cert_chain_file => Daikon.data_dir("heroku.crt")}
- log "#{method.to_s.upcase} #{url}"
+ log "#{method.to_s.upcase} #{url} with ssl cert #{options[:ssl][:cert_chain_file]}"
http = EventMachine::HttpRequest.new(url).send(method, options)
http.callback do

0 comments on commit dcc180f

Please sign in to comment.