-
Notifications
You must be signed in to change notification settings - Fork 11k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failed to connect to mongodb when using docker-compose up
#962
Comments
if you do |
I get the following. I have to ctrl-C the
|
Running
|
How does your docker-compose.yaml look? Have you made any changes? |
When you type docker-compose up make sure to specify the -d flag to daemonize it. Like: Otherwise any key stroke could bring mongo or rocket.chat down. Looks like in this case mongo isn't started. But if you did make any changes to your yml file that'd possibly effect it too. |
Only the rocketchat:
image: rocketchat/rocket.chat
environment:
- MONGO_URL=mongodb://mongodb/rocketchat
- ROOT_URL=http://<our-ip-address>:8080
links:
- mongodb
ports:
- 80:80
mongodb:
image: mongo
ports:
- 27017 Could it be something with the port? I'm running it off of 8080 per the issue in #676 (comment) |
I think your port is probably fine. Seems more and issue of mongo not being properly linked. I'd make sure every thing is completely shutdown.
Then try with Be on the look out for errors with it coming up. |
When running it with |
|
okay i don't see the mongo error but now it says user not found when I try to log in |
Should be able to just register your user and be good to go. Also if you need a little more real time assistance. Feel free to hit us up on our community chat in #support |
Doing |
It work fine for me too. thankyou |
I was using the mongo-express image from docker hub and came here looking for a solution. For me I gave the name of my mongo container a custom name and needed to tell the mongo-express container what it was because it defauls to 'mongo':
So in my docker-compose.yml I had to set the environment variable to match...
Hope this saves someone some time... |
THIS! thanks! |
Its issue with firewall. Follow these instructions to fix the issue |
There could be a step I'm missing in the configuration but when I run
docker-compose up
. I get the following error. The first time I ran it, it failed. I ran it a second time and the error is thrown but the server launches. It seems none of the messages are saved to the database, tho, which would make sense given the errror.The text was updated successfully, but these errors were encountered: