I'm running a server on c9.io using node.js and trying to connect to Mysql I guess I get this error "errorError: getaddrinfo ENOTFOUND" because the connection to the db is wrong.
I'm using this:
var connection = mysql.createConnection({
host: "REMOTE_ADDR",
user: "MYUSERNAME", // this is replaced by my username
database: "c9",
port: 3306 });
Any idea what's wrong?
Thanks!
I know it's been a while since this was asked but I spent the better part of today trying to fix this. What to check for:
Within your nodejs source:
On your db VM/Box/Instance: