arubanetworks / arubanetworks.aos_switch / 1.7.0 / module / arubaoss_dns implements rest api for DNS configuration | "added in version" 2.4.0 of arubanetworks.aos_switch" Authors: Sanju Sadanandan (@hpe) preview | supported by communityarubanetworks.aos_switch.arubaoss_dns (1.7.0) — module
Install with ansible-galaxy collection install arubanetworks.aos_switch:==1.7.0
collections: - name: arubanetworks.aos_switch version: 1.7.0
This implements rest apis which can be used to configure DNS
- name: Configure Maximum DNS Domains and DNS Server arubaoss_dns: dns_domain_names: "mydomain.com" dns_domain_names_2: "myotherdomain.com" dns_domain_names_3: myotherotherdomain.com dns_domain_names_4: yourdomain.com dns_domain_names_5: otherdomain.com server_1: "10.2.3.4" server_2: "10.2.3.5" server_3: "10.2.3.6" server_4: "10.2.3.7"
- name: Configure Remove all DNS Domains and DNS Server 3 and 4 arubaoss_dns: server_1: "10.2.3.4" server_2: "10.2.3.5" server_3: "" server_4: ""
- name: Configure DNS to be DHCP arubaoss_dns: dns_config_mode: "DCM_DHCP"
- name: Disable DNS arubaoss_dns: dns_config_mode: "DCM_DISABLED"
- name: Configure DNS Server with priority 4 arubaoss_dns: dns_config_mode: "DCM_MANUAL" server_4: "10.2.3.4"
- name: Configure DNS Server with priority 4 and priority 1 arubaoss_dns: dns_config_mode: "DCM_MANUAL" server_1: "10.2.3.1" server_4: "10.2.3.4"
host: description: 'Specifies the DNS host name or address for connecting to the remote device over the specified transport. The value of host is used as the destination address for the transport. ' type: str port: description: 'Specifies the port to use when building the connection to the remote device. ' type: int timeout: description: 'Specifies the timeout in seconds for communicating with the network device for either connecting or sending commands. If the timeout is exceeded before the operation is completed, the module will error. ' type: int use_ssl: description: 'Configures use SSL (HTTPS) for access to the remote device. ' type: bool password: description: 'Specifies the password to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_PASSWORD will be used instead. ' type: str provider: description: A dict object containing connection details. suboptions: api_version: default: None description: 'Configures (force) API version (vX.Y) for acces to the remote device. ' type: str host: description: 'Specifies the DNS host name or address for connecting to the remote device over the specified transport. The value of host is used as the destination address for the transport. ' type: str password: description: 'Specifies the password to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_PASSWORD will be used instead. ' type: str port: description: 'Specifies the port to use when building the connection to the remote device. ' type: int ssh_keyfile: description: 'Specifies the SSH key to use to authenticate the connection to the remote device. This value is the path to the key used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_SSH_KEYFILE will be used instead. ' type: path timeout: description: 'Specifies the timeout in seconds for communicating with the network device for either connecting or sending commands. If the timeout is exceeded before the operation is completed, the module will error. ' type: int transport: default: aossapi description: 'Configures the transport (aossapi or network_cli) mode. ' type: str use_proxy: default: false description: 'Configures use (Local) Proxy for access to the remote device. ' type: bool use_ssl: description: 'Configures use SSL (HTTPS) for access to the remote device. ' type: bool username: description: 'Configures the username to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_USERNAME will be used instead. ' type: str validate_certs: default: false description: 'Configures validation of certification for access to the remote device. ' type: bool type: dict server_1: description: The first manually configured DNS Server IP address with priority 1, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str server_2: description: The second manually configured DNS Server IP address with priority 2, all DNS configurations need to be made in a single module call required: false type: str server_3: description: The third manually configured DNS Server IP address with priority 3, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str server_4: description: The fourth manually configured DNS Server IP address with priority 4, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str username: description: 'Configures the username to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_USERNAME will be used instead. ' type: str version_1: choices: - IAV_IP_V4 description: The ip version of first manually configured DNS Server. (V6 is not supported via REST) required: false type: str version_2: choices: - IAV_IP_V4 description: The ip version of second manually configured DNS Server. (V6 is not supported via REST) required: false type: str version_3: choices: - IAV_IP_V4 description: The ip version of third manually configured DNS Server. (V6 is not supported via REST) required: false type: str version_4: choices: - IAV_IP_V4 description: The ip version of fourth manually configured DNS Server. (V6 is not supported via REST) required: false type: str api_version: default: None description: 'Configures (force) API version (vX.Y) for acces to the remote device. ' type: str ssh_keyfile: description: 'Specifies the SSH key to use to authenticate the connection to the remote device. This value is the path to the key used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_SSH_KEYFILE will be used instead. ' type: path validate_certs: default: false description: 'Configures validation of certification for access to the remote device. ' type: bool dns_config_mode: choices: - DCM_DHCP - DCM_MANUAL - DCM_DISABLED description: DNS Configuration Mode, default is DCM_DHCP required: false dns_domain_names: description: The first manually configured DNS server domain name, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str dns_domain_names_2: description: The second manually configured DNS server domain name, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str dns_domain_names_3: description: The third manually configured DNS server domain name, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str dns_domain_names_4: description: The fourth manually configured DNS server domain name, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str dns_domain_names_5: description: The fifth manually configured DNS server domain name, all DNS configurations need to be made in a single module call, to remove configuration pass in empty string "" required: false type: str