Class: Infrataster::Contexts::SslCertificatesContext
- Inherits:
-
BaseContext
- Object
- BaseContext
- Infrataster::Contexts::SslCertificatesContext
- Defined in:
- lib/infrataster/contexts/ssl_certificates_context.rb
Instance Method Summary collapse
Instance Method Details
#certificate ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/infrataster/contexts/ssl_certificates_context.rb', line 7 def certificate = { port: 443 } if server.[:ssl] = .merge(server.[:ssl]) end https = Net::HTTP.new(resource.domain, [:port]) https.use_ssl = true https.verify_mode = OpenSSL::SSL::VERIFY_PEER https.start do https.peer_cert end end |