DomainVerification class
Resource for managing an AWS VPC Lattice Domain Verification.
Starts the domain verification process for a custom domain name. Use this resource to verify ownership of a domain before associating it with VPC Lattice resources.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.vpclattice.DomainVerification("example", {domainName: "example.com"});
// Create DNS TXT record for domain verification
const exampleRecord = new aws.route53.Record("example", {
zoneId: exampleAwsRoute53Zone.zoneId,
name: example.txtRecordName,
type: aws.route53.RecordType.TXT,
ttl: 300,
records: [example.txtRecordValue],
});
import pulumi
import pulumi_aws as aws
example = aws.vpclattice.DomainVerification("example", domain_name="example.com")
# Create DNS TXT record for domain verification
example_record = aws.route53.Record("example",
zone_id=example_aws_route53_zone["zoneId"],
name=example.txt_record_name,
type=aws.route53.RecordType.TXT,
ttl=300,
records=[example.txt_record_value])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.VpcLattice.DomainVerification("example", new()
{
DomainName = "example.com",
});
// Create DNS TXT record for domain verification
var exampleRecord = new Aws.Route53.Record("example", new()
{
ZoneId = exampleAwsRoute53Zone.ZoneId,
Name = example.TxtRecordName,
Type = Aws.Route53.RecordType.TXT,
Ttl = 300,
Records = new[]
{
example.TxtRecordValue,
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/route53"
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/vpclattice"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := vpclattice.NewDomainVerification(ctx, "example", &vpclattice.DomainVerificationArgs{
DomainName: pulumi.String("example.com"),
})
if err != nil {
return err
}
// Create DNS TXT record for domain verification
_, err = route53.NewRecord(ctx, "example", &route53.RecordArgs{
ZoneId: pulumi.Any(exampleAwsRoute53Zone.ZoneId),
Name: example.TxtRecordName,
Type: pulumi.String(route53.RecordTypeTXT),
Ttl: pulumi.Int(300),
Records: pulumi.StringArray{
example.TxtRecordValue,
},
})
if err != nil {
return err
}
return nil
})
}
pulumi {
required_providers {
aws = {
source = "pulumi/aws"
}
}
}
resource "aws_vpclattice_domainverification" "example" {
domain_name = "example.com"
}
# Create DNS TXT record for domain verification
resource "aws_route53_record" "example" {
zone_id = exampleAwsRoute53Zone.zoneId
name = aws_vpclattice_domainverification.example.txt_record_name
type = "TXT"
ttl = 300
records = [aws_vpclattice_domainverification.example.txt_record_value]
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.vpclattice.DomainVerification;
import com.pulumi.aws.vpclattice.DomainVerificationArgs;
import com.pulumi.aws.route53.Record;
import com.pulumi.aws.route53.RecordArgs;
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 DomainVerification("example", DomainVerificationArgs.builder()
.domainName("example.com")
.build());
// Create DNS TXT record for domain verification
var exampleRecord = new Record("exampleRecord", RecordArgs.builder()
.zoneId(exampleAwsRoute53Zone.zoneId())
.name(example.txtRecordName())
.type("TXT")
.ttl(300)
.records(example.txtRecordValue())
.build());
}
}
resources:
example:
type: aws:vpclattice:DomainVerification
properties:
domainName: example.com
# Create DNS TXT record for domain verification
exampleRecord:
type: aws:route53:Record
name: example
properties:
zoneId: ${exampleAwsRoute53Zone.zoneId}
name: ${example.txtRecordName}
type: TXT
ttl: 300
records:
- ${example.txtRecordValue}
With Tags
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.vpclattice.DomainVerification("example", {
domainName: "example.com",
tags: {
Environment: "production",
Purpose: "domain-verification",
},
});
import pulumi
import pulumi_aws as aws
example = aws.vpclattice.DomainVerification("example",
domain_name="example.com",
tags={
"Environment": "production",
"Purpose": "domain-verification",
})
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.VpcLattice.DomainVerification("example", new()
{
DomainName = "example.com",
Tags =
{
{ "Environment", "production" },
{ "Purpose", "domain-verification" },
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/vpclattice"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vpclattice.NewDomainVerification(ctx, "example", &vpclattice.DomainVerificationArgs{
DomainName: pulumi.String("example.com"),
Tags: pulumi.StringMap{
"Environment": pulumi.String("production"),
"Purpose": pulumi.String("domain-verification"),
},
})
if err != nil {
return err
}
return nil
})
}
pulumi {
required_providers {
aws = {
source = "pulumi/aws"
}
}
}
resource "aws_vpclattice_domainverification" "example" {
domain_name = "example.com"
tags = {
"Environment" = "production"
"Purpose" = "domain-verification"
}
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.vpclattice.DomainVerification;
import com.pulumi.aws.vpclattice.DomainVerificationArgs;
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 DomainVerification("example", DomainVerificationArgs.builder()
.domainName("example.com")
.tags(Map.ofEntries(
Map.entry("Environment", "production"),
Map.entry("Purpose", "domain-verification")
))
.build());
}
}
resources:
example:
type: aws:vpclattice:DomainVerification
properties:
domainName: example.com
tags:
Environment: production
Purpose: domain-verification
Import
Using pulumi import, import VPC Lattice Domain Verification using the id. For example:
$ pulumi import aws:vpclattice/domainVerification:DomainVerification example dv-0a1b2c3d4e5f
Constructors
- DomainVerification(String name, {DomainVerificationArgs? args, CustomResourceOptions? options})
-
Creates a new DomainVerification.
nameThe Pulumi resource name.argsArguments used to configure this DomainVerification. The set of arguments for DomainVerification.optionsResource options controlling this resource's behavior. - DomainVerification.reference(String urn)
- Creates a typed reference to an existing DomainVerification resource.
Properties
-
arn
↔ Output<
String> -
ARN of the domain verification.
latefinal
-
childResources
→ Set<
Resource> -
finalinherited
-
completionSources
↔ Map<
String, IOutputCompletionSource> -
latefinalinherited
-
createdAt
↔ Output<
String> -
Date and time that the domain verification was created, in ISO-8601 format.
latefinal
-
domainName
↔ Output<
String> -
Domain name to verify ownership for.
latefinal
- hashCode → int
-
The hash code for this object.
no setterinherited
-
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
-
lastVerifiedTime
↔ Output<
String> -
Date and time that the domain was last successfully verified, in ISO-8601 format.
latefinal
-
region
↔ Output<
String> -
Region where this resource will be managed. Defaults to the Region set in the provider configuration.
latefinal
-
resourceTransforms
→ List<
ResourceTransform> -
Inherited/explicit async transforms.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
status
↔ Output<
String> -
Current status of the domain verification process. Valid values:
VERIFIED,PENDING,VERIFICATION_TIMED_OUT.latefinal -
Key-value mapping of resource tags. If configured with a provider
defaultTagsconfiguration block present, tags with matching keys will overwrite those defined at the provider-level.latefinal -
Map of tags assigned to the resource, including those inherited from the provider
defaultTagsconfiguration block.latefinal -
transformations
→ List<
ResourceTransformation> -
Inherited/explicit legacy transformations.
no setterinherited
-
txtRecordName
↔ Output<
String> -
Name of the TXT record that must be created for domain verification.
latefinal
-
txtRecordValue
↔ Output<
String> -
Value that must be added to the TXT record for domain verification.
latefinal
-
urn
↔ Output<
String> -
latefinalinherited
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
Static Methods
-
get(
String name, Input< String> id, {DomainVerificationState? state, CustomResourceOptions? options}) → DomainVerification -
Gets an existing DomainVerification resource's state with the given
nameandid.