Domain class
Provides a resource to manage a domain. This resource registers, renews and deregisters a domain name. If a domain name's lifecycle is managed outside of Terraform use the aws.route53domains.RegisteredDomain resource instead.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.route53domains.Domain("example", {
adminContact: {
addressLine1: "101 Main Street",
city: "San Francisco",
contactType: "COMPANY",
countryCode: "US",
email: "pulumi-acctest@example.com",
fax: "+1.4155551234",
firstName: "Terraform",
lastName: "Team",
organizationName: "HashiCorp",
phoneNumber: "+1.4155551234",
state: "CA",
zipCode: "94105",
},
registrantContact: {
addressLine1: "101 Main Street",
city: "San Francisco",
contactType: "COMPANY",
countryCode: "US",
email: "pulumi-acctest@example.com",
fax: "+1.4155551234",
firstName: "Terraform",
lastName: "Team",
organizationName: "HashiCorp",
phoneNumber: "+1.4155551234",
state: "CA",
zipCode: "94105",
},
techContact: {
addressLine1: "101 Main Street",
city: "San Francisco",
contactType: "COMPANY",
countryCode: "US",
email: "pulumi-acctest@example.com",
fax: "+1.4155551234",
firstName: "Terraform",
lastName: "Team",
organizationName: "HashiCorp",
phoneNumber: "+1.4155551234",
state: "CA",
zipCode: "94105",
},
domainName: "example.com",
autoRenew: false,
tags: {
Environment: "test",
},
});
import pulumi
import pulumi_aws as aws
example = aws.route53domains.Domain("example",
admin_contact={
"address_line1": "101 Main Street",
"city": "San Francisco",
"contact_type": "COMPANY",
"country_code": "US",
"email": "pulumi-acctest@example.com",
"fax": "+1.4155551234",
"first_name": "Terraform",
"last_name": "Team",
"organization_name": "HashiCorp",
"phone_number": "+1.4155551234",
"state": "CA",
"zip_code": "94105",
},
registrant_contact={
"address_line1": "101 Main Street",
"city": "San Francisco",
"contact_type": "COMPANY",
"country_code": "US",
"email": "pulumi-acctest@example.com",
"fax": "+1.4155551234",
"first_name": "Terraform",
"last_name": "Team",
"organization_name": "HashiCorp",
"phone_number": "+1.4155551234",
"state": "CA",
"zip_code": "94105",
},
tech_contact={
"address_line1": "101 Main Street",
"city": "San Francisco",
"contact_type": "COMPANY",
"country_code": "US",
"email": "pulumi-acctest@example.com",
"fax": "+1.4155551234",
"first_name": "Terraform",
"last_name": "Team",
"organization_name": "HashiCorp",
"phone_number": "+1.4155551234",
"state": "CA",
"zip_code": "94105",
},
domain_name="example.com",
auto_renew=False,
tags={
"Environment": "test",
})
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.Route53Domains.Domain("example", new()
{
AdminContact = new Aws.Route53Domains.Inputs.DomainAdminContactArgs
{
AddressLine1 = "101 Main Street",
City = "San Francisco",
ContactType = "COMPANY",
CountryCode = "US",
Email = "pulumi-acctest@example.com",
Fax = "+1.4155551234",
FirstName = "Terraform",
LastName = "Team",
OrganizationName = "HashiCorp",
PhoneNumber = "+1.4155551234",
State = "CA",
ZipCode = "94105",
},
RegistrantContact = new Aws.Route53Domains.Inputs.DomainRegistrantContactArgs
{
AddressLine1 = "101 Main Street",
City = "San Francisco",
ContactType = "COMPANY",
CountryCode = "US",
Email = "pulumi-acctest@example.com",
Fax = "+1.4155551234",
FirstName = "Terraform",
LastName = "Team",
OrganizationName = "HashiCorp",
PhoneNumber = "+1.4155551234",
State = "CA",
ZipCode = "94105",
},
TechContact = new Aws.Route53Domains.Inputs.DomainTechContactArgs
{
AddressLine1 = "101 Main Street",
City = "San Francisco",
ContactType = "COMPANY",
CountryCode = "US",
Email = "pulumi-acctest@example.com",
Fax = "+1.4155551234",
FirstName = "Terraform",
LastName = "Team",
OrganizationName = "HashiCorp",
PhoneNumber = "+1.4155551234",
State = "CA",
ZipCode = "94105",
},
DomainName = "example.com",
AutoRenew = false,
Tags =
{
{ "Environment", "test" },
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/route53domains"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := route53domains.NewDomain(ctx, "example", &route53domains.DomainArgs{
AdminContact: &route53domains.DomainAdminContactArgs{
AddressLine1: pulumi.String("101 Main Street"),
City: pulumi.String("San Francisco"),
ContactType: pulumi.String("COMPANY"),
CountryCode: pulumi.String("US"),
Email: pulumi.String("pulumi-acctest@example.com"),
Fax: pulumi.String("+1.4155551234"),
FirstName: pulumi.String("Terraform"),
LastName: pulumi.String("Team"),
OrganizationName: pulumi.String("HashiCorp"),
PhoneNumber: pulumi.String("+1.4155551234"),
State: pulumi.String("CA"),
ZipCode: pulumi.String("94105"),
},
RegistrantContact: &route53domains.DomainRegistrantContactArgs{
AddressLine1: pulumi.String("101 Main Street"),
City: pulumi.String("San Francisco"),
ContactType: pulumi.String("COMPANY"),
CountryCode: pulumi.String("US"),
Email: pulumi.String("pulumi-acctest@example.com"),
Fax: pulumi.String("+1.4155551234"),
FirstName: pulumi.String("Terraform"),
LastName: pulumi.String("Team"),
OrganizationName: pulumi.String("HashiCorp"),
PhoneNumber: pulumi.String("+1.4155551234"),
State: pulumi.String("CA"),
ZipCode: pulumi.String("94105"),
},
TechContact: &route53domains.DomainTechContactArgs{
AddressLine1: pulumi.String("101 Main Street"),
City: pulumi.String("San Francisco"),
ContactType: pulumi.String("COMPANY"),
CountryCode: pulumi.String("US"),
Email: pulumi.String("pulumi-acctest@example.com"),
Fax: pulumi.String("+1.4155551234"),
FirstName: pulumi.String("Terraform"),
LastName: pulumi.String("Team"),
OrganizationName: pulumi.String("HashiCorp"),
PhoneNumber: pulumi.String("+1.4155551234"),
State: pulumi.String("CA"),
ZipCode: pulumi.String("94105"),
},
DomainName: pulumi.String("example.com"),
AutoRenew: pulumi.Bool(false),
Tags: pulumi.StringMap{
"Environment": pulumi.String("test"),
},
})
if err != nil {
return err
}
return nil
})
}
pulumi {
required_providers {
aws = {
source = "pulumi/aws"
}
}
}
resource "aws_route53domains_domain" "example" {
admin_contact = {
address_line1 = "101 Main Street"
city = "San Francisco"
contact_type = "COMPANY"
country_code = "US"
email = "pulumi-acctest@example.com"
fax = "+1.4155551234"
first_name = "Terraform"
last_name = "Team"
organization_name = "HashiCorp"
phone_number = "+1.4155551234"
state = "CA"
zip_code = "94105"
}
registrant_contact = {
address_line1 = "101 Main Street"
city = "San Francisco"
contact_type = "COMPANY"
country_code = "US"
email = "pulumi-acctest@example.com"
fax = "+1.4155551234"
first_name = "Terraform"
last_name = "Team"
organization_name = "HashiCorp"
phone_number = "+1.4155551234"
state = "CA"
zip_code = "94105"
}
tech_contact = {
address_line1 = "101 Main Street"
city = "San Francisco"
contact_type = "COMPANY"
country_code = "US"
email = "pulumi-acctest@example.com"
fax = "+1.4155551234"
first_name = "Terraform"
last_name = "Team"
organization_name = "HashiCorp"
phone_number = "+1.4155551234"
state = "CA"
zip_code = "94105"
}
domain_name = "example.com"
auto_renew = false
tags = {
"Environment" = "test"
}
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.route53domains.Domain;
import com.pulumi.aws.route53domains.DomainArgs;
import com.pulumi.aws.route53domains.inputs.DomainAdminContactArgs;
import com.pulumi.aws.route53domains.inputs.DomainRegistrantContactArgs;
import com.pulumi.aws.route53domains.inputs.DomainTechContactArgs;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Domain("example", DomainArgs.builder()
.adminContact(DomainAdminContactArgs.builder()
.addressLine1("101 Main Street")
.city("San Francisco")
.contactType("COMPANY")
.countryCode("US")
.email("pulumi-acctest@example.com")
.fax("+1.4155551234")
.firstName("Terraform")
.lastName("Team")
.organizationName("HashiCorp")
.phoneNumber("+1.4155551234")
.state("CA")
.zipCode("94105")
.build())
.registrantContact(DomainRegistrantContactArgs.builder()
.addressLine1("101 Main Street")
.city("San Francisco")
.contactType("COMPANY")
.countryCode("US")
.email("pulumi-acctest@example.com")
.fax("+1.4155551234")
.firstName("Terraform")
.lastName("Team")
.organizationName("HashiCorp")
.phoneNumber("+1.4155551234")
.state("CA")
.zipCode("94105")
.build())
.techContact(DomainTechContactArgs.builder()
.addressLine1("101 Main Street")
.city("San Francisco")
.contactType("COMPANY")
.countryCode("US")
.email("pulumi-acctest@example.com")
.fax("+1.4155551234")
.firstName("Terraform")
.lastName("Team")
.organizationName("HashiCorp")
.phoneNumber("+1.4155551234")
.state("CA")
.zipCode("94105")
.build())
.domainName("example.com")
.autoRenew(false)
.tags(Map.of("Environment", "test"))
.build());
}
}
resources:
example:
type: aws:route53domains:Domain
properties:
adminContact:
addressLine1: 101 Main Street
city: San Francisco
contactType: COMPANY
countryCode: US
email: pulumi-acctest@example.com
fax: '+1.4155551234'
firstName: Terraform
lastName: Team
organizationName: HashiCorp
phoneNumber: '+1.4155551234'
state: CA
zipCode: '94105'
registrantContact:
addressLine1: 101 Main Street
city: San Francisco
contactType: COMPANY
countryCode: US
email: pulumi-acctest@example.com
fax: '+1.4155551234'
firstName: Terraform
lastName: Team
organizationName: HashiCorp
phoneNumber: '+1.4155551234'
state: CA
zipCode: '94105'
techContact:
addressLine1: 101 Main Street
city: San Francisco
contactType: COMPANY
countryCode: US
email: pulumi-acctest@example.com
fax: '+1.4155551234'
firstName: Terraform
lastName: Team
organizationName: HashiCorp
phoneNumber: '+1.4155551234'
state: CA
zipCode: '94105'
domainName: example.com
autoRenew: false
tags:
Environment: test
Import
Using pulumi import, import domains using the domainName. For example:
$ pulumi import aws:route53domains/domain:Domain example example.com
Constructors
- Domain(String name, {DomainArgs? args, CustomResourceOptions? options})
-
Creates a new Domain.
nameThe Pulumi resource name.argsArguments used to configure this Domain. The set of arguments for Domain.optionsResource options controlling this resource's behavior. - Domain.reference(String urn)
- Creates a typed reference to an existing Domain resource.
Properties
-
abuseContactEmail
↔ Output<
String> -
Email address to contact to report incorrect contact information for a domain, to report that the domain is being used to send spam, to report that someone is cybersquatting on a domain name, or report some other type of abuse.
latefinal
-
abuseContactPhone
↔ Output<
String> -
Phone number for reporting abuse.
latefinal
-
adminContact
↔ Output<
DomainAdminContact> -
Details about the domain administrative contact. See Contact Blocks for more details.
latefinal
-
adminPrivacy
↔ Output<
bool> -
Whether domain administrative contact information is concealed from WHOIS queries. Default:
true.latefinal -
autoRenew
↔ Output<
bool> -
Whether the domain registration is set to renew automatically. Default:
true.latefinal -
billingContacts
↔ Output<
List< DomainBillingContact> > -
Details about the domain billing contact. See Contact Blocks for more details.
latefinal
-
billingPrivacy
↔ Output<
bool> -
Whether domain billing contact information is concealed from WHOIS queries. Default:
true.latefinal -
childResources
→ Set<
Resource> -
finalinherited
-
completionSources
↔ Map<
String, IOutputCompletionSource> -
latefinalinherited
-
creationDate
↔ Output<
String> -
The date when the domain was created as found in the response to a WHOIS query.
latefinal
-
domainName
↔ Output<
String> -
The name of the domain.
latefinal
-
durationInYears
↔ Output<
int> -
The number of years that you want to register the domain for. Domains are registered for a minimum of one year. Increasing the duration renews the domain.
latefinal
-
expirationDate
↔ Output<
String> -
The date when the registration for the domain is set to expire.
latefinal
- hashCode → int
-
The hash code for this object.
no setterinherited
-
hostedZoneId
↔ Output<
String> -
The ID of the public Route 53 hosted zone created for the domain. This hosted zone is deleted when the domain is deregistered.
latefinal
-
id
↔ Output<
String> -
getter/setter pairinherited
- isCustom → bool
-
Returns whether this resource is provider-managed.
no setterinherited
- isProtected → bool
-
Returns whether this resource is protected from deletion.
no setterinherited
- isRemote → bool
-
Whether this resource is registered as remote.
no setterinherited
- isResourceReference → bool
-
Whether this instance represents a resource value returned over RPC.
finalinherited
-
nameServers
↔ Output<
List< DomainNameServer> > -
The list of nameservers for the domain. See
nameServerBlocks for more details.latefinal -
registrantContact
↔ Output<
DomainRegistrantContact> -
Details about the domain registrant. See Contact Blocks for more details.
latefinal
-
registrantPrivacy
↔ Output<
bool> -
Whether domain registrant contact information is concealed from WHOIS queries. Default:
true.latefinal -
registrarName
↔ Output<
String> -
Name of the registrar of the domain as identified in the registry.
latefinal
-
registrarUrl
↔ Output<
String> -
Web address of the registrar.
latefinal
-
resourceTransforms
→ List<
ResourceTransform> -
Inherited/explicit async transforms.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
statusLists
↔ Output<
List< String> > -
List of domain name status codes.
latefinal
-
A map of tags to assign to the resource. If configured with a provider
defaultTagsconfiguration block present, tags with matching keys will overwrite those defined at the provider-level.latefinal -
A map of tags assigned to the resource, including those inherited from the provider
defaultTagsconfiguration block.latefinal -
techContact
↔ Output<
DomainTechContact> -
Details about the domain technical contact. See Contact Blocks for more details.
latefinal
-
techPrivacy
↔ Output<
bool> -
Whether domain technical contact information is concealed from WHOIS queries. Default:
true.latefinal -
timeouts
↔ Output<
DomainTimeouts?> -
latefinal
-
transferLock
↔ Output<
bool> -
Whether the domain is locked for transfer. Default:
true.latefinal -
transformations
→ List<
ResourceTransformation> -
Inherited/explicit legacy transformations.
no setterinherited
-
updatedDate
↔ Output<
String> -
The last updated date of the domain as found in the response to a WHOIS query.
latefinal
-
urn
↔ Output<
String> -
latefinalinherited
-
whoisServer
↔ Output<
String> -
The fully qualified name of the WHOIS server that can answer the WHOIS query for the domain.
latefinal
Methods
-
failId(
Object error) → void -
Completes this resource ID with an error when registration fails.
inherited
-
failOutputs(
Object error) → void -
Completes all output properties with
error.inherited -
failUrn(
Object error) → void -
Completes this resource URN with an error when registration fails.
inherited
-
getProvider(
String moduleMember) → ProviderResource? -
Returns provider for
moduleMember's package, if configured.inherited -
getResourceName(
) → String -
Returns this resource's logical name.
inherited
-
getResourceType(
) → String -
Returns this resource's Pulumi type token.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
registerOutput<
T> (String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output< T> -
Registers a dynamic output property for this resource.
inherited
-
resolveId(
String? value, {required bool isKnown}) → void -
Resolves the provider-assigned ID for this resource.
inherited
-
resolveOutputs(
Struct outputs) → void -
Resolves all output properties from a monitor response payload.
inherited
-
resolveUrn(
String value) → void -
Resolves this resource's URN once assigned by the engine.
inherited
-
serializeProperties(
Map< String, dynamic> properties) → Future<Struct> -
Serializes resource properties for RPC transmission.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited