hwceco.hwcollection.hwc_cce_cluster – Creates a resource of cce cluster in Huawei Cloud¶
Note
This plugin is part of the hwceco.hwcollection collection (version 1.0.5).
To install it use: ansible-galaxy collection install hwceco.hwcollection
.
To use it in a playbook, specify: hwceco.hwcollection.hwc_cce_cluster
.
New in version 1.0.0: of hwceco.hwcollection
Requirements¶
The below requirements are needed on the host that executes this module.
huaweicloudsdkcore >= 3.0.47
huaweicloudsdkcce >= 3.0.47
Parameters¶
Notes¶
Note
For authentication, you can set access_key using the `ANSIBLE_HWC_ACCESS_KEY’ env variable.
For authentication, you can set secret_key using the `ANSIBLE_HWC_SECRET_KEY’ env variable.
For authentication, you can set project_id using the `ANSIBLE_HWC_PROJECT_ID’ env variable.
For authentication, you can set region using the `ANSIBLE_HWC_REGION’ env variable.
For authentication, you can set identity_endpoint using the `ANSIBLE_HWC_IDENTITY_ENDPOINT’ env variable.
For authentication, you can set cloud using the `ANSIBLE_HWC_CLOUD’ env variable.
Environment variables values will only be used if the playbook values are not set.
Examples¶
# create an cce cluster
- name: create a vpc
hwc_vpc:
cidr: "192.168.100.0/24"
name: "ansible_vpc_test"
register: vpc
- name: create a subnet
hwc_vpc_subnet:
filters:
- "name"
gateway_ip: "192.168.100.32"
name: "ansible_subnet_test"
dhcp_enable: true
vpc_id: "{{ vpc.state.id }}"
cidr: "192.168.100.0/26"
# dns is required for cce node installing
dns_address:
- "100.125.1.250"
- "100.125.21.250"
register: subnet
- name: create a cce cluster
hwc_cce_cluster:
filters:
- "name"
name: "ansible-cce-cluster-test"
description: "ansible cce cluster test"
flavor_id: "cce.s1.small"
vpc_id: "{{ vpc.state.id }}"
subnet_id: "{{ subnet.state.id }}"
container_network_type: "overlay_l2"
authentication_mode: "rbac"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Authors¶
Huawei (@huaweicloud)