UNPKG

@pulumi/aws-native

Version:

The Pulumi AWS Cloud Control Provider enables you to build, deploy, and manage [any AWS resource that's supported by the AWS Cloud Control API](https://github.com/pulumi/pulumi-aws-native/blob/master/provider/cmd/pulumi-gen-aws-native/supported-types.txt)

54 lines (53 loc) 3.7 kB
import * as pulumi from "@pulumi/pulumi"; /** * Specifies a key pair for use with an EC2long instance as follows: * + To import an existing key pair, include the ``PublicKeyMaterial`` property. * + To create a new key pair, omit the ``PublicKeyMaterial`` property. * * When you import an existing key pair, you specify the public key material for the key. We assume that you have the private key material for the key. CFNlong does not create or return the private key material when you import a key pair. * When you create a new key pair, the private key is saved to SYSlong Parameter Store, using a parameter with the following name: ``/ec2/keypair/{key_pair_id}``. For more information about retrieving private key, and the required permissions, see [Create a key pair using](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/create-key-pairs.html#create-key-pair-cloudformation) in the *User Guide*. * When CFN deletes a key pair that was created or imported by a stack, it also deletes the parameter that was used to store the private key material in Parameter Store. */ export declare function getKeyPair(args: GetKeyPairArgs, opts?: pulumi.InvokeOptions): Promise<GetKeyPairResult>; export interface GetKeyPairArgs { /** * A unique name for the key pair. * Constraints: Up to 255 ASCII characters */ keyName: string; } export interface GetKeyPairResult { /** * If you created the key pair using Amazon EC2: * * - For RSA key pairs, the key fingerprint is the SHA-1 digest of the DER encoded private key. * - For ED25519 key pairs, the key fingerprint is the base64-encoded SHA-256 digest, which is the default for OpenSSH, starting with [OpenSSH 6.8](https://docs.aws.amazon.com/http://www.openssh.com/txt/release-6.8) . * * If you imported the key pair to Amazon EC2: * * - For RSA key pairs, the key fingerprint is the MD5 public key fingerprint as specified in section 4 of RFC 4716. * - For ED25519 key pairs, the key fingerprint is the base64-encoded SHA-256 digest, which is the default for OpenSSH, starting with [OpenSSH 6.8](https://docs.aws.amazon.com/http://www.openssh.com/txt/release-6.8) . */ readonly keyFingerprint?: string; /** * The ID of the key pair. */ readonly keyPairId?: string; } /** * Specifies a key pair for use with an EC2long instance as follows: * + To import an existing key pair, include the ``PublicKeyMaterial`` property. * + To create a new key pair, omit the ``PublicKeyMaterial`` property. * * When you import an existing key pair, you specify the public key material for the key. We assume that you have the private key material for the key. CFNlong does not create or return the private key material when you import a key pair. * When you create a new key pair, the private key is saved to SYSlong Parameter Store, using a parameter with the following name: ``/ec2/keypair/{key_pair_id}``. For more information about retrieving private key, and the required permissions, see [Create a key pair using](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/create-key-pairs.html#create-key-pair-cloudformation) in the *User Guide*. * When CFN deletes a key pair that was created or imported by a stack, it also deletes the parameter that was used to store the private key material in Parameter Store. */ export declare function getKeyPairOutput(args: GetKeyPairOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetKeyPairResult>; export interface GetKeyPairOutputArgs { /** * A unique name for the key pair. * Constraints: Up to 255 ASCII characters */ keyName: pulumi.Input<string>; }