comtihon / mongodb-erlang

MongoDB driver for Erlang
Apache License 2.0
341 stars 267 forks source link

How to use SSL? #247

Open lazercorn opened 2 years ago

lazercorn commented 2 years ago

Can't find docs on how to use SSL in this library. How to?

lazercorn commented 2 years ago

Ok I think I got it. passing arguments as a list of tuples using valid arguments located here: https://www.erlang.org/doc/man/ssl.html#type-client_option as value for ssl_opts key tuple in WorkerOptions list.

Correct?

lazercorn commented 2 years ago

Based off of code from here: https://github.com/comtihon/mongodb-erlang/blob/master/src/mongoc/mc_monitor.erl Seems like I also need to set {ssl, true} as a key value tuple in WorkerOptions list