Commit 1e720d7f authored by Samir Noir's avatar Samir Noir 🧀
Browse files

Fix tls verify_peer in development environment

parent 07176d99
......@@ -55,7 +55,7 @@ development:
base_uri_out: https://127.0.0.1:8443
uri_out_private_key_file: /etc/ssl/certs/clientkey_nopass.pem
uri_out_cert_chain_file: /etc/ssl/certs/clientcert.pem
uri_out_verify_peer: false
uri_out_verify_peer: OpenSSL::SSL::VERIFY_NONE
reference_repository_path: ~/reference-repository
smtp_host: localhost
smtp_port: 2525
......
......@@ -103,7 +103,7 @@ module Grid5000
if tls_options.present?
http.cert = OpenSSL::X509::Certificate.new(File.read(tls_options[:cert_chain_file]))
http.key = OpenSSL::PKey::RSA.new(File.read(tls_options[:private_key_file]))
http.verify_mode = tls_options[:verify_peer]
http.verify_mode = tls_options[:verify_peer].constantize if tls_options[:verify_peer]
end
request = case method
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment