avi_gslb – Module for setup of Gslb Avi RESTful Object¶
New in version 2.4.
Synopsis¶
This module is used to configure Gslb object
more examples at https://github.com/avinetworks/devops
Parameters¶
Notes¶
Note
For more information on using Ansible to manage Avi Network devices see https://www.ansible.com/ansible-avi-networks.
Examples¶
- name: Example to create Gslb object
avi_gslb:
name: "test-gslb"
avi_credentials:
username: '{{ username }}'
password: '{{ password }}'
controller: '{{ controller }}'
sites:
- name: "test-site1"
username: "gslb_username"
password: "gslb_password"
ip_addresses:
- type: "V4"
addr: "10.10.28.83"
enabled: True
member_type: "GSLB_ACTIVE_MEMBER"
port: 443
cluster_uuid: "cluster-d4ee5fcc-3e0a-4d4f-9ae6-4182bc605829"
- name: "test-site2"
username: "gslb_username"
password: "gslb_password"
ip_addresses:
- type: "V4"
addr: "10.10.28.86"
enabled: True
member_type: "GSLB_ACTIVE_MEMBER"
port: 443
cluster_uuid: "cluster-0c37ae8d-ab62-410c-ad3e-06fa831950b1"
dns_configs:
- domain_name: "test1.com"
- domain_name: "test2.com"
leader_cluster_uuid: "cluster-d4ee5fcc-3e0a-4d4f-9ae6-4182bc605829"
- name: Update Gslb site's configurations (Patch Add Operation)
avi_gslb:
avi_credentials:
username: '{{ username }}'
password: '{{ password }}'
controller: '{{ controller }}'
avi_api_update_method: patch
avi_api_patch_op: add
leader_cluster_uuid: "cluster-d4ee5fcc-3e0a-4d4f-9ae6-4182bc605829"
name: "test-gslb"
dns_configs:
- domain_name: "temp1.com"
- domain_name: "temp2.com"
gslb_sites_config:
- ip_addr: "10.10.28.83"
dns_vses:
- dns_vs_uuid: "virtualservice-f2a711cd-5e78-473f-8f47-d12de660fd62"
domain_names:
- "test1.com"
- "test2.com"
- ip_addr: "10.10.28.86"
dns_vses:
- dns_vs_uuid: "virtualservice-c1a63a16-f2a1-4f41-aab4-1e90f92a5e49"
domain_names:
- "temp1.com"
- "temp2.com"
- name: Update Gslb site's configurations (Patch Replace Operation)
avi_gslb:
avi_credentials:
username: "{{ username }}"
password: "{{ password }}"
controller: "{{ controller }}"
# On basis of cluster leader uuid dns_configs is set for that particular leader cluster
leader_cluster_uuid: "cluster-84aa795f-8f09-42bb-97a4-5103f4a53da9"
name: "test-gslb"
avi_api_update_method: patch
avi_api_patch_op: replace
dns_configs:
- domain_name: "test3.com"
- domain_name: "temp3.com"
gslb_sites_config:
# Ip address is mapping key for dns_vses field update. For the given IP address,
# dns_vses is updated.
- ip_addr: "10.10.28.83"
dns_vses:
- dns_vs_uuid: "virtualservice-7c947ed4-77f3-4a52-909c-4f12afaf5bb0"
domain_names:
- "test3.com"
- ip_addr: "10.10.28.86"
dns_vses:
- dns_vs_uuid: "virtualservice-799b2c6d-7f2d-4c3f-94c6-6e813b20b674"
domain_names:
- "temp3.com"
- name: Update Gslb site's configurations (Patch Delete Operation)
avi_gslb:
avi_credentials:
username: "{{ username }}"
password: "{{ password }}"
controller: "{{ controller }}"
# On basis of cluster leader uuid dns_configs is set for that particular leader cluster
leader_cluster_uuid: "cluster-84aa795f-8f09-42bb-97a4-5103f4a53da9"
name: "test-gslb"
avi_api_update_method: patch
avi_api_patch_op: delete
dns_configs:
gslb_sites_config:
- ip_addr: "10.10.28.83"
- ip_addr: "10.10.28.86"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
obj
dictionary
|
success, changed |
Gslb (api/gslb) object
|
Status¶
This module is not guaranteed to have a backwards compatible interface. [preview]
This module is maintained by the Ansible Community. [community]
Authors¶
Gaurav Rastogi (@grastogi23) <grastogi@avinetworks.com>
Hint
If you notice any issues in this documentation, you can edit this document to improve it.