community / community.general / 3.8.10 / module / vertica_schema Adds or removes Vertica database schema and roles. Authors: Dariusz Owczarek (@dareko)community.general.vertica_schema (3.8.10) — module
Install with ansible-galaxy collection install community.general:==3.8.10
collections: - name: community.general version: 3.8.10
Adds or removes Vertica database schema and, optionally, roles with schema access privileges.
A schema will not be removed until all the objects have been dropped.
In such a situation, if the module tries to remove the schema it will fail and only remove roles created for the schema if they have no dependencies.
- name: Creating a new vertica schema community.general.vertica_schema: name=schema_name db=db_name state=present
- name: Creating a new schema with specific schema owner community.general.vertica_schema: name=schema_name owner=dbowner db=db_name state=present
- name: Creating a new schema with roles community.general.vertica_schema: name=schema_name create_roles=schema_name_all usage_roles=schema_name_ro,schema_name_rw db=db_name state=present
db: description: - Name of the Vertica database. type: str port: default: '5433' description: - Vertica cluster port to connect to. type: str owner: description: - Name of the user to set as owner of the schema. type: str state: choices: - present - absent default: present description: - Whether to create C(present), or drop C(absent) a schema. type: str schema: aliases: - name description: - Name of the schema to add or remove. required: true type: str cluster: default: localhost description: - Name of the Vertica cluster. type: str login_user: default: dbadmin description: - The username used to authenticate with. type: str usage_roles: aliases: - usage_role description: - Comma separated list of roles to create and grant usage access to the schema. type: str create_roles: aliases: - create_role description: - Comma separated list of roles to create and grant usage and create access to the schema. type: str login_password: description: - The password used to authenticate with. type: str