tencentcloud.KmsWhiteBoxKey
Explore with Pulumi AI
Provides a resource to create a kms white_box_key
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.KmsWhiteBoxKey("example", {
algorithm: "SM4",
alias: "tf_example",
description: "test desc.",
status: "Enabled",
tags: {
createdBy: "terraform",
},
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.KmsWhiteBoxKey("example",
algorithm="SM4",
alias="tf_example",
description="test desc.",
status="Enabled",
tags={
"createdBy": "terraform",
})
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.NewKmsWhiteBoxKey(ctx, "example", &tencentcloud.KmsWhiteBoxKeyArgs{
Algorithm: pulumi.String("SM4"),
Alias: pulumi.String("tf_example"),
Description: pulumi.String("test desc."),
Status: pulumi.String("Enabled"),
Tags: pulumi.StringMap{
"createdBy": pulumi.String("terraform"),
},
})
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 example = new Tencentcloud.KmsWhiteBoxKey("example", new()
{
Algorithm = "SM4",
Alias = "tf_example",
Description = "test desc.",
Status = "Enabled",
Tags =
{
{ "createdBy", "terraform" },
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.KmsWhiteBoxKey;
import com.pulumi.tencentcloud.KmsWhiteBoxKeyArgs;
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 KmsWhiteBoxKey("example", KmsWhiteBoxKeyArgs.builder()
.algorithm("SM4")
.alias("tf_example")
.description("test desc.")
.status("Enabled")
.tags(Map.of("createdBy", "terraform"))
.build());
}
}
resources:
example:
type: tencentcloud:KmsWhiteBoxKey
properties:
algorithm: SM4
alias: tf_example
description: test desc.
status: Enabled
tags:
createdBy: terraform
Create KmsWhiteBoxKey Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new KmsWhiteBoxKey(name: string, args: KmsWhiteBoxKeyArgs, opts?: CustomResourceOptions);
@overload
def KmsWhiteBoxKey(resource_name: str,
args: KmsWhiteBoxKeyArgs,
opts: Optional[ResourceOptions] = None)
@overload
def KmsWhiteBoxKey(resource_name: str,
opts: Optional[ResourceOptions] = None,
algorithm: Optional[str] = None,
alias: Optional[str] = None,
description: Optional[str] = None,
kms_white_box_key_id: Optional[str] = None,
status: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewKmsWhiteBoxKey(ctx *Context, name string, args KmsWhiteBoxKeyArgs, opts ...ResourceOption) (*KmsWhiteBoxKey, error)
public KmsWhiteBoxKey(string name, KmsWhiteBoxKeyArgs args, CustomResourceOptions? opts = null)
public KmsWhiteBoxKey(String name, KmsWhiteBoxKeyArgs args)
public KmsWhiteBoxKey(String name, KmsWhiteBoxKeyArgs args, CustomResourceOptions options)
type: tencentcloud:KmsWhiteBoxKey
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 KmsWhiteBoxKeyArgs
- 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 KmsWhiteBoxKeyArgs
- 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 KmsWhiteBoxKeyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args KmsWhiteBoxKeyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args KmsWhiteBoxKeyArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
KmsWhiteBoxKey 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 KmsWhiteBoxKey resource accepts the following input properties:
- Algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- Alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- Description string
- Description of the key, up to 1024 bytes.
- Kms
White stringBox Key Id - ID of the resource.
- Status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Dictionary<string, string>
- The tags of Key.
- Algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- Alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- Description string
- Description of the key, up to 1024 bytes.
- Kms
White stringBox Key Id - ID of the resource.
- Status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- map[string]string
- The tags of Key.
- algorithm String
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias String
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description String
- Description of the key, up to 1024 bytes.
- kms
White StringBox Key Id - ID of the resource.
- status String
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Map<String,String>
- The tags of Key.
- algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description string
- Description of the key, up to 1024 bytes.
- kms
White stringBox Key Id - ID of the resource.
- status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- {[key: string]: string}
- The tags of Key.
- algorithm str
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias str
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description str
- Description of the key, up to 1024 bytes.
- kms_
white_ strbox_ key_ id - ID of the resource.
- status str
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Mapping[str, str]
- The tags of Key.
- algorithm String
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias String
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description String
- Description of the key, up to 1024 bytes.
- kms
White StringBox Key Id - ID of the resource.
- status String
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Map<String>
- The tags of Key.
Outputs
All input properties are implicitly available as output properties. Additionally, the KmsWhiteBoxKey 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 KmsWhiteBoxKey Resource
Get an existing KmsWhiteBoxKey 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?: KmsWhiteBoxKeyState, opts?: CustomResourceOptions): KmsWhiteBoxKey
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
algorithm: Optional[str] = None,
alias: Optional[str] = None,
description: Optional[str] = None,
kms_white_box_key_id: Optional[str] = None,
status: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None) -> KmsWhiteBoxKey
func GetKmsWhiteBoxKey(ctx *Context, name string, id IDInput, state *KmsWhiteBoxKeyState, opts ...ResourceOption) (*KmsWhiteBoxKey, error)
public static KmsWhiteBoxKey Get(string name, Input<string> id, KmsWhiteBoxKeyState? state, CustomResourceOptions? opts = null)
public static KmsWhiteBoxKey get(String name, Output<String> id, KmsWhiteBoxKeyState state, CustomResourceOptions options)
resources: _: type: tencentcloud:KmsWhiteBoxKey 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.
- Algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- Alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- Description string
- Description of the key, up to 1024 bytes.
- Kms
White stringBox Key Id - ID of the resource.
- Status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Dictionary<string, string>
- The tags of Key.
- Algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- Alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- Description string
- Description of the key, up to 1024 bytes.
- Kms
White stringBox Key Id - ID of the resource.
- Status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- map[string]string
- The tags of Key.
- algorithm String
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias String
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description String
- Description of the key, up to 1024 bytes.
- kms
White StringBox Key Id - ID of the resource.
- status String
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Map<String,String>
- The tags of Key.
- algorithm string
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias string
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description string
- Description of the key, up to 1024 bytes.
- kms
White stringBox Key Id - ID of the resource.
- status string
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- {[key: string]: string}
- The tags of Key.
- algorithm str
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias str
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description str
- Description of the key, up to 1024 bytes.
- kms_
white_ strbox_ key_ id - ID of the resource.
- status str
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Mapping[str, str]
- The tags of Key.
- algorithm String
- All algorithm types for creating keys, supported values: AES_256, SM4.
- alias String
- As an alias for the key to be easier to identify and easier to understand, it cannot be empty and is a combination of 1-60 alphanumeric characters - _. The first character must be a letter or number. Alias are not repeatable.
- description String
- Description of the key, up to 1024 bytes.
- kms
White StringBox Key Id - ID of the resource.
- status String
- Whether to enable the key. Enabled or Disabled. Default is Enabled.
- Map<String>
- The tags of Key.
Import
kms white_box_key can be imported using the id, e.g.
$ pulumi import tencentcloud:index/kmsWhiteBoxKey:KmsWhiteBoxKey example 244dab8c-6dad-11ea-80c6-5254006d0810
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.