I am beginner lift with django mongodb on heroku [ addon : mongolab ].
heroku run python manage.py syncdb
Running python manage.py syncdb
attached to terminal... up, run.2332
Creating tables ...
OperationFailure: database error: not authorized for query on database.system.namespaces consider editing privileges on the basis of data mongo
.
>use admin
>db.addUser({ user: "myadmin", pwd: "1234", roles: ["userAdminAnyDatabase"] })
but get:
Error: couldn't add user: not authorized on admin to execute command
Thanks in advance.
Heroku Postgres does not allow for user creation. You'll want to use the connection string provided in DATABASE_URL
. Actions like creating/dropping DB's and creating users is prohibited.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With