1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. kms
  5. Instance
Alibaba Cloud v3.57.1 published on Wednesday, Jun 26, 2024 by Pulumi

alicloud.kms.Instance

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.57.1 published on Wednesday, Jun 26, 2024 by Pulumi

    Provides a KMS Instance resource.

    For information about KMS Instance and how to use it, see What is Instance.

    NOTE: Available since v1.210.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 default = alicloud.vpc.getNetworks({
        nameRegex: "^default-NODELETING$",
        cidrBlock: "172.16.0.0/16",
    });
    const defaultGetSwitches = _default.then(_default => alicloud.vpc.getSwitches({
        vpcId: _default.ids?.[0],
        zoneId: "cn-hangzhou-h",
    }));
    const defaultInstance = new alicloud.kms.Instance("default", {
        productVersion: "3",
        vpcId: _default.then(_default => _default.ids?.[0]),
        zoneIds: [
            "cn-hangzhou-h",
            "cn-hangzhou-g",
        ],
        vswitchIds: [defaultGetSwitches.then(defaultGetSwitches => defaultGetSwitches.ids?.[0])],
        vpcNum: 1,
        keyNum: 1000,
        secretNum: 0,
        spec: 1000,
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    default = alicloud.vpc.get_networks(name_regex="^default-NODELETING$",
        cidr_block="172.16.0.0/16")
    default_get_switches = alicloud.vpc.get_switches(vpc_id=default.ids[0],
        zone_id="cn-hangzhou-h")
    default_instance = alicloud.kms.Instance("default",
        product_version="3",
        vpc_id=default.ids[0],
        zone_ids=[
            "cn-hangzhou-h",
            "cn-hangzhou-g",
        ],
        vswitch_ids=[default_get_switches.ids[0]],
        vpc_num=1,
        key_num=1000,
        secret_num=0,
        spec=1000)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/kms"
    	"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
    		}
    		_default, err := vpc.GetNetworks(ctx, &vpc.GetNetworksArgs{
    			NameRegex: pulumi.StringRef("^default-NODELETING$"),
    			CidrBlock: pulumi.StringRef("172.16.0.0/16"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultGetSwitches, err := vpc.GetSwitches(ctx, &vpc.GetSwitchesArgs{
    			VpcId:  pulumi.StringRef(_default.Ids[0]),
    			ZoneId: pulumi.StringRef("cn-hangzhou-h"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = kms.NewInstance(ctx, "default", &kms.InstanceArgs{
    			ProductVersion: pulumi.String("3"),
    			VpcId:          pulumi.String(_default.Ids[0]),
    			ZoneIds: pulumi.StringArray{
    				pulumi.String("cn-hangzhou-h"),
    				pulumi.String("cn-hangzhou-g"),
    			},
    			VswitchIds: pulumi.StringArray{
    				pulumi.String(defaultGetSwitches.Ids[0]),
    			},
    			VpcNum:    pulumi.Int(1),
    			KeyNum:    pulumi.Int(1000),
    			SecretNum: pulumi.Int(0),
    			Spec:      pulumi.Int(1000),
    		})
    		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 @default = AliCloud.Vpc.GetNetworks.Invoke(new()
        {
            NameRegex = "^default-NODELETING$",
            CidrBlock = "172.16.0.0/16",
        });
    
        var defaultGetSwitches = AliCloud.Vpc.GetSwitches.Invoke(new()
        {
            VpcId = @default.Apply(getNetworksResult => getNetworksResult.Ids[0]),
            ZoneId = "cn-hangzhou-h",
        });
    
        var defaultInstance = new AliCloud.Kms.Instance("default", new()
        {
            ProductVersion = "3",
            VpcId = @default.Apply(@default => @default.Apply(getNetworksResult => getNetworksResult.Ids[0])),
            ZoneIds = new[]
            {
                "cn-hangzhou-h",
                "cn-hangzhou-g",
            },
            VswitchIds = new[]
            {
                defaultGetSwitches.Apply(getSwitchesResult => getSwitchesResult.Ids[0]),
            },
            VpcNum = 1,
            KeyNum = 1000,
            SecretNum = 0,
            Spec = 1000,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.vpc.VpcFunctions;
    import com.pulumi.alicloud.vpc.inputs.GetNetworksArgs;
    import com.pulumi.alicloud.vpc.inputs.GetSwitchesArgs;
    import com.pulumi.alicloud.kms.Instance;
    import com.pulumi.alicloud.kms.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) {
            final var config = ctx.config();
            final var name = config.get("name").orElse("terraform-example");
            final var default = VpcFunctions.getNetworks(GetNetworksArgs.builder()
                .nameRegex("^default-NODELETING$")
                .cidrBlock("172.16.0.0/16")
                .build());
    
            final var defaultGetSwitches = VpcFunctions.getSwitches(GetSwitchesArgs.builder()
                .vpcId(default_.ids()[0])
                .zoneId("cn-hangzhou-h")
                .build());
    
            var defaultInstance = new Instance("defaultInstance", InstanceArgs.builder()
                .productVersion("3")
                .vpcId(default_.ids()[0])
                .zoneIds(            
                    "cn-hangzhou-h",
                    "cn-hangzhou-g")
                .vswitchIds(defaultGetSwitches.applyValue(getSwitchesResult -> getSwitchesResult.ids()[0]))
                .vpcNum("1")
                .keyNum("1000")
                .secretNum("0")
                .spec("1000")
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      defaultInstance:
        type: alicloud:kms:Instance
        name: default
        properties:
          productVersion: '3'
          vpcId: ${default.ids[0]}
          zoneIds:
            - cn-hangzhou-h
            - cn-hangzhou-g
          vswitchIds:
            - ${defaultGetSwitches.ids[0]}
          vpcNum: '1'
          keyNum: '1000'
          secretNum: '0'
          spec: '1000'
    variables:
      default:
        fn::invoke:
          Function: alicloud:vpc:getNetworks
          Arguments:
            nameRegex: ^default-NODELETING$
            cidrBlock: 172.16.0.0/16
      defaultGetSwitches:
        fn::invoke:
          Function: alicloud:vpc:getSwitches
          Arguments:
            vpcId: ${default.ids[0]}
            zoneId: cn-hangzhou-h
    

    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: InstanceArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Instance(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 vpc_id: Optional[str] = None,
                 zone_ids: Optional[Sequence[str]] = None,
                 vswitch_ids: Optional[Sequence[str]] = None,
                 log_storage: Optional[int] = None,
                 bind_vpcs: Optional[Sequence[InstanceBindVpcArgs]] = None,
                 payment_type: Optional[str] = None,
                 period: Optional[int] = None,
                 product_version: Optional[str] = None,
                 renew_period: Optional[int] = None,
                 renew_status: Optional[str] = None,
                 secret_num: Optional[int] = None,
                 spec: Optional[int] = None,
                 log: Optional[str] = None,
                 vpc_num: Optional[int] = None,
                 key_num: Optional[int] = None,
                 force_delete_without_backup: Optional[str] = None)
    func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)
    public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
    public Instance(String name, InstanceArgs args)
    public Instance(String name, InstanceArgs args, CustomResourceOptions options)
    
    type: alicloud:kms: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.

    Constructor example

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

    var exampleinstanceResourceResourceFromKmsinstance = new AliCloud.Kms.Instance("exampleinstanceResourceResourceFromKmsinstance", new()
    {
        VpcId = "string",
        ZoneIds = new[]
        {
            "string",
        },
        VswitchIds = new[]
        {
            "string",
        },
        LogStorage = 0,
        BindVpcs = new[]
        {
            new AliCloud.Kms.Inputs.InstanceBindVpcArgs
            {
                RegionId = "string",
                VpcId = "string",
                VpcOwnerId = 0,
                VswitchId = "string",
            },
        },
        PaymentType = "string",
        Period = 0,
        ProductVersion = "string",
        RenewPeriod = 0,
        RenewStatus = "string",
        SecretNum = 0,
        Spec = 0,
        Log = "string",
        VpcNum = 0,
        KeyNum = 0,
        ForceDeleteWithoutBackup = "string",
    });
    
    example, err := kms.NewInstance(ctx, "exampleinstanceResourceResourceFromKmsinstance", &kms.InstanceArgs{
    	VpcId: pulumi.String("string"),
    	ZoneIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	VswitchIds: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	LogStorage: pulumi.Int(0),
    	BindVpcs: kms.InstanceBindVpcArray{
    		&kms.InstanceBindVpcArgs{
    			RegionId:   pulumi.String("string"),
    			VpcId:      pulumi.String("string"),
    			VpcOwnerId: pulumi.Int(0),
    			VswitchId:  pulumi.String("string"),
    		},
    	},
    	PaymentType:              pulumi.String("string"),
    	Period:                   pulumi.Int(0),
    	ProductVersion:           pulumi.String("string"),
    	RenewPeriod:              pulumi.Int(0),
    	RenewStatus:              pulumi.String("string"),
    	SecretNum:                pulumi.Int(0),
    	Spec:                     pulumi.Int(0),
    	Log:                      pulumi.String("string"),
    	VpcNum:                   pulumi.Int(0),
    	KeyNum:                   pulumi.Int(0),
    	ForceDeleteWithoutBackup: pulumi.String("string"),
    })
    
    var exampleinstanceResourceResourceFromKmsinstance = new Instance("exampleinstanceResourceResourceFromKmsinstance", InstanceArgs.builder()
        .vpcId("string")
        .zoneIds("string")
        .vswitchIds("string")
        .logStorage(0)
        .bindVpcs(InstanceBindVpcArgs.builder()
            .regionId("string")
            .vpcId("string")
            .vpcOwnerId(0)
            .vswitchId("string")
            .build())
        .paymentType("string")
        .period(0)
        .productVersion("string")
        .renewPeriod(0)
        .renewStatus("string")
        .secretNum(0)
        .spec(0)
        .log("string")
        .vpcNum(0)
        .keyNum(0)
        .forceDeleteWithoutBackup("string")
        .build());
    
    exampleinstance_resource_resource_from_kmsinstance = alicloud.kms.Instance("exampleinstanceResourceResourceFromKmsinstance",
        vpc_id="string",
        zone_ids=["string"],
        vswitch_ids=["string"],
        log_storage=0,
        bind_vpcs=[alicloud.kms.InstanceBindVpcArgs(
            region_id="string",
            vpc_id="string",
            vpc_owner_id=0,
            vswitch_id="string",
        )],
        payment_type="string",
        period=0,
        product_version="string",
        renew_period=0,
        renew_status="string",
        secret_num=0,
        spec=0,
        log="string",
        vpc_num=0,
        key_num=0,
        force_delete_without_backup="string")
    
    const exampleinstanceResourceResourceFromKmsinstance = new alicloud.kms.Instance("exampleinstanceResourceResourceFromKmsinstance", {
        vpcId: "string",
        zoneIds: ["string"],
        vswitchIds: ["string"],
        logStorage: 0,
        bindVpcs: [{
            regionId: "string",
            vpcId: "string",
            vpcOwnerId: 0,
            vswitchId: "string",
        }],
        paymentType: "string",
        period: 0,
        productVersion: "string",
        renewPeriod: 0,
        renewStatus: "string",
        secretNum: 0,
        spec: 0,
        log: "string",
        vpcNum: 0,
        keyNum: 0,
        forceDeleteWithoutBackup: "string",
    });
    
    type: alicloud:kms:Instance
    properties:
        bindVpcs:
            - regionId: string
              vpcId: string
              vpcOwnerId: 0
              vswitchId: string
        forceDeleteWithoutBackup: string
        keyNum: 0
        log: string
        logStorage: 0
        paymentType: string
        period: 0
        productVersion: string
        renewPeriod: 0
        renewStatus: string
        secretNum: 0
        spec: 0
        vpcId: string
        vpcNum: 0
        vswitchIds:
            - string
        zoneIds:
            - string
    

    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:

    VpcId string
    Instance VPC id.
    VswitchIds List<string>
    Instance bind vswitches.
    ZoneIds List<string>
    zone id.
    BindVpcs List<Pulumi.AliCloud.Kms.Inputs.InstanceBindVpc>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    ForceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    KeyNum int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    Log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    LogStorage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    PaymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    Period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    ProductVersion string
    KMS Instance commodity type (software/hardware).
    RenewPeriod int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    RenewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    SecretNum int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    Spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    VpcNum int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    VpcId string
    Instance VPC id.
    VswitchIds []string
    Instance bind vswitches.
    ZoneIds []string
    zone id.
    BindVpcs []InstanceBindVpcArgs
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    ForceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    KeyNum int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    Log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    LogStorage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    PaymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    Period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    ProductVersion string
    KMS Instance commodity type (software/hardware).
    RenewPeriod int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    RenewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    SecretNum int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    Spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    VpcNum int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcId String
    Instance VPC id.
    vswitchIds List<String>
    Instance bind vswitches.
    zoneIds List<String>
    zone id.
    bindVpcs List<InstanceBindVpc>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    forceDeleteWithoutBackup String
    Whether to force deletion even without backup.
    keyNum Integer
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log String
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage Integer
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType String
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period Integer
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion String
    KMS Instance commodity type (software/hardware).
    renewPeriod Integer
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus String
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum Integer
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec Integer
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcNum Integer
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcId string
    Instance VPC id.
    vswitchIds string[]
    Instance bind vswitches.
    zoneIds string[]
    zone id.
    bindVpcs InstanceBindVpc[]
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    forceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    keyNum number
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage number
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period number
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion string
    KMS Instance commodity type (software/hardware).
    renewPeriod number
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum number
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec number
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcNum number
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpc_id str
    Instance VPC id.
    vswitch_ids Sequence[str]
    Instance bind vswitches.
    zone_ids Sequence[str]
    zone id.
    bind_vpcs Sequence[InstanceBindVpcArgs]
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    force_delete_without_backup str
    Whether to force deletion even without backup.
    key_num int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log str
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    log_storage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    payment_type str
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    product_version str
    KMS Instance commodity type (software/hardware).
    renew_period int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renew_status str
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secret_num int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpc_num int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcId String
    Instance VPC id.
    vswitchIds List<String>
    Instance bind vswitches.
    zoneIds List<String>
    zone id.
    bindVpcs List<Property Map>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    forceDeleteWithoutBackup String
    Whether to force deletion even without backup.
    keyNum Number
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log String
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage Number
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType String
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period Number
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion String
    KMS Instance commodity type (software/hardware).
    renewPeriod Number
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus String
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum Number
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec Number
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vpcNum Number
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.

    Outputs

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

    CaCertificateChainPem string
    KMS instance certificate chain in PEM format.
    CreateTime string
    The creation time of the resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceName string
    The name of the resource.
    Status string
    Instance status.
    CaCertificateChainPem string
    KMS instance certificate chain in PEM format.
    CreateTime string
    The creation time of the resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    InstanceName string
    The name of the resource.
    Status string
    Instance status.
    caCertificateChainPem String
    KMS instance certificate chain in PEM format.
    createTime String
    The creation time of the resource.
    id String
    The provider-assigned unique ID for this managed resource.
    instanceName String
    The name of the resource.
    status String
    Instance status.
    caCertificateChainPem string
    KMS instance certificate chain in PEM format.
    createTime string
    The creation time of the resource.
    id string
    The provider-assigned unique ID for this managed resource.
    instanceName string
    The name of the resource.
    status string
    Instance status.
    ca_certificate_chain_pem str
    KMS instance certificate chain in PEM format.
    create_time str
    The creation time of the resource.
    id str
    The provider-assigned unique ID for this managed resource.
    instance_name str
    The name of the resource.
    status str
    Instance status.
    caCertificateChainPem String
    KMS instance certificate chain in PEM format.
    createTime String
    The creation time of the resource.
    id String
    The provider-assigned unique ID for this managed resource.
    instanceName String
    The name of the resource.
    status String
    Instance 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,
            bind_vpcs: Optional[Sequence[InstanceBindVpcArgs]] = None,
            ca_certificate_chain_pem: Optional[str] = None,
            create_time: Optional[str] = None,
            force_delete_without_backup: Optional[str] = None,
            instance_name: Optional[str] = None,
            key_num: Optional[int] = None,
            log: Optional[str] = None,
            log_storage: Optional[int] = None,
            payment_type: Optional[str] = None,
            period: Optional[int] = None,
            product_version: Optional[str] = None,
            renew_period: Optional[int] = None,
            renew_status: Optional[str] = None,
            secret_num: Optional[int] = None,
            spec: Optional[int] = None,
            status: Optional[str] = None,
            vpc_id: Optional[str] = None,
            vpc_num: Optional[int] = None,
            vswitch_ids: Optional[Sequence[str]] = None,
            zone_ids: Optional[Sequence[str]] = 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:
    BindVpcs List<Pulumi.AliCloud.Kms.Inputs.InstanceBindVpc>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    CaCertificateChainPem string
    KMS instance certificate chain in PEM format.
    CreateTime string
    The creation time of the resource.
    ForceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    InstanceName string
    The name of the resource.
    KeyNum int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    Log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    LogStorage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    PaymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    Period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    ProductVersion string
    KMS Instance commodity type (software/hardware).
    RenewPeriod int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    RenewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    SecretNum int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    Spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    Status string
    Instance status.
    VpcId string
    Instance VPC id.
    VpcNum int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    VswitchIds List<string>
    Instance bind vswitches.
    ZoneIds List<string>
    zone id.
    BindVpcs []InstanceBindVpcArgs
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    CaCertificateChainPem string
    KMS instance certificate chain in PEM format.
    CreateTime string
    The creation time of the resource.
    ForceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    InstanceName string
    The name of the resource.
    KeyNum int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    Log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    LogStorage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    PaymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    Period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    ProductVersion string
    KMS Instance commodity type (software/hardware).
    RenewPeriod int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    RenewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    SecretNum int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    Spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    Status string
    Instance status.
    VpcId string
    Instance VPC id.
    VpcNum int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    VswitchIds []string
    Instance bind vswitches.
    ZoneIds []string
    zone id.
    bindVpcs List<InstanceBindVpc>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    caCertificateChainPem String
    KMS instance certificate chain in PEM format.
    createTime String
    The creation time of the resource.
    forceDeleteWithoutBackup String
    Whether to force deletion even without backup.
    instanceName String
    The name of the resource.
    keyNum Integer
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log String
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage Integer
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType String
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period Integer
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion String
    KMS Instance commodity type (software/hardware).
    renewPeriod Integer
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus String
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum Integer
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec Integer
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    status String
    Instance status.
    vpcId String
    Instance VPC id.
    vpcNum Integer
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vswitchIds List<String>
    Instance bind vswitches.
    zoneIds List<String>
    zone id.
    bindVpcs InstanceBindVpc[]
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    caCertificateChainPem string
    KMS instance certificate chain in PEM format.
    createTime string
    The creation time of the resource.
    forceDeleteWithoutBackup string
    Whether to force deletion even without backup.
    instanceName string
    The name of the resource.
    keyNum number
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log string
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage number
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType string
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period number
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion string
    KMS Instance commodity type (software/hardware).
    renewPeriod number
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus string
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum number
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec number
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    status string
    Instance status.
    vpcId string
    Instance VPC id.
    vpcNum number
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vswitchIds string[]
    Instance bind vswitches.
    zoneIds string[]
    zone id.
    bind_vpcs Sequence[InstanceBindVpcArgs]
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    ca_certificate_chain_pem str
    KMS instance certificate chain in PEM format.
    create_time str
    The creation time of the resource.
    force_delete_without_backup str
    Whether to force deletion even without backup.
    instance_name str
    The name of the resource.
    key_num int
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log str
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    log_storage int
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    payment_type str
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period int
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    product_version str
    KMS Instance commodity type (software/hardware).
    renew_period int
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renew_status str
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secret_num int
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec int
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    status str
    Instance status.
    vpc_id str
    Instance VPC id.
    vpc_num int
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vswitch_ids Sequence[str]
    Instance bind vswitches.
    zone_ids Sequence[str]
    zone id.
    bindVpcs List<Property Map>
    Aucillary VPCs used to access this KMS instance. See bind_vpcs below.
    caCertificateChainPem String
    KMS instance certificate chain in PEM format.
    createTime String
    The creation time of the resource.
    forceDeleteWithoutBackup String
    Whether to force deletion even without backup.
    instanceName String
    The name of the resource.
    keyNum Number
    Maximum number of stored keys. The attribute is valid when the attribute payment_type is Subscription.
    log String
    Instance Audit Log Switch. The attribute is valid when the attribute payment_type is Subscription.
    logStorage Number
    Instance log capacity. The attribute is valid when the attribute payment_type is Subscription.
    paymentType String
    Payment type, valid values: Subscription: Prepaid. PayAsYouGo: Postpaid, available since v1.223.2.
    period Number
    Purchase cycle, in months. The attribute is valid when the attribute payment_type is Subscription.
    productVersion String
    KMS Instance commodity type (software/hardware).
    renewPeriod Number
    Automatic renewal period, in months. The attribute is valid when the attribute payment_type is Subscription.
    renewStatus String
    Renewal options. Valid values: AutoRenewal, ManualRenewal. The attribute is valid when the attribute payment_type is Subscription.
    secretNum Number
    Maximum number of Secrets. The attribute is valid when the attribute payment_type is Subscription.
    spec Number
    The computation performance level of the KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    status String
    Instance status.
    vpcId String
    Instance VPC id.
    vpcNum Number
    The number of managed accesses. The maximum number of VPCs that can access this KMS instance. The attribute is valid when the attribute payment_type is Subscription.
    vswitchIds List<String>
    Instance bind vswitches.
    zoneIds List<String>
    zone id.

    Supporting Types

    InstanceBindVpc, InstanceBindVpcArgs

    RegionId string
    region id.
    VpcId string
    VPC ID.
    VpcOwnerId int
    VPC owner root user ID.
    VswitchId string
    vswitch id.
    RegionId string
    region id.
    VpcId string
    VPC ID.
    VpcOwnerId int
    VPC owner root user ID.
    VswitchId string
    vswitch id.
    regionId String
    region id.
    vpcId String
    VPC ID.
    vpcOwnerId Integer
    VPC owner root user ID.
    vswitchId String
    vswitch id.
    regionId string
    region id.
    vpcId string
    VPC ID.
    vpcOwnerId number
    VPC owner root user ID.
    vswitchId string
    vswitch id.
    region_id str
    region id.
    vpc_id str
    VPC ID.
    vpc_owner_id int
    VPC owner root user ID.
    vswitch_id str
    vswitch id.
    regionId String
    region id.
    vpcId String
    VPC ID.
    vpcOwnerId Number
    VPC owner root user ID.
    vswitchId String
    vswitch id.

    Import

    KMS Instance can be imported using the id, e.g.

    $ pulumi import alicloud:kms/instance:Instance example <id>
    

    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.57.1 published on Wednesday, Jun 26, 2024 by Pulumi