[PR #9309/b57fef20 backport][stable-9] [vw]*: adjust docs (#9325)

[vw]*: adjust docs (#9309)

[vm]*: adjust docs

(cherry picked from commit b57fef201e)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
patchback[bot] 2024-12-23 12:22:42 +01:00 committed by GitHub
parent 3dd1c9d64a
commit 19b6f9ef3f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 353 additions and 507 deletions

View file

@ -8,15 +8,13 @@ from __future__ import absolute_import, division, print_function
__metaclass__ = type
DOCUMENTATION = r'''
---
DOCUMENTATION = r"""
module: vertica_user
short_description: Adds or removes Vertica database users and assigns roles
description:
- Adds or removes Vertica database user and, optionally, assigns roles.
- A user will not be removed until all the dependencies have been dropped.
- In such a situation, if the module tries to remove the user it
will fail and only remove roles granted to the user.
- In such a situation, if the module tries to remove the user it will fail and only remove roles granted to the user.
extends_documentation_fragment:
- community.general.attributes
attributes:
@ -42,9 +40,8 @@ options:
password:
description:
- The user's password encrypted by the MD5 algorithm.
- The password must be generated with the format C("md5" + md5[password + username]),
resulting in a total of 35 characters. An easy way to do this is by querying
the Vertica database with select V('md5'||md5('<user_password><user_name>'\)).
- The password must be generated with the format C("md5" + md5[password + username]), resulting in a total of 35 characters. An easy way
to do this is by querying the Vertica database with select V('md5'||md5('<user_password><user_name>'\)).
type: str
expired:
description:
@ -90,29 +87,22 @@ options:
- The password used to authenticate with.
type: str
notes:
- The default authentication assumes that you are either logging in as or sudo'ing
to the C(dbadmin) account on the host.
- This module uses C(pyodbc), a Python ODBC database adapter. You must ensure
that C(unixODBC) and C(pyodbc) is installed on the host and properly configured.
- Configuring C(unixODBC) for Vertica requires C(Driver = /opt/vertica/lib64/libverticaodbc.so)
to be added to the C(Vertica) section of either C(/etc/odbcinst.ini) or C($HOME/.odbcinst.ini)
and both C(ErrorMessagesPath = /opt/vertica/lib64) and C(DriverManagerEncoding = UTF-16)
to be added to the C(Driver) section of either C(/etc/vertica.ini) or C($HOME/.vertica.ini).
requirements: [ 'unixODBC', 'pyodbc' ]
- The default authentication assumes that you are either logging in as or sudo'ing to the C(dbadmin) account on the host.
- This module uses C(pyodbc), a Python ODBC database adapter. You must ensure that C(unixODBC) and C(pyodbc) is installed on the host and properly
configured.
- Configuring C(unixODBC) for Vertica requires C(Driver = /opt/vertica/lib64/libverticaodbc.so) to be added to the C(Vertica) section of either
C(/etc/odbcinst.ini) or C($HOME/.odbcinst.ini) and both C(ErrorMessagesPath = /opt/vertica/lib64) and C(DriverManagerEncoding = UTF-16) to
be added to the C(Driver) section of either C(/etc/vertica.ini) or C($HOME/.vertica.ini).
requirements: ['unixODBC', 'pyodbc']
author: "Dariusz Owczarek (@dareko)"
'''
"""
EXAMPLES = """
EXAMPLES = r"""
- name: Creating a new vertica user with password
community.general.vertica_user: name=user_name password=md5<encrypted_password> db=db_name state=present
- name: Creating a new vertica user authenticated via ldap with roles assigned
community.general.vertica_user:
name=user_name
ldap=true
db=db_name
roles=schema_name_ro
state=present
community.general.vertica_user: name=user_name ldap=true db=db_name roles=schema_name_ro state=present
"""
import traceback