For security reasons, your DB server needs whitelisting and Forge will allow a basic connection. However, you really should lock it down further on the server. The DB server should be set up so that only specific IP address' and ports can access it. That is probably the cause of your issue. You should still be able to ssh into the DB server with the installed ssh key. Password access should be blocked by default with Forge.
Connecting to Database from local machine
Hi.
I've got 2 servers setup with Digital ocean which was provisioned using forge. I have one as an app server and the other a database server.
I can connect using ssh tunnel on sequel pro but unless I add my IP to the firewall in forge, I cannot connect to the server when using local dev. I try to use a testing db on the server so when I'm away from the office I can carry on with local dev with the same data.
Any ideas on how to allow my local computer to connect ??
Cheers
I would avoid allowing mysql access from outside your db server except for the web servers. If you have ssh access to the db server you can create an ssh tunnel over port 22 to allow access to the local port 3306 as per
https://www.linode.com/docs/databases/mysql/create-an-ssh-tunnel-for-mysql-remote-access/
Please or to participate in this conversation.