arvancloud_cdn_domain_dns_record (Resource)
Domain's DNS Record.
Example Usage
resource "arvancloud_cdn_domain_dns_record " "a-example" {
domain = "cdn-terraform.ir"
name = "a-terraform"
ttl = 120
cloud = true
upstream_https = "https"
ip_filter_mode = {
count = "single"
order = "none"
geo_filter = "none"
}
type = "a"
value = {
a = [
{
ip = "1.1.1.1"
port = 1001
},
{
ip = "1.1.1.2"
weight = 101
}
]
}
}
resource "arvancloud_cdn_domain_dns_record " "aaaa-example" {
domain = "cdn-terraform.ir"
name = "aaaa-terraform"
ttl = 120
cloud = true
upstream_https = "https"
ip_filter_mode = {
count = "single"
order = "none"
geo_filter = "none"
}
type = "aaaa"
value = {
aaaa = [
{
ip = "2345:0425:2CA1:0000:0000:0567:5673:23B6"
port = 1001
},
{
ip = "2345:0425:2CA1:0000:0000:0567:5673:23b5"
weight = 101
}
]
}
}
resource "arvancloud_cdn_domain_dns_record " "cname-example" {
domain = "cdn-terraform.ir"
name = "cname-terraform"
ttl = 120
cloud = true
upstream_https = "https"
ip_filter_mode = {
count = "single"
order = "none"
geo_filter = "none"
}
type = "cname"
value = {
cname = {
host = "some-host.ir."
host_header = "source"
port = 443
upstream_https = "https"
ip_filter_mode = {
count = "single"
order = "none"
geo_filter = "none"
}
type = "txt"
value = {
txt = {
text = "some text"
}
}
}
}
}
resource "arvancloud_cdn_domain_dns_record " "aname-example" {
domain = "cdn-terraform.ir"
name = "aname-terraform"
ttl = 120
cloud = true
upstream_https = "https"
ip_filter_mode = {
count = "single"
order = "none"
geo_filter = "none"
}
type = "aname"
value = {
aname = {
location = "some-host.ir."
host_header = "source"
port = 443
}
}
}
resource "arvancloud_cdn_domain_dns_record " "txt-example" {
domain = "cdn-terraform.ir"
name = "txt-terraform"
ttl = 120
cloud = true
}
Schema
Required
cloud
(Boolean) Whether this record is managed by Arvancloud.domain
(String) UUID or the name of the domain.name
(String) The name of the record.ttl
(Number)type
(String) The type of DNS record. Valid values are: a, aaaa, aname, cname, caa, dkim, spf, txt, tlsa, mx, ns, ptr, srv.value
(Attributes) The record value based on its type. (see below for nested schema)
Optional
id
(String) UUID of the DNS record.ip_filter_mode
(Attributes) IP filter mode configuration. (see below for nested schema)upstream_https
(String) HTTPS configuration for the upstream server.
Read-Only
is_protected
(Boolean) Whether this record is protected.last_updated
(String) Timestamp of the last update.
Nested Schema for value
Optional:
a
(Attributes List) Values for A record type. (see below for nested schema)aaaa
(Attributes List) Values for AAAA record type. (see below for nested schema)aname
(Attributes) Value for ANAME record type. (see below for nested schema)caa
(Attributes) Value for CAA record type. (see below for nested schema)cname
(Attributes) Value for CNAME record type. (see below for nested schema)dkim
(Attributes) Value for DKIM record type. (see below for nested schema)mx
(Attributes) Value for MX record type. (see below for nested schema)ns
(Attributes) Value for NS record type. (see below for nested schema)ptr
(Attributes) Value for PTR record type. (see below for nested schema)spf
(Attributes) Value for SPF record type. (see below for nested schema)srv
(Attributes) Value for SRV record type. (see below for nested schema)tlsa
(Attributes) Value for TLSA record type. (see below for nested schema)txt
(Attributes) Value for TXT record type. (see below for nested schema)
Nested Schema for value.a
Required:
ip
(String) IPv4 address.
Optional:
country
(String) Country code for geo-routing.port
(Number) Port number.weight
(Number) Weight for load balancing.
Nested Schema for value.aaaa
Required:
ip
(String) IPv6 address.
Optional:
country
(String) Country code for geo-routing.port
(Number) Port number.weight
(Number) Weight for load balancing.
Nested Schema for value.aname
Required:
host_header
(String) Host header value.location
(String) Target location.
Optional:
port
(Number) Port number.
Nested Schema for value.caa
Optional:
tag
(String) CAA tag.value
(String) CAA value.
Nested Schema for value.cname
Required:
host
(String) Target hostname.host_header
(String) Host header value.
Optional:
port
(Number) Port number.
Nested Schema for value.dkim
Required:
text
(String) DKIM record content.
Nested Schema for value.mx
Required:
host
(String) Mail exchange server hostname.priority
(Number) Priority for mail exchange server.
Nested Schema for value.ns
Required:
host
(String) Name server hostname.
Nested Schema for value.ptr
Required:
domain
(String) Domain name for reverse lookup.
Nested Schema for value.spf
Required:
text
(String) SPF record content.
Nested Schema for value.srv
Required:
target
(String) Target hostname.
Optional:
port
(Number) Target port.priority
(Number) Priority of the target host.weight
(Number) Relative weight for records with the same priority.
Nested Schema for value.tlsa
Required:
certificate
(String) TLSA certificate data.matching_type
(String) TLSA matching type field.selector
(String) TLSA selector field.usage
(String) TLSA usage field.