By iMode
**Hello,
I have a Ubuntu droplet running my app, and am also running localy from a MacBook, and I am having truble connecting to it.**
Here is the string I am using:
“Host=db-postgresql-fra1-XXXx-do-XXXx-XXX-0.b.db.ondigitalocean.com; Port=25060; Database=XXXX; Username=XXXX; Password=XXXXX; SslMode=Require”
This is the error i get: The remote certificate was rejected by the provided RemoteCertificateValidationCallback
How do I specify the path to the CA Cert, and can I just have it in the project?
Thanks for any help.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Hi there,
There are a few ways to do that:
Client Certificate directly in the connection string parameter.PGSSLCERT environment variable.~/.postgresql/postgresql.crt file with your CA certificate.For more information I could suggest taking a look at the docs here:
https://www.npgsql.org/doc/security.html?tabs=tabid-1
Let me know if you have any questions.
Best,
Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Scale up as you grow — whether you're running one virtual machine or ten thousand.

From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.
