1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. cen
  5. Instance
Alibaba Cloud v3.53.0 published on Wednesday, Apr 17, 2024 by Pulumi

alicloud.cen.Instance

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.53.0 published on Wednesday, Apr 17, 2024 by Pulumi

    Provides a CEN instance resource. Cloud Enterprise Network (CEN) is a service that allows you to create a global network for rapidly building a distributed business system with a hybrid cloud computing solution. CEN enables you to build a secure, private, and enterprise-class interconnected network between VPCs in different regions and your local data centers. CEN provides enterprise-class scalability that automatically responds to your dynamic computing requirements.

    For information about CEN and how to use it, see What is Cloud Enterprise Network.

    NOTE: Available since v1.15.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const example = new alicloud.cen.Instance("example", {
        cenInstanceName: "tf_example",
        description: "an example for cen",
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    example = alicloud.cen.Instance("example",
        cen_instance_name="tf_example",
        description="an example for cen")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cen"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cen.NewInstance(ctx, "example", &cen.InstanceArgs{
    			CenInstanceName: pulumi.String("tf_example"),
    			Description:     pulumi.String("an example for cen"),
    		})
    		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 example = new AliCloud.Cen.Instance("example", new()
        {
            CenInstanceName = "tf_example",
            Description = "an example for cen",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.cen.Instance;
    import com.pulumi.alicloud.cen.InstanceArgs;
    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 example = new Instance("example", InstanceArgs.builder()        
                .cenInstanceName("tf_example")
                .description("an example for cen")
                .build());
    
        }
    }
    
    resources:
      example:
        type: alicloud:cen:Instance
        properties:
          cenInstanceName: tf_example
          description: an example for cen
    

    Create Instance Resource

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

    Constructor syntax

    new Instance(name: string, args?: InstanceArgs, opts?: CustomResourceOptions);
    @overload
    def Instance(resource_name: str,
                 args: Optional[InstanceArgs] = None,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Instance(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 cen_instance_name: Optional[str] = None,
                 description: Optional[str] = None,
                 name: Optional[str] = None,
                 protection_level: Optional[str] = None,
                 tags: Optional[Mapping[str, Any]] = None)
    func NewInstance(ctx *Context, name string, args *InstanceArgs, opts ...ResourceOption) (*Instance, error)
    public Instance(string name, InstanceArgs? args = null, CustomResourceOptions? opts = null)
    public Instance(String name, InstanceArgs args)
    public Instance(String name, InstanceArgs args, CustomResourceOptions options)
    
    type: alicloud:cen:Instance
    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 InstanceArgs
    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 InstanceArgs
    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 InstanceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args InstanceArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

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

    var exampleinstanceResourceResourceFromCeninstance = new AliCloud.Cen.Instance("exampleinstanceResourceResourceFromCeninstance", new()
    {
        CenInstanceName = "string",
        Description = "string",
        ProtectionLevel = "string",
        Tags = 
        {
            { "string", "any" },
        },
    });
    
    example, err := cen.NewInstance(ctx, "exampleinstanceResourceResourceFromCeninstance", &cen.InstanceArgs{
    	CenInstanceName: pulumi.String("string"),
    	Description:     pulumi.String("string"),
    	ProtectionLevel: pulumi.String("string"),
    	Tags: pulumi.Map{
    		"string": pulumi.Any("any"),
    	},
    })
    
    var exampleinstanceResourceResourceFromCeninstance = new Instance("exampleinstanceResourceResourceFromCeninstance", InstanceArgs.builder()        
        .cenInstanceName("string")
        .description("string")
        .protectionLevel("string")
        .tags(Map.of("string", "any"))
        .build());
    
    exampleinstance_resource_resource_from_ceninstance = alicloud.cen.Instance("exampleinstanceResourceResourceFromCeninstance",
        cen_instance_name="string",
        description="string",
        protection_level="string",
        tags={
            "string": "any",
        })
    
    const exampleinstanceResourceResourceFromCeninstance = new alicloud.cen.Instance("exampleinstanceResourceResourceFromCeninstance", {
        cenInstanceName: "string",
        description: "string",
        protectionLevel: "string",
        tags: {
            string: "any",
        },
    });
    
    type: alicloud:cen:Instance
    properties:
        cenInstanceName: string
        description: string
        protectionLevel: string
        tags:
            string: any
    

    Instance Resource Properties

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

    Inputs

    The Instance resource accepts the following input properties:

    CenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    Description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    Name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    ProtectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    Tags Dictionary<string, object>
    A mapping of tags to assign to the resource.
    CenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    Description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    Name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    ProtectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    Tags map[string]interface{}
    A mapping of tags to assign to the resource.
    cenInstanceName String
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description String
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name String
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel String
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    tags Map<String,Object>
    A mapping of tags to assign to the resource.
    cenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    tags {[key: string]: any}
    A mapping of tags to assign to the resource.
    cen_instance_name str
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description str
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name str
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protection_level str
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    tags Mapping[str, Any]
    A mapping of tags to assign to the resource.
    cenInstanceName String
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description String
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name String
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel String
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    tags Map<Any>
    A mapping of tags to assign to the resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    The Cen Instance current status.
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    The Cen Instance current status.
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    The Cen Instance current status.
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    The Cen Instance current status.
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    The Cen Instance current status.
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    The Cen Instance current status.

    Look up Existing Instance Resource

    Get an existing Instance 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?: InstanceState, opts?: CustomResourceOptions): Instance
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cen_instance_name: Optional[str] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            protection_level: Optional[str] = None,
            status: Optional[str] = None,
            tags: Optional[Mapping[str, Any]] = None) -> Instance
    func GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)
    public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)
    public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    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:
    CenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    Description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    Name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    ProtectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    Status string
    The Cen Instance current status.
    Tags Dictionary<string, object>
    A mapping of tags to assign to the resource.
    CenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    Description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    Name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    ProtectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    Status string
    The Cen Instance current status.
    Tags map[string]interface{}
    A mapping of tags to assign to the resource.
    cenInstanceName String
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description String
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name String
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel String
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    status String
    The Cen Instance current status.
    tags Map<String,Object>
    A mapping of tags to assign to the resource.
    cenInstanceName string
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description string
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name string
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel string
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    status string
    The Cen Instance current status.
    tags {[key: string]: any}
    A mapping of tags to assign to the resource.
    cen_instance_name str
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description str
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name str
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protection_level str
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    status str
    The Cen Instance current status.
    tags Mapping[str, Any]
    A mapping of tags to assign to the resource.
    cenInstanceName String
    The name of the CEN instance. Defaults to null. The name must be 2 to 128 characters in length and can contain letters, numbers, periods (.), underscores (_), and hyphens (-). The name must start with a letter, but cannot start with http:// or https://.
    description String
    The description of the CEN instance. Defaults to null. The description must be 2 to 256 characters in length. It must start with a letter, and cannot start with http:// or https://.
    name String
    Field name has been deprecated from version 1.98.0. Use cen_instance_name instead.

    Deprecated: attribute 'name' has been deprecated from version 1.98.0. Use 'cen_instance_name' instead.

    protectionLevel String
    Indicates the allowed level of CIDR block overlapping. Default value: REDUCE: Overlapping CIDR blocks are allowed. However, the overlapping CIDR blocks cannot be identical.
    status String
    The Cen Instance current status.
    tags Map<Any>
    A mapping of tags to assign to the resource.

    Import

    CEN instance can be imported using the id, e.g.

    $ pulumi import alicloud:cen/instance:Instance example cen-abc123456
    

    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.53.0 published on Wednesday, Apr 17, 2024 by Pulumi