Rocket
Rocket copied to clipboard
add rudimentary TLS support for postgres connections
This fixes #2820. sqlx is also being configured to use rustls-native-certs, so using tokio-postgres-rustls and rustls-native-certs here is consistent with that.
I'm not happy with the error handling, tokio_postgres::Error does not let you construct it, so I cannot turn the rustls errors into a tokio_postgres::Error. I think the only way forward here is to create a custom MakeTlsConnect impl that lazily loads the certs, but that seems like a lot of effort for now.