-
-
Notifications
You must be signed in to change notification settings - Fork 713
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to read custom certs for SSL postgres when in docker #1432
Comments
Hi thanks for reporting, First 'fs.readFileSync' will simply not work, you would need to set the actual text-content of the file, you can't instruct it to read the content from a file. I know NODE_EXTRA_CA_CERTS do work (we used this technique previously for the hosted offering), so this must be some configuration issues (maybe the path was not actually correct to the cert?) |
I was able to configure it with I am now able to make Unleash verify my postgres certificate, so I would close this issue unless you want to use it to add proper support for passing a cert path to |
In case somebody faces this situation in the future:
|
Reopening based of this conversation in our community Slack: https://unleash-community.slack.com/archives/C03GWTN7XMG/p1689777281226039 where using |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
When trying to connect an Unleash self-hoster instance towards a Postgres DB that uses self-signed certs, I am getting the following error
Following some other issues like this one and checking the docs in here along with the environment variables supported by Unleash, documented here I know I can do the following to totally disabling checking for certificates and allowing self-signed certs:
But this has a problem about the certificate not being verified, which is not ideal. I would like our certificate to be verified, and for that it seems I should be able to pass it in the
ca
object as part of theDATABASE_SSL
variable, like thisbut this configuration does not seem to be valid in Unleash, it just gets ignored and I still get the error about the
self signed certificate in certificate chain
I also tried using other node-specific variables like
NODE_EXTRA_CA_CERTS
but the result was the sameFinally, there is no way to have the certificate signed by a trusted CA (the Postgres instance is not controlled by me, and they just provide the certificate, so you can at least add it to your known certificates)
The text was updated successfully, but these errors were encountered: