create_mongodb
Exceptions
Common base class for all non-exit exceptions. |
Functions
|
|
|
|
|
|
|
|
|
|
|
|
|
Module Contents
- exception create_mongodb.MongodError[source]
Bases:
Exception
Common base class for all non-exit exceptions.
- create_mongodb.create_admin_user(host: str, password: str, port: int | None = None, username: str = 'admin')[source]
- create_mongodb.create_or_update_user(db: pymongo.database.Database, username: str, password: str, roles: list)[source]
- create_mongodb.create_read_only_user(host: str, password: str, port: int | None = None, username: str = 'reader')[source]
- create_mongodb.main(dbpath: pathlib.Path, admin_password: str, reader_password: str, host: str = 'localhost', port: int | None = None, admin_username: str | None = 'admin', reader_username: str | None = 'reader')[source]