1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. cloudfirewall
  5. PrivateDns
Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi
alicloud logo
Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi

    Provides a Cloud Firewall Private Dns resource.

    Private DNS Endpoint.

    For information about Cloud Firewall Private Dns and how to use it, see What is Private Dns.

    NOTE: Available since v1.264.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "terraform-example";
    const current = alicloud.getAccount({});
    const vpc = new alicloud.vpc.Network("vpc", {
        cidrBlock: "172.16.0.0/12",
        vpcName: "yqc-example-vpc",
    });
    const vpcvsw1 = new alicloud.vpc.Switch("vpcvsw1", {
        vpcId: vpc.id,
        zoneId: "cn-hangzhou-i",
        cidrBlock: "172.16.3.0/24",
    });
    const vpcvsw2 = new alicloud.vpc.Switch("vpcvsw2", {
        vpcId: vpc.id,
        zoneId: "cn-hangzhou-j",
        cidrBlock: "172.16.4.0/24",
    });
    const _default = new alicloud.cloudfirewall.PrivateDns("default", {
        regionNo: "cn-hangzhou",
        accessInstanceName: name,
        port: 53,
        primaryVswitchId: vpcvsw1.id,
        standbyDns: "4.4.4.4",
        primaryDns: "8.8.8.8",
        vpcId: vpc.id,
        privateDnsType: "Custom",
        firewallTypes: ["internet"],
        ipProtocol: "UDP",
        standbyVswitchId: vpcvsw2.id,
        domainNameLists: ["www.aliyun.com"],
        primaryVswitchIp: "172.16.3.1",
        standbyVswitchIp: "172.16.4.1",
        memberUid: current.then(current => current.id),
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    current = alicloud.get_account()
    vpc = alicloud.vpc.Network("vpc",
        cidr_block="172.16.0.0/12",
        vpc_name="yqc-example-vpc")
    vpcvsw1 = alicloud.vpc.Switch("vpcvsw1",
        vpc_id=vpc.id,
        zone_id="cn-hangzhou-i",
        cidr_block="172.16.3.0/24")
    vpcvsw2 = alicloud.vpc.Switch("vpcvsw2",
        vpc_id=vpc.id,
        zone_id="cn-hangzhou-j",
        cidr_block="172.16.4.0/24")
    default = alicloud.cloudfirewall.PrivateDns("default",
        region_no="cn-hangzhou",
        access_instance_name=name,
        port=53,
        primary_vswitch_id=vpcvsw1.id,
        standby_dns="4.4.4.4",
        primary_dns="8.8.8.8",
        vpc_id=vpc.id,
        private_dns_type="Custom",
        firewall_types=["internet"],
        ip_protocol="UDP",
        standby_vswitch_id=vpcvsw2.id,
        domain_name_lists=["www.aliyun.com"],
        primary_vswitch_ip="172.16.3.1",
        standby_vswitch_ip="172.16.4.1",
        member_uid=current.id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cloudfirewall"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := "terraform-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		current, err := alicloud.GetAccount(ctx, map[string]interface{}{}, nil)
    		if err != nil {
    			return err
    		}
    		vpc, err := vpc.NewNetwork(ctx, "vpc", &vpc.NetworkArgs{
    			CidrBlock: pulumi.String("172.16.0.0/12"),
    			VpcName:   pulumi.String("yqc-example-vpc"),
    		})
    		if err != nil {
    			return err
    		}
    		vpcvsw1, err := vpc.NewSwitch(ctx, "vpcvsw1", &vpc.SwitchArgs{
    			VpcId:     vpc.ID(),
    			ZoneId:    pulumi.String("cn-hangzhou-i"),
    			CidrBlock: pulumi.String("172.16.3.0/24"),
    		})
    		if err != nil {
    			return err
    		}
    		vpcvsw2, err := vpc.NewSwitch(ctx, "vpcvsw2", &vpc.SwitchArgs{
    			VpcId:     vpc.ID(),
    			ZoneId:    pulumi.String("cn-hangzhou-j"),
    			CidrBlock: pulumi.String("172.16.4.0/24"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = cloudfirewall.NewPrivateDns(ctx, "default", &cloudfirewall.PrivateDnsArgs{
    			RegionNo:           pulumi.String("cn-hangzhou"),
    			AccessInstanceName: pulumi.String(name),
    			Port:               pulumi.Int(53),
    			PrimaryVswitchId:   vpcvsw1.ID(),
    			StandbyDns:         pulumi.String("4.4.4.4"),
    			PrimaryDns:         pulumi.String("8.8.8.8"),
    			VpcId:              vpc.ID(),
    			PrivateDnsType:     pulumi.String("Custom"),
    			FirewallTypes: pulumi.StringArray{
    				pulumi.String("internet"),
    			},
    			IpProtocol:       pulumi.String("UDP"),
    			StandbyVswitchId: vpcvsw2.ID(),
    			DomainNameLists: pulumi.StringArray{
    				pulumi.String("www.aliyun.com"),
    			},
    			PrimaryVswitchIp: pulumi.String("172.16.3.1"),
    			StandbyVswitchIp: pulumi.String("172.16.4.1"),
    			MemberUid:        pulumi.String(current.Id),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "terraform-example";
        var current = AliCloud.GetAccount.Invoke();
    
        var vpc = new AliCloud.Vpc.Network("vpc", new()
        {
            CidrBlock = "172.16.0.0/12",
            VpcName = "yqc-example-vpc",
        });
    
        var vpcvsw1 = new AliCloud.Vpc.Switch("vpcvsw1", new()
        {
            VpcId = vpc.Id,
            ZoneId = "cn-hangzhou-i",
            CidrBlock = "172.16.3.0/24",
        });
    
        var vpcvsw2 = new AliCloud.Vpc.Switch("vpcvsw2", new()
        {
            VpcId = vpc.Id,
            ZoneId = "cn-hangzhou-j",
            CidrBlock = "172.16.4.0/24",
        });
    
        var @default = new AliCloud.CloudFirewall.PrivateDns("default", new()
        {
            RegionNo = "cn-hangzhou",
            AccessInstanceName = name,
            Port = 53,
            PrimaryVswitchId = vpcvsw1.Id,
            StandbyDns = "4.4.4.4",
            PrimaryDns = "8.8.8.8",
            VpcId = vpc.Id,
            PrivateDnsType = "Custom",
            FirewallTypes = new[]
            {
                "internet",
            },
            IpProtocol = "UDP",
            StandbyVswitchId = vpcvsw2.Id,
            DomainNameLists = new[]
            {
                "www.aliyun.com",
            },
            PrimaryVswitchIp = "172.16.3.1",
            StandbyVswitchIp = "172.16.4.1",
            MemberUid = current.Apply(getAccountResult => getAccountResult.Id),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.AlicloudFunctions;
    import com.pulumi.alicloud.vpc.Network;
    import com.pulumi.alicloud.vpc.NetworkArgs;
    import com.pulumi.alicloud.vpc.Switch;
    import com.pulumi.alicloud.vpc.SwitchArgs;
    import com.pulumi.alicloud.cloudfirewall.PrivateDns;
    import com.pulumi.alicloud.cloudfirewall.PrivateDnsArgs;
    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) {
            final var config = ctx.config();
            final var name = config.get("name").orElse("terraform-example");
            final var current = AlicloudFunctions.getAccount(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference);
    
            var vpc = new Network("vpc", NetworkArgs.builder()
                .cidrBlock("172.16.0.0/12")
                .vpcName("yqc-example-vpc")
                .build());
    
            var vpcvsw1 = new Switch("vpcvsw1", SwitchArgs.builder()
                .vpcId(vpc.id())
                .zoneId("cn-hangzhou-i")
                .cidrBlock("172.16.3.0/24")
                .build());
    
            var vpcvsw2 = new Switch("vpcvsw2", SwitchArgs.builder()
                .vpcId(vpc.id())
                .zoneId("cn-hangzhou-j")
                .cidrBlock("172.16.4.0/24")
                .build());
    
            var default_ = new PrivateDns("default", PrivateDnsArgs.builder()
                .regionNo("cn-hangzhou")
                .accessInstanceName(name)
                .port(53)
                .primaryVswitchId(vpcvsw1.id())
                .standbyDns("4.4.4.4")
                .primaryDns("8.8.8.8")
                .vpcId(vpc.id())
                .privateDnsType("Custom")
                .firewallTypes("internet")
                .ipProtocol("UDP")
                .standbyVswitchId(vpcvsw2.id())
                .domainNameLists("www.aliyun.com")
                .primaryVswitchIp("172.16.3.1")
                .standbyVswitchIp("172.16.4.1")
                .memberUid(current.id())
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      vpc:
        type: alicloud:vpc:Network
        properties:
          cidrBlock: 172.16.0.0/12
          vpcName: yqc-example-vpc
      vpcvsw1:
        type: alicloud:vpc:Switch
        properties:
          vpcId: ${vpc.id}
          zoneId: cn-hangzhou-i
          cidrBlock: 172.16.3.0/24
      vpcvsw2:
        type: alicloud:vpc:Switch
        properties:
          vpcId: ${vpc.id}
          zoneId: cn-hangzhou-j
          cidrBlock: 172.16.4.0/24
      default:
        type: alicloud:cloudfirewall:PrivateDns
        properties:
          regionNo: cn-hangzhou
          accessInstanceName: ${name}
          port: '53'
          primaryVswitchId: ${vpcvsw1.id}
          standbyDns: 4.4.4.4
          primaryDns: 8.8.8.8
          vpcId: ${vpc.id}
          privateDnsType: Custom
          firewallTypes:
            - internet
          ipProtocol: UDP
          standbyVswitchId: ${vpcvsw2.id}
          domainNameLists:
            - www.aliyun.com
          primaryVswitchIp: 172.16.3.1
          standbyVswitchIp: 172.16.4.1
          memberUid: ${current.id}
    variables:
      current:
        fn::invoke:
          function: alicloud:getAccount
          arguments: {}
    

    Create PrivateDns Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new PrivateDns(name: string, args: PrivateDnsArgs, opts?: CustomResourceOptions);
    @overload
    def PrivateDns(resource_name: str,
                   args: PrivateDnsArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def PrivateDns(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   private_dns_type: Optional[str] = None,
                   vpc_id: Optional[str] = None,
                   firewall_types: Optional[Sequence[str]] = None,
                   access_instance_name: Optional[str] = None,
                   region_no: Optional[str] = None,
                   ip_protocol: Optional[str] = None,
                   primary_dns: Optional[str] = None,
                   primary_vswitch_id: Optional[str] = None,
                   primary_vswitch_ip: Optional[str] = None,
                   port: Optional[int] = None,
                   member_uid: Optional[int] = None,
                   standby_dns: Optional[str] = None,
                   standby_vswitch_id: Optional[str] = None,
                   standby_vswitch_ip: Optional[str] = None,
                   domain_name_lists: Optional[Sequence[str]] = None)
    func NewPrivateDns(ctx *Context, name string, args PrivateDnsArgs, opts ...ResourceOption) (*PrivateDns, error)
    public PrivateDns(string name, PrivateDnsArgs args, CustomResourceOptions? opts = null)
    public PrivateDns(String name, PrivateDnsArgs args)
    public PrivateDns(String name, PrivateDnsArgs args, CustomResourceOptions options)
    
    type: alicloud:cloudfirewall:PrivateDns
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args PrivateDnsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args PrivateDnsArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args PrivateDnsArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args PrivateDnsArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args PrivateDnsArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var privateDnsResource = new AliCloud.CloudFirewall.PrivateDns("privateDnsResource", new()
    {
        PrivateDnsType = "string",
        VpcId = "string",
        FirewallTypes = new[]
        {
            "string",
        },
        AccessInstanceName = "string",
        RegionNo = "string",
        IpProtocol = "string",
        PrimaryDns = "string",
        PrimaryVswitchId = "string",
        PrimaryVswitchIp = "string",
        Port = 0,
        MemberUid = 0,
        StandbyDns = "string",
        StandbyVswitchId = "string",
        StandbyVswitchIp = "string",
        DomainNameLists = new[]
        {
            "string",
        },
    });
    
    example, err := cloudfirewall.NewPrivateDns(ctx, "privateDnsResource", &cloudfirewall.PrivateDnsArgs{
    	PrivateDnsType: pulumi.String("string"),
    	VpcId:          pulumi.String("string"),
    	FirewallTypes: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	AccessInstanceName: pulumi.String("string"),
    	RegionNo:           pulumi.String("string"),
    	IpProtocol:         pulumi.String("string"),
    	PrimaryDns:         pulumi.String("string"),
    	PrimaryVswitchId:   pulumi.String("string"),
    	PrimaryVswitchIp:   pulumi.String("string"),
    	Port:               pulumi.Int(0),
    	MemberUid:          pulumi.Int(0),
    	StandbyDns:         pulumi.String("string"),
    	StandbyVswitchId:   pulumi.String("string"),
    	StandbyVswitchIp:   pulumi.String("string"),
    	DomainNameLists: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var privateDnsResource = new PrivateDns("privateDnsResource", PrivateDnsArgs.builder()
        .privateDnsType("string")
        .vpcId("string")
        .firewallTypes("string")
        .accessInstanceName("string")
        .regionNo("string")
        .ipProtocol("string")
        .primaryDns("string")
        .primaryVswitchId("string")
        .primaryVswitchIp("string")
        .port(0)
        .memberUid(0)
        .standbyDns("string")
        .standbyVswitchId("string")
        .standbyVswitchIp("string")
        .domainNameLists("string")
        .build());
    
    private_dns_resource = alicloud.cloudfirewall.PrivateDns("privateDnsResource",
        private_dns_type="string",
        vpc_id="string",
        firewall_types=["string"],
        access_instance_name="string",
        region_no="string",
        ip_protocol="string",
        primary_dns="string",
        primary_vswitch_id="string",
        primary_vswitch_ip="string",
        port=0,
        member_uid=0,
        standby_dns="string",
        standby_vswitch_id="string",
        standby_vswitch_ip="string",
        domain_name_lists=["string"])
    
    const privateDnsResource = new alicloud.cloudfirewall.PrivateDns("privateDnsResource", {
        privateDnsType: "string",
        vpcId: "string",
        firewallTypes: ["string"],
        accessInstanceName: "string",
        regionNo: "string",
        ipProtocol: "string",
        primaryDns: "string",
        primaryVswitchId: "string",
        primaryVswitchIp: "string",
        port: 0,
        memberUid: 0,
        standbyDns: "string",
        standbyVswitchId: "string",
        standbyVswitchIp: "string",
        domainNameLists: ["string"],
    });
    
    type: alicloud:cloudfirewall:PrivateDns
    properties:
        accessInstanceName: string
        domainNameLists:
            - string
        firewallTypes:
            - string
        ipProtocol: string
        memberUid: 0
        port: 0
        primaryDns: string
        primaryVswitchId: string
        primaryVswitchIp: string
        privateDnsType: string
        regionNo: string
        standbyDns: string
        standbyVswitchId: string
        standbyVswitchIp: string
        vpcId: string
    

    PrivateDns Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The PrivateDns resource accepts the following input properties:

    AccessInstanceName string
    The name of Private DNS instance
    FirewallTypes List<string>
    The type of firewall
    PrivateDnsType string
    The type of Private DNS instance
    RegionNo string
    The region ID of Private DNS instance
    VpcId string
    The ID of the VPC.
    DomainNameLists List<string>
    Private DNS domain name list
    IpProtocol string
    IP protocol
    MemberUid int
    The member Uid
    Port int
    The Port of Private DNS instance
    PrimaryDns string
    Primary DNS IP
    PrimaryVswitchId string
    Primary zone Switch ID
    PrimaryVswitchIp string
    Primary zone switch IP
    StandbyDns string
    Standby DNS IP
    StandbyVswitchId string
    Standby zone switch ID
    StandbyVswitchIp string
    Standby zone switch IP address
    AccessInstanceName string
    The name of Private DNS instance
    FirewallTypes []string
    The type of firewall
    PrivateDnsType string
    The type of Private DNS instance
    RegionNo string
    The region ID of Private DNS instance
    VpcId string
    The ID of the VPC.
    DomainNameLists []string
    Private DNS domain name list
    IpProtocol string
    IP protocol
    MemberUid int
    The member Uid
    Port int
    The Port of Private DNS instance
    PrimaryDns string
    Primary DNS IP
    PrimaryVswitchId string
    Primary zone Switch ID
    PrimaryVswitchIp string
    Primary zone switch IP
    StandbyDns string
    Standby DNS IP
    StandbyVswitchId string
    Standby zone switch ID
    StandbyVswitchIp string
    Standby zone switch IP address
    accessInstanceName String
    The name of Private DNS instance
    firewallTypes List<String>
    The type of firewall
    privateDnsType String
    The type of Private DNS instance
    regionNo String
    The region ID of Private DNS instance
    vpcId String
    The ID of the VPC.
    domainNameLists List<String>
    Private DNS domain name list
    ipProtocol String
    IP protocol
    memberUid Integer
    The member Uid
    port Integer
    The Port of Private DNS instance
    primaryDns String
    Primary DNS IP
    primaryVswitchId String
    Primary zone Switch ID
    primaryVswitchIp String
    Primary zone switch IP
    standbyDns String
    Standby DNS IP
    standbyVswitchId String
    Standby zone switch ID
    standbyVswitchIp String
    Standby zone switch IP address
    accessInstanceName string
    The name of Private DNS instance
    firewallTypes string[]
    The type of firewall
    privateDnsType string
    The type of Private DNS instance
    regionNo string
    The region ID of Private DNS instance
    vpcId string
    The ID of the VPC.
    domainNameLists string[]
    Private DNS domain name list
    ipProtocol string
    IP protocol
    memberUid number
    The member Uid
    port number
    The Port of Private DNS instance
    primaryDns string
    Primary DNS IP
    primaryVswitchId string
    Primary zone Switch ID
    primaryVswitchIp string
    Primary zone switch IP
    standbyDns string
    Standby DNS IP
    standbyVswitchId string
    Standby zone switch ID
    standbyVswitchIp string
    Standby zone switch IP address
    access_instance_name str
    The name of Private DNS instance
    firewall_types Sequence[str]
    The type of firewall
    private_dns_type str
    The type of Private DNS instance
    region_no str
    The region ID of Private DNS instance
    vpc_id str
    The ID of the VPC.
    domain_name_lists Sequence[str]
    Private DNS domain name list
    ip_protocol str
    IP protocol
    member_uid int
    The member Uid
    port int
    The Port of Private DNS instance
    primary_dns str
    Primary DNS IP
    primary_vswitch_id str
    Primary zone Switch ID
    primary_vswitch_ip str
    Primary zone switch IP
    standby_dns str
    Standby DNS IP
    standby_vswitch_id str
    Standby zone switch ID
    standby_vswitch_ip str
    Standby zone switch IP address
    accessInstanceName String
    The name of Private DNS instance
    firewallTypes List<String>
    The type of firewall
    privateDnsType String
    The type of Private DNS instance
    regionNo String
    The region ID of Private DNS instance
    vpcId String
    The ID of the VPC.
    domainNameLists List<String>
    Private DNS domain name list
    ipProtocol String
    IP protocol
    memberUid Number
    The member Uid
    port Number
    The Port of Private DNS instance
    primaryDns String
    Primary DNS IP
    primaryVswitchId String
    Primary zone Switch ID
    primaryVswitchIp String
    Primary zone switch IP
    standbyDns String
    Standby DNS IP
    standbyVswitchId String
    Standby zone switch ID
    standbyVswitchIp String
    Standby zone switch IP address

    Outputs

    All input properties are implicitly available as output properties. Additionally, the PrivateDns resource produces the following output properties:

    AccessInstanceId string
    The id of Private DNS instance
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    status
    AccessInstanceId string
    The id of Private DNS instance
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    status
    accessInstanceId String
    The id of Private DNS instance
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    status
    accessInstanceId string
    The id of Private DNS instance
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    status
    access_instance_id str
    The id of Private DNS instance
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    status
    accessInstanceId String
    The id of Private DNS instance
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    status

    Look up Existing PrivateDns Resource

    Get an existing PrivateDns resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: PrivateDnsState, opts?: CustomResourceOptions): PrivateDns
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            access_instance_id: Optional[str] = None,
            access_instance_name: Optional[str] = None,
            domain_name_lists: Optional[Sequence[str]] = None,
            firewall_types: Optional[Sequence[str]] = None,
            ip_protocol: Optional[str] = None,
            member_uid: Optional[int] = None,
            port: Optional[int] = None,
            primary_dns: Optional[str] = None,
            primary_vswitch_id: Optional[str] = None,
            primary_vswitch_ip: Optional[str] = None,
            private_dns_type: Optional[str] = None,
            region_no: Optional[str] = None,
            standby_dns: Optional[str] = None,
            standby_vswitch_id: Optional[str] = None,
            standby_vswitch_ip: Optional[str] = None,
            status: Optional[str] = None,
            vpc_id: Optional[str] = None) -> PrivateDns
    func GetPrivateDns(ctx *Context, name string, id IDInput, state *PrivateDnsState, opts ...ResourceOption) (*PrivateDns, error)
    public static PrivateDns Get(string name, Input<string> id, PrivateDnsState? state, CustomResourceOptions? opts = null)
    public static PrivateDns get(String name, Output<String> id, PrivateDnsState state, CustomResourceOptions options)
    resources:  _:    type: alicloud:cloudfirewall:PrivateDns    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AccessInstanceId string
    The id of Private DNS instance
    AccessInstanceName string
    The name of Private DNS instance
    DomainNameLists List<string>
    Private DNS domain name list
    FirewallTypes List<string>
    The type of firewall
    IpProtocol string
    IP protocol
    MemberUid int
    The member Uid
    Port int
    The Port of Private DNS instance
    PrimaryDns string
    Primary DNS IP
    PrimaryVswitchId string
    Primary zone Switch ID
    PrimaryVswitchIp string
    Primary zone switch IP
    PrivateDnsType string
    The type of Private DNS instance
    RegionNo string
    The region ID of Private DNS instance
    StandbyDns string
    Standby DNS IP
    StandbyVswitchId string
    Standby zone switch ID
    StandbyVswitchIp string
    Standby zone switch IP address
    Status string
    status
    VpcId string
    The ID of the VPC.
    AccessInstanceId string
    The id of Private DNS instance
    AccessInstanceName string
    The name of Private DNS instance
    DomainNameLists []string
    Private DNS domain name list
    FirewallTypes []string
    The type of firewall
    IpProtocol string
    IP protocol
    MemberUid int
    The member Uid
    Port int
    The Port of Private DNS instance
    PrimaryDns string
    Primary DNS IP
    PrimaryVswitchId string
    Primary zone Switch ID
    PrimaryVswitchIp string
    Primary zone switch IP
    PrivateDnsType string
    The type of Private DNS instance
    RegionNo string
    The region ID of Private DNS instance
    StandbyDns string
    Standby DNS IP
    StandbyVswitchId string
    Standby zone switch ID
    StandbyVswitchIp string
    Standby zone switch IP address
    Status string
    status
    VpcId string
    The ID of the VPC.
    accessInstanceId String
    The id of Private DNS instance
    accessInstanceName String
    The name of Private DNS instance
    domainNameLists List<String>
    Private DNS domain name list
    firewallTypes List<String>
    The type of firewall
    ipProtocol String
    IP protocol
    memberUid Integer
    The member Uid
    port Integer
    The Port of Private DNS instance
    primaryDns String
    Primary DNS IP
    primaryVswitchId String
    Primary zone Switch ID
    primaryVswitchIp String
    Primary zone switch IP
    privateDnsType String
    The type of Private DNS instance
    regionNo String
    The region ID of Private DNS instance
    standbyDns String
    Standby DNS IP
    standbyVswitchId String
    Standby zone switch ID
    standbyVswitchIp String
    Standby zone switch IP address
    status String
    status
    vpcId String
    The ID of the VPC.
    accessInstanceId string
    The id of Private DNS instance
    accessInstanceName string
    The name of Private DNS instance
    domainNameLists string[]
    Private DNS domain name list
    firewallTypes string[]
    The type of firewall
    ipProtocol string
    IP protocol
    memberUid number
    The member Uid
    port number
    The Port of Private DNS instance
    primaryDns string
    Primary DNS IP
    primaryVswitchId string
    Primary zone Switch ID
    primaryVswitchIp string
    Primary zone switch IP
    privateDnsType string
    The type of Private DNS instance
    regionNo string
    The region ID of Private DNS instance
    standbyDns string
    Standby DNS IP
    standbyVswitchId string
    Standby zone switch ID
    standbyVswitchIp string
    Standby zone switch IP address
    status string
    status
    vpcId string
    The ID of the VPC.
    access_instance_id str
    The id of Private DNS instance
    access_instance_name str
    The name of Private DNS instance
    domain_name_lists Sequence[str]
    Private DNS domain name list
    firewall_types Sequence[str]
    The type of firewall
    ip_protocol str
    IP protocol
    member_uid int
    The member Uid
    port int
    The Port of Private DNS instance
    primary_dns str
    Primary DNS IP
    primary_vswitch_id str
    Primary zone Switch ID
    primary_vswitch_ip str
    Primary zone switch IP
    private_dns_type str
    The type of Private DNS instance
    region_no str
    The region ID of Private DNS instance
    standby_dns str
    Standby DNS IP
    standby_vswitch_id str
    Standby zone switch ID
    standby_vswitch_ip str
    Standby zone switch IP address
    status str
    status
    vpc_id str
    The ID of the VPC.
    accessInstanceId String
    The id of Private DNS instance
    accessInstanceName String
    The name of Private DNS instance
    domainNameLists List<String>
    Private DNS domain name list
    firewallTypes List<String>
    The type of firewall
    ipProtocol String
    IP protocol
    memberUid Number
    The member Uid
    port Number
    The Port of Private DNS instance
    primaryDns String
    Primary DNS IP
    primaryVswitchId String
    Primary zone Switch ID
    primaryVswitchIp String
    Primary zone switch IP
    privateDnsType String
    The type of Private DNS instance
    regionNo String
    The region ID of Private DNS instance
    standbyDns String
    Standby DNS IP
    standbyVswitchId String
    Standby zone switch ID
    standbyVswitchIp String
    Standby zone switch IP address
    status String
    status
    vpcId String
    The ID of the VPC.

    Import

    Cloud Firewall Private Dns can be imported using the id, e.g.

    $ pulumi import alicloud:cloudfirewall/privateDns:PrivateDns example <access_instance_id>:<region_no>
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.90.0 published on Tuesday, Dec 2, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate