---
title: "infoblox_ipv6_association"
canonical: "https://docs.infoblox.com/space/ipamdriverterraform/53154230/infoblox_ipv6_association"
format: markdown
---
<span style="color: #000000">With the IP address association operation, you can update the Host record created using the </span><span style="color: #000000">*[IP address allocation](https://infoblox-docs.atlassian.net/wiki/spaces/ipamdriverterraform/pages/53154100)*</span><span style="color: #000000"> operation with details of the VM created in the cloud environment. The VM details include DUID and VM tags as extensible attributes.</span>

> ⚠️ **Note**
> ⚠️ 
> ⚠️ The `Infoblox_ipv4_allocation` resource is deprecated and is not supported from Infoblox IPAM Plug-In version 2.3.0. Infoblox strongly recommends that you use *[infoblox_ip_association](https://infoblox-docs.atlassian.net/wiki/spaces/ipamdriverterraform/pages/53023339)* resource for allocation of IP addresses. For more information, see *[IP Address Association](https://infoblox-docs.atlassian.net/wiki/spaces/ipamdriverterraform/pages/53121336)*.

> Macro (excerpt-include)



Additionally, define the following parameter for `infoblox_ipv6_association`:

| <span style="color: #000000">**Parameter**</span> | <span style="color: #000000">**Required/Optional**</span> | <span style="color: #000000">**Description**</span> | <span style="color: #000000">**Example Value**</span> |
| --- | --- | --- | --- |
| `duid` | <span style="color: #000000">Required</span> | <span style="color: #000000">It specifies the DHCPv6 Unique Identifier (DUID) of the address object.</span> | `0c:c0:84:d3:03:00:09:12` |

## <span style="color: #000000">Example of the Resource Block</span>

<span style="color: #000000">As the IP address association operation is dependent on the allocation operation, the following examples for IPv6 addresses demonstrate how to define the resource blocks in the Terraform configuration file:</span>

`resource "infoblox_ipv6_allocation" "ipv6_allocation" {`  
`  network_view= "default"`  
`  cidr = infoblox_ipv6_network.ipv6_network.cidr`  
`  `  
`  #Create Host Record with DNS and DHCP flags`  
`  dns_view="default"`  
`  fqdn="testipv6.aws.com"`  
`  enable_dns = "true"`  
  
`  comment = "tf IPv6 allocation"`  
`  ext_attrs = jsonencode({`  
`    "Tenant ID" = "tf-plugin"`  
`    "Cloud API Owned" = "True"`  
`    "CMP Type"= "AWS"`  
`    "Network Name" = "ipv6-tf-network"`  
`    "VM Name" = "tf-ec2-instance-ipv6"`  
`    "Location" = "Test loc."`  
`    "Site" = "Test site"`  
`   })`  
`}`


`resource "infoblox_ipv6_association" "ipv6_associate"{`  
`  network_view = infoblox_ipv6_allocation.ipv6_allocation.network_view`  
`  ip_addr = infoblox_ipv6_allocation.ipv6_allocation.ip_addr`  
`  duid = aws_network_interface.ni.mac_address`  
  
`  #Create Host Record with DNS and DHCP flags`  
`  dns_view=infoblox_ipv6_allocation.ipv6_allocation.dns_view`  
`  fqdn=infoblox_ipv6_allocation.ipv6_allocation.fqdn`  
`  enable_dns = infoblox_ipv6_allocation.ipv6_allocation.enable_dns`  
`  enable_dhcp = infoblox_ipv6_allocation.ipv6_allocation.enable_dhcp`  
  
`  comment = ""Associating of an IPv6 address""`  
`  ext_attrs = jsonencode({`  
`    "Tenant ID" = "tf-plugin"`  
`    "Cloud API Owned" = "True"`  
`    "CMP Type"= "AWS"`  
`    "Network Name" = "ipv6-tf-network"`  
`    "VM Name" = "tf-ec2-instance-ipv6"`  
`    "VM ID" = aws_instance.ec2-instance.id`  
`    "Location" = "Test loc."`  
`    "Site" = "Test site"`  
`  })`  
`}`