Open sgrodzicki opened 2 months ago
[!NOTE] A similar issue has been reported for Node.js on Stack Overflow: https://stackoverflow.com/q/75652653
I am unable to connect to a managed PostgreSQL database on AWS RDS. There seems to be an issue with the certificate chain verification. It only works with the sslmode=no-verify option, which is obviously not a solution for production environments.
sslmode=no-verify
# docker-compose.yaml services: nango-server: container_name: nango-server image: nangohq/nango-server:hosted platform: linux/amd64 environment: NANGO_DATABASE_URL: postgres://*****:*****@database-6s1c0ppu.cukpee2wtyaq.eu-west-1.rds.amazonaws.com:5432/nango?ssl=1
% docker-compose up [+] Running 1/0 ✔ Container nango-server Created 0.0s Attaching to nango-server nango-server | 03:35:52.099 info (Server) Migrating database ... nango-server | node:internal/process/promises:289 nango-server | triggerUncaughtException(err, true /* fromPromise */); nango-server | ^ nango-server | nango-server | Error: self-signed certificate in certificate chain nango-server | at TLSSocket.onConnectSecure (node:_tls_wrap:1674:34) nango-server | at TLSSocket.emit (node:events:518:28) nango-server | at TLSSocket.emit (node:domain:488:12) nango-server | at TLSSocket._finishInit (node:_tls_wrap:1085:8) nango-server | at ssl.onhandshakedone (node:_tls_wrap:871:12) nango-server | at TLSWrap.callbackTrampoline (node:internal/async_hooks:130:17) { nango-server | code: 'SELF_SIGNED_CERT_IN_CHAIN' nango-server | } nango-server | nango-server | Node.js v20.12.2 nango-server exited with code 1
NAN-1677 Unable to connect to AWS RDS
I am unable to connect to a managed PostgreSQL database on AWS RDS. There seems to be an issue with the certificate chain verification. It only works with the
sslmode=no-verify
option, which is obviously not a solution for production environments.