Using mongoose and mlab behind a proxy

天大地大妈咪最大 提交于 2020-01-24 02:45:37

问题


Can't connect to my mlab database if I'm behind a proxy.

Any idea how to achieve this? I've already googled and found no answer...

Here is my connection:

mongoose.connect(config.db.URI);
var db = mongoose.connection;
db.on('error', function(){
    throw new Error('unable to connect to database at ' + config.db.URI);
});

来源:https://stackoverflow.com/questions/38197407/using-mongoose-and-mlab-behind-a-proxy

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!