Class: Ansible::Ruby::Modules::Mongodb_user
- Inherits:
-
Base
- Object
- Ansible::Ruby::Models::Base
- Base
- Ansible::Ruby::Modules::Mongodb_user
- Defined in:
- lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb
Overview
Adds or removes a user from a MongoDB database.
Instance Method Summary collapse
-
#database ⇒ String
The name of the database to add/remove the user from.
-
#login_database ⇒ Object?
The database where login credentials are stored.
-
#login_host ⇒ String?
The host running the database.
-
#login_password ⇒ String?
The password used to authenticate with.
-
#login_port ⇒ Integer?
The port to connect to.
-
#login_user ⇒ String?
The username used to authenticate with.
-
#name ⇒ String
The name of the user to add or remove.
-
#password ⇒ Integer, ...
The password to use for the user.
-
#replica_set ⇒ String?
Replica set to connect to (automatically connects to primary for writes).
-
#roles ⇒ String?
The database user roles valid values could either be one or more of the following strings: ‘read’, ‘readWrite’, ‘dbAdmin’, ‘userAdmin’, ‘clusterAdmin’, ‘readAnyDatabase’, ‘readWriteAnyDatabase’, ‘userAdminAnyDatabase’, ‘dbAdminAnyDatabase’rn,Or the following dictionary ‘{ db: DATABASE_NAME, role: ROLE_NAME }’.,This param requires pymongo 2.5+.
-
#ssl ⇒ Boolean?
Whether to use an SSL connection when connecting to the database.
-
#ssl_cert_reqs ⇒ :CERT_REQUIRED, ...
Specifies whether a certificate is required from the other side of the connection, and whether it will be validated if provided.
-
#state ⇒ :present, ...
The database user state.
-
#update_password ⇒ :always, ...
C(always) will update passwords if they differ.
Methods inherited from Base
Methods inherited from Ansible::Ruby::Models::Base
attr_option, attr_options, attribute, fix_inclusion, #initialize, remove_existing_validations, #to_h, validates
Constructor Details
This class inherits a constructor from Ansible::Ruby::Models::Base
Instance Method Details
#database ⇒ String
Returns The name of the database to add/remove the user from.
35 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 35 attribute :database |
#login_database ⇒ Object?
Returns The database where login credentials are stored.
28 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 28 attribute :login_database |
#login_host ⇒ String?
Returns The host running the database.
20 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 20 attribute :login_host |
#login_password ⇒ String?
Returns The password used to authenticate with.
16 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 16 attribute :login_password |
#login_port ⇒ Integer?
Returns The port to connect to.
24 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 24 attribute :login_port |
#login_user ⇒ String?
Returns The username used to authenticate with.
12 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 12 attribute :login_user |
#name ⇒ String
Returns The name of the user to add or remove.
39 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 39 attribute :name |
#password ⇒ Integer, ...
Returns The password to use for the user.
43 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 43 attribute :password |
#replica_set ⇒ String?
Returns Replica set to connect to (automatically connects to primary for writes).
31 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 31 attribute :replica_set |
#roles ⇒ String?
Returns The database user roles valid values could either be one or more of the following strings: ‘read’, ‘readWrite’, ‘dbAdmin’, ‘userAdmin’, ‘clusterAdmin’, ‘readAnyDatabase’, ‘readWriteAnyDatabase’, ‘userAdminAnyDatabase’, ‘dbAdminAnyDatabase’rn,Or the following dictionary ‘{ db: DATABASE_NAME, role: ROLE_NAME }’.,This param requires pymongo 2.5+. If it is a string, mongodb 2.4+ is also required. If it is a dictionary, mongo 2.6+ is required.
55 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 55 attribute :roles |
#ssl ⇒ Boolean?
Returns Whether to use an SSL connection when connecting to the database.
47 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 47 attribute :ssl |
#ssl_cert_reqs ⇒ :CERT_REQUIRED, ...
Returns Specifies whether a certificate is required from the other side of the connection, and whether it will be validated if provided.
51 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 51 attribute :ssl_cert_reqs |
#state ⇒ :present, ...
Returns The database user state.
59 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 59 attribute :state |
#update_password ⇒ :always, ...
Returns C(always) will update passwords if they differ. C(on_create) will only set the password for newly created users.
63 |
# File 'lib/ansible/ruby/modules/generated/database/mongodb/mongodb_user.rb', line 63 attribute :update_password |