ResolverRuleArgs

data class ResolverRuleArgs(val domainName: Output<String>? = null, val name: Output<String>? = null, val resolverEndpointId: Output<String>? = null, val ruleType: Output<String>? = null, val tags: Output<Map<String, String>>? = null, val targetIps: Output<List<ResolverRuleTargetIpArgs>>? = null) : ConvertibleToJava<ResolverRuleArgs>

Provides a Route53 Resolver rule.

Example Usage

System rule

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.route53.ResolverRule;
import com.pulumi.aws.route53.ResolverRuleArgs;
import java.util.List;
import java.util.ArrayList;
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 sys = new ResolverRule("sys", ResolverRuleArgs.builder()
.domainName("subdomain.example.com")
.ruleType("SYSTEM")
.build());
}
}

Forward rule

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.route53.ResolverRule;
import com.pulumi.aws.route53.ResolverRuleArgs;
import com.pulumi.aws.route53.inputs.ResolverRuleTargetIpArgs;
import java.util.List;
import java.util.ArrayList;
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 fwd = new ResolverRule("fwd", ResolverRuleArgs.builder()
.domainName("example.com")
.ruleType("FORWARD")
.resolverEndpointId(aws_route53_resolver_endpoint.foo().id())
.targetIps(ResolverRuleTargetIpArgs.builder()
.ip("123.45.67.89")
.build())
.tags(Map.of("Environment", "Prod"))
.build());
}
}

Import

Route53 Resolver rules can be imported using the id, e.g.,

$ pulumi import aws:route53/resolverRule:ResolverRule sys rslvr-rr-0123456789abcdef0

Constructors

Link copied to clipboard
constructor(domainName: Output<String>? = null, name: Output<String>? = null, resolverEndpointId: Output<String>? = null, ruleType: Output<String>? = null, tags: Output<Map<String, String>>? = null, targetIps: Output<List<ResolverRuleTargetIpArgs>>? = null)

Properties

Link copied to clipboard
val domainName: Output<String>? = null

DNS queries for this domain name are forwarded to the IP addresses that are specified using target_ip.

Link copied to clipboard
val name: Output<String>? = null

A friendly name that lets you easily find a rule in the Resolver dashboard in the Route 53 console.

Link copied to clipboard
val resolverEndpointId: Output<String>? = null

The ID of the outbound resolver endpoint that you want to use to route DNS queries to the IP addresses that you specify using target_ip. This argument should only be specified for FORWARD type rules.

Link copied to clipboard
val ruleType: Output<String>? = null

The rule type. Valid values are FORWARD, SYSTEM and RECURSIVE.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

A map of tags to assign to the resource. .If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Link copied to clipboard

Configuration block(s) indicating the IPs that you want Resolver to forward DNS queries to (documented below). This argument should only be specified for FORWARD type rules.

Functions

Link copied to clipboard
open override fun toJava(): ResolverRuleArgs