project id: 1971e1a2-608a-41cc-88bf-6980e99ce984
Deployment crash for basic ejs app. Logs show problem with mongo database.
Solution:Jump to 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
15 Replies
Project ID:
N/A
what is the state of your mongo database deployment
mongo database deploys with no problems on logs
okay what is the error you are getting
screen shot for the logs error
your client code is incorrect, please make sure you are using the correct connection details
I am using the same connection details as before, when it deployed ok.
That code was not changed in the Git repository.
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 slightestOk, 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?
railway isn't changing anything in your index.js file, you simply have something missconfigured
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
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.
i think you shouldn't do something so drastic, instead, simply fix your coding / config mistake
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!
no problem!