Introducing a new admin interface for MongoDB, written in Python using Django and Bootstrap.
Get the code from GitHub (https://github.com/thomasst/mongoadmin/):
git clone https://github.com/thomasst/mongoadmin.git
Alternatively, download mongoadmin_project-0.1.tar.bz2 (v0.1, revision 472d30a).
Make sure you have the following packages installed:
Make a copy the included default project settings:
cp mongoadmin_project/settings.py.dist mongoadmin_project/settings.py
Create a database for Django (by default, it is a MySQL database called
mongoadmin, but you can change it in
DATABASES in the settings). This database is required to store sessions or to save database connection details.
SECRET_KEY (can be any random string) in the settings.py file that you created.
Create SQL database tables:
python manage.py syncdb
Run the server:
python manage.py runserver
Go to http://127.0.0.1:8000/ and connect to your Mongo database.
Interested in developing MongoAdmin? Here are just a few ideas for improvements:
Looking forward to hearing your feedback and seeing your pull requests!
@Brett: Thanks, I fixed this in master.
This is really great! Will save me a lot of time at the mongo console...
One note: I had pymongo 2.2 (the latest) installed and couldn't get this to run out of the box because pymongo.objectid and pymongo.json_util have been moved to bson.objectid and bson.json_util respectively. Making that change in views.py and forms.py got me up and running.
Great! I added this to the README so people hopefully don't run into this problem again.
Ok thank you, it works :-)
I forgot to run "python manage.py syncdb"...
@Arthur and @Tobias, make sure you have DEBUG enabled so you can see a detailed error message. I will change it to be True by default.
@Tobias, there is no need to use virtualenv. Note that easy_install shouldn't be used anymore. Instead, you could use pip to install your packages. Another option is to manually download the modules and symlink them in a lib directory and add that directory to your PYTHONPATH. I'm sorry that my installation instructions aren't specific enough if you've never used Python.
I'll also consider adding a 500 template to the project so the server error page looks nicer.
I've got the same problem as Tobias:
- 500.html template seems to be missing,
- "A server error occurred. Please contact the administrator."
I am on OS X 10.6.8.
Any suggestion ?
Finally, after I reinstalled all modules via virtualenv the server starts. You should maybe consider to describe virtualenv in your instructions. However, a 500.html template seems to be missing. Here is the output when I load the login page: http://pastebin.com/PdqcBemD
Though, the database connection fails with a simple "A server error occurred. Please contact the administrator." message. No hints in the console.
I configured the database and mongoadmin as described. Though, when I start the application an error message occurs. There is the same error with Python 2.6.6 and 2.7.0+ but another with 3.2. I am running Ubuntu 10.10. What do I have to do?
$ /usr/bin/python2.7 manage.py runserver
Error: No module named staticfiles
I also tried with Python 3.2
$ /usr/bin/python3.2 manage.py runserver
Traceback (most recent call last):
File "manage.py", line 7, in <module>
from django.core.management import execute_from_command_line
ImportError: No module named django.core.management
I would like to encourage you to add some more details to the requirements part of your installation. You should add some more information on how to install "django" and "mongo-python-driver". First question someone could come up with is which version of python is needed? Second question: How do I install the required software. Under Ubuntu you need to do ..
sudo apt-get install python python-dev python-django
sudo easy_install pymongo
I think, some more details will make it much easier to try out your project without having worked with python and django before.
I'm working on a UI for Cassandra. Same thing, python, Django... I call it Djandra.
If any of you guys have good xhtml, and a little bit of JS, perhaps you can help me to roll this out rapidly...... jparicka(at)gmail.com is the email to reach me on. Creative common license.
Anyways, I absolutely love MongoAdmin!
Kudos for putting the efforts in! :)
Great work! I'm sure this will come in handy.
I think you need to configure the static file URLs for when running locally without a web server.
Keep in mind that this is an interface between django and mongodb, not a means of using django's ORM with mongo.
For that, see the django-nonrel project at https://github.com/django-nonrel/django-nonrel, which allows you to build a 100% mongodb-powered django project using almost all of django core and many third-party django apps.
That's not to take away from this project - mongoadmin and django-nonrel are different solutions to different problems.
Well admin was one thing that holds me back in trying mangodb with django
You do know mongo is a database right? Why would your app need another db to run?
You managed to create ugly interface using twitter bootstrap? Congratulations.
what a co-incidence !! I'm also writing an interface for mongoDB with same name in php using same bootstrap. Anyways, Nice work
Nice work! Have wanted something like this for a while. I assume this can run on Heroku since they support Django now. https://devcenter.heroku.com/articles/django Would be cool to see a quick start guide there with authentication. Awesome job tho, this is great!
Great, definitely have this bookmarked.