---
title: "DNS View"
canonical: "https://docs.infoblox.com/space/niosmodulesansible/45940905/DNS%20View"
format: markdown
---
<span style="color: #000000">Use the </span>`nios_dns_view`<span style="color: #000000"> module to create, update, or remove instances of DNS view objects from a NIOS Grid.</span>

<span style="color: #000000">The following table describes the parameters you can define in the </span>`nios_dns_view`<span style="color: #000000"> module:</span>

| <span style="color: #000000">**Parameter**</span> | <span style="color: #000000">**Required/Optional**</span> | <span style="color: #000000">**Description**</span> |
| --- | --- | --- |
| `name` | <span style="color: #000000">Required</span> | <span style="color: #000000">Specifies the fully qualified host name to add or remove from NIOS.</span> |
| `network_view` | <span style="color: #000000">Required</span> | <span style="color: #000000">Specifies the name of the network view to which the DNS view must be assigned.</span>  
<span style="color: #000000">If a value is not specified, the default network view configured in NIOS is used.</span> |
| `extattrs` | <span style="color: #000000">Optional</span> | <span style="color: #000000">Specifies extensible attributes for the DNS view object.</span> |
| `state` | <span style="color: #000000">Optional</span> | <span style="color: #000000">Specifies the state of the DNS view instance in NIOS. Set one of the following values:</span><br>- `present`<span style="color: #000000"> (default): Configures the object.</span>
- `absent`<span style="color: #000000">: Removes the object.</span> |
| `comment` | <span style="color: #000000">Optional</span> | <span style="color: #000000">Describes the DNS view object.</span> |
| `provider` | <span style="color: #000000">Required</span> | <span style="color: #000000">A dictionary object that contains connection details.</span><br>- `host`<span style="color: #000000">: DNS host name or IP address to connect to the remote instance of NIOS.</span>
- `username`<span style="color: #000000">: User name to use for authenticating the connection to the remote instance.</span>
- `password`<span style="color: #000000">: Password to use for authenticating the connection to the remote instance.</span><br><span style="color: #000000">For information on additional fields you can define, see the list of subparameters in the </span><span style="color: #000000">*[NIOS Modules for Ansible Collections](https://infoblox-docs.atlassian.net/wiki/spaces/niosmodulesansible/pages/44525470/NIOS+Modules+for+Ansible+Collections#Provider parameters)*</span><span style="color: #000000"> topi</span><span style="color: #003366">c.</span> |
| `connection` | <span style="color: #000000">Required</span> | <span style="color: #000000">The </span>`nios_dns_view`<span style="color: #000000"> module must be run locally.</span> |

  


## <span style="color: #000000">Examples</span>

`name: configure a new dns view instance`  
`infoblox.nios_modules.nios_dns_view:`  
`  name: ansible-dns`  
`  state: present`  
`  provider:`  
`    host: <nios_hostname_or_hostip>`  
`    username: <nios_username>`  
`    password: <nios_password>`  
`connection: local`

  


`name: update the dns view instance`  
`infoblox.nios_modules.nios_dns_view:`  
`  name: {new_name: ansible-dns-new, old_name: ansible-dns}`  
`  state: present`  
`  provider:`  
`    host: <nios_hostname_or_hostip>`  
`    username: <nios_username>`  
`    password: <nios_password>`  
`connection: local`