opentelekomcloud / opentelekomcloud.cloud / 0.14.2 / module / css_cluster Manage CSS clusters | "added in version" 0.9.0 of opentelekomcloud.cloud" Authors: Vladimir Vshivkov (@enrrou)opentelekomcloud.cloud.css_cluster (0.14.2) — module
Install with ansible-galaxy collection install opentelekomcloud.cloud:==0.14.2
collections: - name: opentelekomcloud.cloud version: 0.14.2
Manage CSS clusters
#Create CSS Cluster --- - hosts: localhost tasks: - name: Create CSS cluster opentelekomcloud.cloud.css_cluster: name: ES-Test state: present instance_num: 3 volume_size: 40 authority_enable: false volume_type: common router: '{{ router_id }}' net: '{{ net_id }}' security_group: '{{ security_group_id }}' flavor: 'css.xlarge.2' https_enable: false system_encrypted: 0 tags: - 'key': "key0" 'value': "value0" - 'key': "key1" 'value': "value1" backup_strategy: period: "00:00 GMT+03:00" prefix: "yetanother" keepday: 1 agency: "css-agency" bucket: "css-bucket" basepath: "css-test"
#Delete CSS Cluster - hosts: localhost tasks: - name: Create CSS cluster opentelekomcloud.cloud.css_cluster: name: ES-Test state: absent
net: description: - Subnet ID. All instances in a cluster must have the same subnets and security groups. type: str auth: description: - Dictionary containing auth information as needed by the cloud's auth plugin strategy. For the default I(password) plugin, this would contain I(auth_url), I(username), I(password), I(project_name) and any information about domains (for example, I(os_user_domain_name) or I(os_project_domain_name)) if the cloud supports them. For other plugins, this param will need to contain whatever parameters that auth plugin requires. This parameter is not needed if a named cloud is provided or OpenStack OS_* environment variables are present. type: dict name: description: - Cluster name. - It contains 4 to 32 characters. Only letters, digits, hyphens (-), and underscores (_) are allowed. - The value must start with a letter. required: true type: str tags: description: - Tags in a cluster. elements: dict suboptions: key: description: - Tag key. The value can contain 1 to 36 characters. Only digits, letters, hyphens (-) and underscores (_) are allowed. value: description: - Tag value. The value can contain 0 to 43 characters. Only digits, letters, hyphens (-) and underscores (_) are allowed. type: list wait: default: true description: - Should ansible wait until the requested resource is complete. type: bool cloud: description: - Named cloud or cloud config to operate against. If I(cloud) is a string, it references a named cloud config as defined in an OpenStack clouds.yaml file. Provides default values for I(auth) and I(auth_type). This parameter is not needed if I(auth) is provided or if OpenStack OS_* environment variables are present. If I(cloud) is a dict, it contains a complete cloud configuration like would be in a section of clouds.yaml. type: raw state: choices: - present - absent default: present description: Instance state type: str flavor: description: Instance flavor name. type: str router: description: VPC ID, which is used for configuring cluster network. type: str ca_cert: aliases: - cacert description: - A path to a CA Cert bundle that can be used as part of verifying SSL API requests. type: str timeout: default: 180 description: - How long should ansible wait for the requested resource. type: int admin_pwd: description: - Password of the cluster user admin in security mode. - This parameter is mandatory only when authority_enable is set to true. - The password can contain 8 to 32 characters. - Passwords must contain at least 3 of the following character types uppercase letters, lowercase letters, numbers, and special characters (~!@#$%^&*()-_=+\|[{}];:,<.>/?). type: str auth_type: description: - Name of the auth plugin to use. If the cloud uses something other than password authentication, the name of the plugin should be indicated here and the contents of the I(auth) parameter should be updated accordingly. type: str interface: aliases: - endpoint_type choices: - admin - internal - public default: public description: - Endpoint URL type to fetch from the service catalog. type: str client_key: aliases: - key description: - A path to a client key to use as part of the SSL transaction. type: str api_timeout: description: - How long should the socket layer wait before timing out for API calls. If this is omitted, nothing will be passed to the requests library. type: int client_cert: aliases: - cert description: - A path to a client certificate to use as part of the SSL transaction. type: str region_name: description: - Name of the region. type: str volume_size: description: - Volume size, which must be a multiple of 4 and 10. - Unit GB type: int volume_type: choices: - common - high - ultrahigh description: - Information about the volume. - COMMON Common I/O - HIGH High I/O - ULTRAHIGH Ultra-high I/O type: str https_enable: description: - Whether communication is encrypted on the cluster. - Available values include true and false. By default, communication is encrypted. - Value true indicates that communication is encrypted on the cluster. - Value false indicates that communication is not encrypted on the cluster. type: bool instance_num: description: - Number of clusters. - The value range is 1 to 32. type: int sdk_log_path: description: - Path to the logfile of the OpenStackSDK. If empty no log is written type: str system_cmkid: description: - Key ID. - The Default Master Keys cannot be used to create grants. Specifically, you cannot use Default Master Keys whose aliases end with /default in KMS to create clusters. - After a cluster is created, do not delete the key used by the cluster. Otherwise, the cluster will become unavailable. type: str sdk_log_level: choices: - ERROR - WARN - INFO - DEBUG default: WARN description: Log level of the OpenStackSDK type: str datastore_type: default: elasticsearch description: - Engine type. - The default value is elasticsearch. Currently, the value can only be elasticsearch. type: str security_group: description: - Security group ID. All instances in a cluster must have the same subnets and security groups. type: str validate_certs: aliases: - verify description: - Whether or not SSL API requests should be verified. - Before Ansible 2.3 this defaulted to C(yes). type: bool backup_strategy: description: - Automatic snapshot creation. This function is disabled by default. suboptions: agency: description: - IAM agency used to access OBS. type: str basepath: description: - Storage path of the snapshot in the OBS bucket. type: str bucket: description: - OBS bucket used for storing backup. If there is snapshot data in an OBS bucket, only the OBS bucket will be used for backup storage and cannot be changed. type: str keepday: description: - Number of days for which automatically created snapshots are reserved. Value range is 1 to 90 type: int period: description: - Time when a snapshot is created every day. Snapshots can only be created on the hour. The time format is the time followed by the time zone, specifically, HH:mm z. In the format, HH:mm refers to the hour time and z refers to the time zone, for example, 00:00 GMT+08:00 and 01:00 GMT+08:00. type: str prefix: description: - Prefix of the name of the snapshot that is automatically created. type: str type: dict authority_enable: description: - Whether to enable authentication. - Available values include true and false. - Authentication is disabled by default. - When authentication is enabled, httpsEnable must be set to true. type: bool system_encrypted: choices: - '0' - '1' description: - Value 1 indicates encryption is performed - Value 0 indicates encryption is not performed. type: int datastore_version: choices: - 7.6.2 - 7.9.3 default: 7.6.2 description: - Engine version. The value can be 6.2.3, 7.1.1 or 7.6.2. - The default value is 7.6.2. type: str
cluster: description: Dictionary of CSS cluster returned: changed sample: - cluster: id: ef683016-871e-48bc-bf93-74a29d60d214 name: ES-Test type: list