project id: 1971e1a2-608a-41cc-88bf-6980e99ce984

Deployment crash for basic ejs app. Logs show problem with mongo database.
Solution:
please review your mongodb client to make sure you are creating a client with the correct credentials as per mongo's syntax for the client initiator
Jump to solution
15 Replies
Percy
Percy4mo ago
Project ID: N/A
Brody
Brody4mo ago
what is the state of your mongo database deployment
BobPar_21
BobPar_21OP4mo ago
mongo database deploys with no problems on logs
Brody
Brody4mo ago
okay what is the error you are getting
BobPar_21
BobPar_21OP4mo ago
screen shot for the logs error
No description
Brody
Brody4mo ago
your client code is incorrect, please make sure you are using the correct connection details
BobPar_21
BobPar_21OP4mo ago
I am using the same connection details as before, when it deployed ok. That code was not changed in the Git repository.
Brody
Brody4mo ago
you have missconfigured something, please see those logs, it is attempting to connect to mongo at ::1 and that's just not correct in the slightest
BobPar_21
BobPar_21OP4mo ago
Ok, I will examine my code. I noted when it deployed ok 6 months ago, Railway changed connection code in the index.js file. Should I use that?
Brody
Brody4mo ago
railway isn't changing anything in your index.js file, you simply have something missconfigured
Solution
Brody
Brody4mo ago
please review your mongodb client to make sure you are creating a client with the correct credentials as per mongo's syntax for the client initiator
BobPar_21
BobPar_21OP4mo ago
Seems I need to role back to an earlier repository, and check the mongo variables and other settings. Other than that, I can delete the mongo service and try to build another.
Brody
Brody4mo ago
i think you shouldn't do something so drastic, instead, simply fix your coding / config mistake
BobPar_21
BobPar_21OP4mo ago
I will work with the connection code in the index. js file. This may take some time. your suggestion was helpful, I was able to change the mongo connection code and it worked, the revised app deploys. Thanks!
Brody
Brody4mo ago
no problem!
Want results from more Discord servers?
Add your server