django-mongokit icon indicating copy to clipboard operation
django-mongokit copied to clipboard

Auth to remote mongod

Open caruccio opened this issue 11 years ago • 3 comments

I'm not sure, but it looks like we need to authenticate before accessing a database on a remote mongod. Maybe that is something new from pymongo/mongokit ? Warning: code wasn't tested to exhaustion.

caruccio avatar Apr 19 '13 16:04 caruccio

Have you tried this locally? Have you tried running the tests for it?

peterbe avatar Apr 19 '13 22:04 peterbe

Yes, I have tried it. In fact it is running smooth right now on my production server. I ran coverage test and got:

...../home/mateus/.virtualenvs/getup-admin/local/lib/python2.7/site-packages/pymongo/common.py:529: DeprecationWarning: The safe parameter is deprecated. Please use write concern options instead.
  "write concern options instead.", DeprecationWarning)

..........Destroying test database 'mongodb'...
..Destroying test database 'mongodb'...
.....
----------------------------------------------------------------------
Ran 22 tests in 0.765s

OK
Name               Stmts   Miss  Cover
--------------------------------------
__init__               3      3     0%
document              61      2    97%
mongodb/__init__       0      0   100%
mongodb/base          98     98     0%
shortcut              30     12    60%
--------------------------------------
TOTAL                192    115    40%
htmlcov/index.html

caruccio avatar Apr 19 '13 23:04 caruccio

That may fix. Coverage ran OK (django 1.5 only). Travis is failing with 'connection refused' to mongodb.

caruccio avatar Apr 19 '13 23:04 caruccio