MongoDB connection issues

2 years ago

So when ever i try to connect to my database, i get this error. It worked before with my local database. But wanna have it on railway. I just straigt copied the url from the railway dashboard.

10 Replies

2 years ago

n/a


2 years ago

I assume you may have changed the database name?


2 years ago

I have set it to "test" wich already exist in it


2 years ago

MONGO_URL="mongodb://:@:/test"

2 years ago

have you changed anything service variables wise?


2 years ago

I works now, by removing the "/test"


2 years ago

is this mongoose?


2 years ago

Yes


2 years ago

you need to specify the database name in the options object


2 years ago

Alright thanks brody 👌


Loading...