1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. DcInternetAddress
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.DcInternetAddress

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Provides a resource to create a dc internet_address

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const internetAddress = new tencentcloud.DcInternetAddress("internetAddress", {
        addrProto: 0,
        addrType: 2,
        maskLen: 30,
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    internet_address = tencentcloud.DcInternetAddress("internetAddress",
        addr_proto=0,
        addr_type=2,
        mask_len=30)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.NewDcInternetAddress(ctx, "internetAddress", &tencentcloud.DcInternetAddressArgs{
    			AddrProto: pulumi.Float64(0),
    			AddrType:  pulumi.Float64(2),
    			MaskLen:   pulumi.Float64(30),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var internetAddress = new Tencentcloud.DcInternetAddress("internetAddress", new()
        {
            AddrProto = 0,
            AddrType = 2,
            MaskLen = 30,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.DcInternetAddress;
    import com.pulumi.tencentcloud.DcInternetAddressArgs;
    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 internetAddress = new DcInternetAddress("internetAddress", DcInternetAddressArgs.builder()
                .addrProto(0)
                .addrType(2)
                .maskLen(30)
                .build());
    
        }
    }
    
    resources:
      internetAddress:
        type: tencentcloud:DcInternetAddress
        properties:
          addrProto: 0
          addrType: 2
          maskLen: 30
    

    Create DcInternetAddress Resource

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

    Constructor syntax

    new DcInternetAddress(name: string, args: DcInternetAddressArgs, opts?: CustomResourceOptions);
    @overload
    def DcInternetAddress(resource_name: str,
                          args: DcInternetAddressArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def DcInternetAddress(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          addr_proto: Optional[float] = None,
                          addr_type: Optional[float] = None,
                          mask_len: Optional[float] = None,
                          dc_internet_address_id: Optional[str] = None)
    func NewDcInternetAddress(ctx *Context, name string, args DcInternetAddressArgs, opts ...ResourceOption) (*DcInternetAddress, error)
    public DcInternetAddress(string name, DcInternetAddressArgs args, CustomResourceOptions? opts = null)
    public DcInternetAddress(String name, DcInternetAddressArgs args)
    public DcInternetAddress(String name, DcInternetAddressArgs args, CustomResourceOptions options)
    
    type: tencentcloud:DcInternetAddress
    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 DcInternetAddressArgs
    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 DcInternetAddressArgs
    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 DcInternetAddressArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DcInternetAddressArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DcInternetAddressArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    DcInternetAddress 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 DcInternetAddress resource accepts the following input properties:

    AddrProto double
    0: IPv4, 1: IPv6.
    AddrType double
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    MaskLen double
    CIDR address mask.
    DcInternetAddressId string
    ID of the resource.
    AddrProto float64
    0: IPv4, 1: IPv6.
    AddrType float64
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    MaskLen float64
    CIDR address mask.
    DcInternetAddressId string
    ID of the resource.
    addrProto Double
    0: IPv4, 1: IPv6.
    addrType Double
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    maskLen Double
    CIDR address mask.
    dcInternetAddressId String
    ID of the resource.
    addrProto number
    0: IPv4, 1: IPv6.
    addrType number
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    maskLen number
    CIDR address mask.
    dcInternetAddressId string
    ID of the resource.
    addr_proto float
    0: IPv4, 1: IPv6.
    addr_type float
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    mask_len float
    CIDR address mask.
    dc_internet_address_id str
    ID of the resource.
    addrProto Number
    0: IPv4, 1: IPv6.
    addrType Number
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    maskLen Number
    CIDR address mask.
    dcInternetAddressId String
    ID of the resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing DcInternetAddress Resource

    Get an existing DcInternetAddress 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?: DcInternetAddressState, opts?: CustomResourceOptions): DcInternetAddress
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            addr_proto: Optional[float] = None,
            addr_type: Optional[float] = None,
            dc_internet_address_id: Optional[str] = None,
            mask_len: Optional[float] = None) -> DcInternetAddress
    func GetDcInternetAddress(ctx *Context, name string, id IDInput, state *DcInternetAddressState, opts ...ResourceOption) (*DcInternetAddress, error)
    public static DcInternetAddress Get(string name, Input<string> id, DcInternetAddressState? state, CustomResourceOptions? opts = null)
    public static DcInternetAddress get(String name, Output<String> id, DcInternetAddressState state, CustomResourceOptions options)
    resources:  _:    type: tencentcloud:DcInternetAddress    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:
    AddrProto double
    0: IPv4, 1: IPv6.
    AddrType double
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    DcInternetAddressId string
    ID of the resource.
    MaskLen double
    CIDR address mask.
    AddrProto float64
    0: IPv4, 1: IPv6.
    AddrType float64
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    DcInternetAddressId string
    ID of the resource.
    MaskLen float64
    CIDR address mask.
    addrProto Double
    0: IPv4, 1: IPv6.
    addrType Double
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    dcInternetAddressId String
    ID of the resource.
    maskLen Double
    CIDR address mask.
    addrProto number
    0: IPv4, 1: IPv6.
    addrType number
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    dcInternetAddressId string
    ID of the resource.
    maskLen number
    CIDR address mask.
    addr_proto float
    0: IPv4, 1: IPv6.
    addr_type float
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    dc_internet_address_id str
    ID of the resource.
    mask_len float
    CIDR address mask.
    addrProto Number
    0: IPv4, 1: IPv6.
    addrType Number
    0: BGP, 1: china telecom, 2: china mobile, 3: china unicom.
    dcInternetAddressId String
    ID of the resource.
    maskLen Number
    CIDR address mask.

    Import

    dc internet_address can be imported using the id, e.g.

    $ pulumi import tencentcloud:index/dcInternetAddress:DcInternetAddress internet_address internet_address_id
    

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

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack