Class: Ansible::Ruby::Modules::Mongodb_user

Inherits:
Base show all
Defined in:
lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb

Overview

Adds or removes a user from a MongoDB database.

Instance Method Summary collapse

Methods inherited from Base

#ansible_name, #to_h

Methods inherited from Ansible::Ruby::Models::Base

attr_option, attr_options, attribute, #initialize, remove_existing_validations, #to_h, validates

Constructor Details

This class inherits a constructor from Ansible::Ruby::Models::Base

Instance Method Details

#databaseString

Returns The name of the database to add/remove the user from.

Returns:

  • (String)

    The name of the database to add/remove the user from



34
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 34

attribute :database

#login_databaseObject?

Returns The database where login credentials are stored.

Returns:

  • (Object, nil)

    The database where login credentials are stored



27
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 27

attribute :login_database

#login_hostString?

Returns The host running the database.

Returns:

  • (String, nil)

    The host running the database



19
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 19

attribute :login_host

#login_passwordString?

Returns The password used to authenticate with.

Returns:

  • (String, nil)

    The password used to authenticate with



15
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 15

attribute :login_password

#login_portInteger?

Returns The port to connect to.

Returns:

  • (Integer, nil)

    The port to connect to



23
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 23

attribute :login_port

#login_userString?

Returns The username used to authenticate with.

Returns:

  • (String, nil)

    The username used to authenticate with



11
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 11

attribute :login_user

#nameString

Returns The name of the user to add or remove.

Returns:

  • (String)

    The name of the user to add or remove



38
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 38

attribute :name

#passwordString?

Returns The password to use for the user.

Returns:

  • (String, nil)

    The password to use for the user



42
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 42

attribute :password

#replica_setString?

Returns Replica set to connect to (automatically connects to primary for writes).

Returns:

  • (String, nil)

    Replica set to connect to (automatically connects to primary for writes)



30
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 30

attribute :replica_set

#rolesString?

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’,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.

Returns:

  • (String, nil)

    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’,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.



50
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 50

attribute :roles

#sslBoolean?

Returns Whether to use an SSL connection when connecting to the database.

Returns:

  • (Boolean, nil)

    Whether to use an SSL connection when connecting to the database



46
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 46

attribute :ssl

#state:present, ...

Returns The database user state.

Returns:

  • (:present, :absent, nil)

    The database user state



54
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 54

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.

Returns:

  • (:always, :on_create, nil)

    C(always) will update passwords if they differ. C(on_create) will only set the password for newly created users.



58
# File 'lib/ansible/ruby/modules/generated/extras/database/misc/mongodb_user.rb', line 58

attribute :update_password