UNPKG

@pulumi/aws

Version:

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

134 lines (133 loc) 5.94 kB
import * as pulumi from "@pulumi/pulumi"; /** * ## Example Usage * * The following example below creates a CloudFront public key. * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * import * as std from "@pulumi/std"; * * const example = new aws.cloudfront.PublicKey("example", { * comment: "test public key", * encodedKey: std.file({ * input: "public_key.pem", * }).then(invoke => invoke.result), * name: "test_key", * }); * ``` * * ## Import * * Using `pulumi import`, import CloudFront Public Key using the `id`. For example: * * ```sh * $ pulumi import aws:cloudfront/publicKey:PublicKey example K3D5EWEUDCCXON * ``` */ export declare class PublicKey extends pulumi.CustomResource { /** * Get an existing PublicKey resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: PublicKeyState, opts?: pulumi.CustomResourceOptions): PublicKey; /** * Returns true if the given object is an instance of PublicKey. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is PublicKey; /** * Internal value used by CloudFront to allow future updates to the public key configuration. */ readonly callerReference: pulumi.Output<string>; /** * An optional comment about the public key. */ readonly comment: pulumi.Output<string | undefined>; /** * The encoded public key that you want to add to CloudFront to use with features like field-level encryption. */ readonly encodedKey: pulumi.Output<string>; /** * The current version of the public key. For example: `E2QWRUHAPOMQZL`. */ readonly etag: pulumi.Output<string>; /** * The name for the public key. By default generated by this provider. Note: Do not set if using the key's id in another resource (e.g. KeyGroup) since it will result in a dependency error from AWS. Instead, it is recommended to use Pulumi autonaming by leaving this property unset (default behavior) or set the `namePrefix` property to allow the provider to autoname the resource. */ readonly name: pulumi.Output<string>; /** * The name for the public key. Conflicts with `name`. * * **NOTE:** When setting `encodedKey` value, there needs a newline at the end of string. Otherwise, multiple runs of pulumi will want to recreate the `aws.cloudfront.PublicKey` resource. */ readonly namePrefix: pulumi.Output<string>; /** * Create a PublicKey resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: PublicKeyArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering PublicKey resources. */ export interface PublicKeyState { /** * Internal value used by CloudFront to allow future updates to the public key configuration. */ callerReference?: pulumi.Input<string>; /** * An optional comment about the public key. */ comment?: pulumi.Input<string>; /** * The encoded public key that you want to add to CloudFront to use with features like field-level encryption. */ encodedKey?: pulumi.Input<string>; /** * The current version of the public key. For example: `E2QWRUHAPOMQZL`. */ etag?: pulumi.Input<string>; /** * The name for the public key. By default generated by this provider. Note: Do not set if using the key's id in another resource (e.g. KeyGroup) since it will result in a dependency error from AWS. Instead, it is recommended to use Pulumi autonaming by leaving this property unset (default behavior) or set the `namePrefix` property to allow the provider to autoname the resource. */ name?: pulumi.Input<string>; /** * The name for the public key. Conflicts with `name`. * * **NOTE:** When setting `encodedKey` value, there needs a newline at the end of string. Otherwise, multiple runs of pulumi will want to recreate the `aws.cloudfront.PublicKey` resource. */ namePrefix?: pulumi.Input<string>; } /** * The set of arguments for constructing a PublicKey resource. */ export interface PublicKeyArgs { /** * An optional comment about the public key. */ comment?: pulumi.Input<string>; /** * The encoded public key that you want to add to CloudFront to use with features like field-level encryption. */ encodedKey: pulumi.Input<string>; /** * The name for the public key. By default generated by this provider. Note: Do not set if using the key's id in another resource (e.g. KeyGroup) since it will result in a dependency error from AWS. Instead, it is recommended to use Pulumi autonaming by leaving this property unset (default behavior) or set the `namePrefix` property to allow the provider to autoname the resource. */ name?: pulumi.Input<string>; /** * The name for the public key. Conflicts with `name`. * * **NOTE:** When setting `encodedKey` value, there needs a newline at the end of string. Otherwise, multiple runs of pulumi will want to recreate the `aws.cloudfront.PublicKey` resource. */ namePrefix?: pulumi.Input<string>; }