Closed uzziwizzle closed 5 years ago
Dude I am so sorry for not getting back to you when you submitted this issue! I just happened to check back on this project today and only just noticed. Did you get the issue solved? That error indicates that flask can't connect to mongodb; it needs to be running, and accessible to the app server, and configured in config.py
Out of interest, what were you working on? What did you end up doing?
Looks like misconfiguration, closing
Hi,
running device_gateway.py, i get the error:
Traceback (most recent call last): File "device_gateway.py", line 6, in
from models import GPSDevice
File "/var/www/FlaskApp/FlaskApp/gps-tracker-server/models.py", line 11, in
mongoengine.connect(config.MONGO_DBNAME, host=config.MONGO_HOST, port=config.MONGO_PORT)
File "/usr/local/lib/python2.7/dist-packages/mongoengine/connection.py", line 161, in connect
return get_connection(alias)
File "/usr/local/lib/python2.7/dist-packages/mongoengine/connection.py", line 124, in get_connection
raise ConnectionError("Cannot connect to database %s :\n%s" % (alias, e))
mongoengine.connection.ConnectionError: Cannot connect to database default :
[Errno 111] Connection refused
I believe it is related to the error below, seen when installing requirement.txt:
Updating ./src/flask-mongoengine-master clone (to 0c2cc30ec98154bb2eb4499efada65239050025d) Could not find a tag or branch '0c2cc30ec98154bb2eb4499efada65239050025d', assuming commit.