Provides a DigitalOcean domain resource.
# Create a new domain
resource "digitalocean_domain" "default" {
name = "example.com"
ip_address = digitalocean_droplet.foo.ipv4_address
}
The following arguments are supported:
name
- (Required) The name of the domainip_address
- (Optional) The IP address of the domain. If specified, this IP
is used to created an initial A record for the domain.The following attributes are exported:
id
- The name of the domainurn
- The uniform resource name of the domainttl
- The TTL value of the domainDomains can be imported using the domain name
, e.g.
terraform import digitalocean_domain.mydomain mytestdomain.com