Method: Docker.env_options

Defined in:
lib/docker.rb

.env_optionsObject



49
50
51
52
53
54
55
56
57
58
59
60
# File 'lib/docker.rb', line 49

def env_options
  if cert_path = ENV['DOCKER_CERT_PATH']
    {
      client_cert: File.join(cert_path, 'cert.pem'),
      client_key: File.join(cert_path, 'key.pem'),
      ssl_ca_file: File.join(cert_path, 'ca.pem'),
      scheme: 'https'
    }.merge(ssl_options)
  else
    {}
  end
end