The infoblox_mx_record
resource corresponds to an MX record (mail exchanger record) in NIOS. An MX-record associates a mail exchange host to a domain name. For more information about an MX record, refer to Managing MX Records in the Infoblox NIOS Documentation.
The following table describes the parameters you can define in the resource block of the record:
Parameter | Required/ | Description | Example Value |
---|---|---|---|
| Required | Specifies the fully qualified domain name of the DNS zone to which a mail exchange host is assigned. |
|
| Required | Specifies the mail exchange host's fully qualified domain name. |
|
| Required | Specifies the preference number in the range of 0-65535, for the MX record. |
|
| Optional | Specifies the DNS view in which the zone’s record exists. |
|
| Optional | Specifies the Time to Live value for the record. There is no default value for this parameter. |
|
| Optional | Describes the record. |
|
| Optional | Specifies the set of NIOS extensible attributes that are attached to the record. |
|
Examples of the MX Record Block
// MX-record, minimal set of parameters
resource "infoblox_mx_record" "rec1" {
fqdn = "big-big-company.com"
mail_exchanger = "mx1.secure-mail-provider.net"
preference = 30
}
// MX-record, full set of parameters
resource "infoblox_mx_record" "rec2" {
dns_view = "nondefault_dnsview1"
fqdn = "
example2.org "
mail_exchanger = "sample.test.com"
preference = 40
comment = "example MX-record"
ttl = 120
ext_attrs = jsonencode({
"Location" = "Las Vegas"
})
}