Viewing docs for AWS v7.52.1
published on Wednesday, Oct 28, 2026 by Pulumi
published on Wednesday, Oct 28, 2026 by Pulumi
Viewing docs for AWS v7.52.1
published on Wednesday, Oct 28, 2026 by Pulumi
published on Wednesday, Oct 28, 2026 by Pulumi
Use this data source to get the metadata KMS custom key store. By using this data source, you can reference KMS custom key store without having to hard code the ID as input.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const keystore = aws.kms.getCustomKeyStore({
customKeyStoreName: "my_cloudhsm",
});
import pulumi
import pulumi_aws as aws
keystore = aws.kms.get_custom_key_store(custom_key_store_name="my_cloudhsm")
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/kms"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := kms.LookupCustomKeyStore(ctx, &kms.LookupCustomKeyStoreArgs{
CustomKeyStoreName: pulumi.StringRef("my_cloudhsm"),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var keystore = Aws.Kms.GetCustomKeyStore.Invoke(new()
{
CustomKeyStoreName = "my_cloudhsm",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.kms.KmsFunctions;
import com.pulumi.aws.kms.inputs.GetCustomKeyStoreArgs;
import java.util.ArrayList;
import java.util.Arrays;
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 keystore = KmsFunctions.getCustomKeyStore(GetCustomKeyStoreArgs.builder()
.customKeyStoreName("my_cloudhsm")
.build());
}
}
variables:
keystore:
fn::invoke:
function: aws:kms:getCustomKeyStore
arguments:
customKeyStoreName: my_cloudhsm
terraform {
required_providers {
aws = {
source = "pulumi/aws"
}
}
}
data "aws_kms_custom_key_store" "keystore" {
custom_key_store_name = "my_cloudhsm"
}
Using getCustomKeyStore
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getCustomKeyStore(args: GetCustomKeyStoreArgs, opts?: InvokeOptions): Promise<GetCustomKeyStoreResult>
function getCustomKeyStoreOutput(args: GetCustomKeyStoreOutputArgs, opts?: InvokeOutputOptions): Output<GetCustomKeyStoreResult>def get_custom_key_store(custom_key_store_id: Optional[str] = None,
custom_key_store_name: Optional[str] = None,
region: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetCustomKeyStoreResult
def get_custom_key_store_output(custom_key_store_id: pulumi.Input[Optional[str]] = None,
custom_key_store_name: pulumi.Input[Optional[str]] = None,
region: pulumi.Input[Optional[str]] = None,
opts: Optional[InvokeOutputOptions] = None) -> Output[GetCustomKeyStoreResult]func LookupCustomKeyStore(ctx *Context, args *LookupCustomKeyStoreArgs, opts ...InvokeOption) (*LookupCustomKeyStoreResult, error)
func LookupCustomKeyStoreOutput(ctx *Context, args *LookupCustomKeyStoreOutputArgs, opts ...InvokeOption) LookupCustomKeyStoreResultOutput> Note: This function is named LookupCustomKeyStore in the Go SDK.
public static class GetCustomKeyStore
{
public static Task<GetCustomKeyStoreResult> InvokeAsync(GetCustomKeyStoreArgs args, InvokeOptions? opts = null)
public static Output<GetCustomKeyStoreResult> Invoke(GetCustomKeyStoreInvokeArgs args, InvokeOptions? opts = null)
public static Output<GetCustomKeyStoreResult> Invoke(GetCustomKeyStoreInvokeArgs args, InvokeOutputOptions opts)
}public static CompletableFuture<GetCustomKeyStoreResult> getCustomKeyStore(GetCustomKeyStoreArgs args, InvokeOptions options)
public static Output<GetCustomKeyStoreResult> getCustomKeyStore(GetCustomKeyStoreArgs args, InvokeOptions options)
public static Output<GetCustomKeyStoreResult> getCustomKeyStore(GetCustomKeyStoreArgs args, InvokeOutputOptions options)
fn::invoke:
function: aws:kms/getCustomKeyStore:getCustomKeyStore
arguments:
# arguments dictionarydata "aws_kms_get_custom_key_store" "name" {
# arguments
}The following arguments are supported:
- Custom
Key stringStore Id - ID for the custom key store.
- Custom
Key stringStore Name - User-specified friendly name for the custom key store.
- Region string
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- Custom
Key stringStore Id - ID for the custom key store.
- Custom
Key stringStore Name - User-specified friendly name for the custom key store.
- Region string
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- custom_
key_ stringstore_ id - ID for the custom key store.
- custom_
key_ stringstore_ name - User-specified friendly name for the custom key store.
- region string
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- custom
Key StringStore Id - ID for the custom key store.
- custom
Key StringStore Name - User-specified friendly name for the custom key store.
- region String
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- custom
Key stringStore Id - ID for the custom key store.
- custom
Key stringStore Name - User-specified friendly name for the custom key store.
- region string
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- custom_
key_ strstore_ id - ID for the custom key store.
- custom_
key_ strstore_ name - User-specified friendly name for the custom key store.
- region str
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
- custom
Key StringStore Id - ID for the custom key store.
- custom
Key StringStore Name - User-specified friendly name for the custom key store.
- region String
- Region where this resource will be managed. Defaults to the Region set in the provider configuration.
getCustomKeyStore Result
The following output properties are available:
- Cloud
Hsm stringCluster Id - ID for the CloudHSM cluster that is associated with the custom key store.
- Connection
State string - Whether the custom key store is connected to its CloudHSM cluster.
- Creation
Date string - Date and time when the custom key store was created.
- Custom
Key stringStore Id - Custom
Key stringStore Name - Id string
- The provider-assigned unique ID for this managed resource.
- Region string
- Trust
Anchor stringCertificate - Trust anchor certificate of the associated CloudHSM cluster.
- Cloud
Hsm stringCluster Id - ID for the CloudHSM cluster that is associated with the custom key store.
- Connection
State string - Whether the custom key store is connected to its CloudHSM cluster.
- Creation
Date string - Date and time when the custom key store was created.
- Custom
Key stringStore Id - Custom
Key stringStore Name - Id string
- The provider-assigned unique ID for this managed resource.
- Region string
- Trust
Anchor stringCertificate - Trust anchor certificate of the associated CloudHSM cluster.
- cloud_
hsm_ stringcluster_ id - ID for the CloudHSM cluster that is associated with the custom key store.
- connection_
state string - Whether the custom key store is connected to its CloudHSM cluster.
- creation_
date string - Date and time when the custom key store was created.
- custom_
key_ stringstore_ id - custom_
key_ stringstore_ name - id string
- The provider-assigned unique ID for this managed resource.
- region string
- trust_
anchor_ stringcertificate - Trust anchor certificate of the associated CloudHSM cluster.
- cloud
Hsm StringCluster Id - ID for the CloudHSM cluster that is associated with the custom key store.
- connection
State String - Whether the custom key store is connected to its CloudHSM cluster.
- creation
Date String - Date and time when the custom key store was created.
- custom
Key StringStore Id - custom
Key StringStore Name - id String
- The provider-assigned unique ID for this managed resource.
- region String
- trust
Anchor StringCertificate - Trust anchor certificate of the associated CloudHSM cluster.
- cloud
Hsm stringCluster Id - ID for the CloudHSM cluster that is associated with the custom key store.
- connection
State string - Whether the custom key store is connected to its CloudHSM cluster.
- creation
Date string - Date and time when the custom key store was created.
- custom
Key stringStore Id - custom
Key stringStore Name - id string
- The provider-assigned unique ID for this managed resource.
- region string
- trust
Anchor stringCertificate - Trust anchor certificate of the associated CloudHSM cluster.
- cloud_
hsm_ strcluster_ id - ID for the CloudHSM cluster that is associated with the custom key store.
- connection_
state str - Whether the custom key store is connected to its CloudHSM cluster.
- creation_
date str - Date and time when the custom key store was created.
- custom_
key_ strstore_ id - custom_
key_ strstore_ name - id str
- The provider-assigned unique ID for this managed resource.
- region str
- trust_
anchor_ strcertificate - Trust anchor certificate of the associated CloudHSM cluster.
- cloud
Hsm StringCluster Id - ID for the CloudHSM cluster that is associated with the custom key store.
- connection
State String - Whether the custom key store is connected to its CloudHSM cluster.
- creation
Date String - Date and time when the custom key store was created.
- custom
Key StringStore Id - custom
Key StringStore Name - id String
- The provider-assigned unique ID for this managed resource.
- region String
- trust
Anchor StringCertificate - Trust anchor certificate of the associated CloudHSM cluster.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
awsTerraform Provider.
Viewing docs for AWS v7.52.1
published on Wednesday, Oct 28, 2026 by Pulumi
published on Wednesday, Oct 28, 2026 by Pulumi