Files
mongodb-memory-server/docs/api/interfaces/mongo-memory-server-automaticauth.md
hasezoey 582c5ce7d7 feat: change authentication to only happen when "enable" is "true"
BREAKING CHANGE:
Authentication now is only created when "{ enable: true }" is given
also "disable" has been removed
2023-06-09 18:25:35 +02:00

1.3 KiB

id, title
id title
mongo-memory-server-automaticauth AutomaticAuth

API Documentation of AutomaticAuth-Interface

Values

enable

Typings: enable?: boolean
Default: false

Enable or disable Authentication creation.

extraUsers

Typings: extraUsers?: CreateUser[]
Default: []

Add extra users after the root user has been created, uses CreateUser.

customRootName

Typings: customRootName?: string
Default: mongodb-memory-server-root

Set a Custom Root User Name.

customRootPwd

Typings: customRootPwd?: string
Default: rootuser

Set a Custom Root User Password.

force

Typings: force?: boolean
Default: false

Force to run createAuth, by default createAuth is only run when the instance is new.

keyfileContent

Typings: keyfileContent?: string
Default: 0123456789

Set custom content for the keyfile.
This field only has a effect in a MongoMemoryReplSet.

A Keyfile is required in ReplSet's since ~5.0 for other replset instances to connect to eachother without having to use a password, and keyfiles only work for authenticating other instances, not clients, for more see MongoDB Keyfile Documentation.