on 08-06-2021 11:25 AM
Hi experts,
we created an instance of the “postgresql-db” (“PostgreSQL, hyperscaler option”, plan "standard") service in a subaccount/org, lets call it “A”, on the Cloud Foundry BTP Platform. I can connect to the database running a node.js application in the same org/space or using a ssh tunnel on my local machine just fine.
But am I able to connect to the database from an application running in a space of a different org “B”? I created a “Service Key”, in org “A”, and imported this key in a space of org “B” via “Instances -> Create -> User-Provided Service Instance”.
My node.js application can read the properties of this key, but fails to connect to the database. Also it fails if I try to connect via
psql -h <hostname> -p <port> “dbname=<dbname> user=<username> sslrootcert=<> sslmode=verify-ca
on my local machine, like described in the help portal, with the parameters of the “Service Key”:
Can you guide me in the right direction? Is it even possible to connect to a postgres database instance when the client is not part of the org the postgres instance is running in.
Here is a quick drawing:
Error in node.js module "pg":
Error: connect ETIMEDOUT xx.xx.xx.xxx:2407 at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1137:16) {
errno: 'ETIMEDOUT',
code: 'ETIMEDOUT',
syscall: 'connect',
address: 'xx.xx.xx.xxx',
port: 2407
}
Best regards
Tim
User | Count |
---|---|
74 | |
10 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.