UNPKG

@pulumi/aws

Version:

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

174 lines (173 loc) 7.18 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Provides an [S3 Intelligent-Tiering](https://docs.aws.amazon.com/AmazonS3/latest/userguide/intelligent-tiering.html) configuration resource. * * > This resource cannot be used with S3 directory buckets. * * ## Example Usage * * ### Add intelligent tiering configuration for entire S3 bucket * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.s3.Bucket("example", {bucket: "example"}); * const example_entire_bucket = new aws.s3.BucketIntelligentTieringConfiguration("example-entire-bucket", { * bucket: example.id, * name: "EntireBucket", * tierings: [ * { * accessTier: "DEEP_ARCHIVE_ACCESS", * days: 180, * }, * { * accessTier: "ARCHIVE_ACCESS", * days: 125, * }, * ], * }); * ``` * * ### Add intelligent tiering configuration with S3 object filter * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const example = new aws.s3.Bucket("example", {bucket: "example"}); * const example_filtered = new aws.s3.BucketIntelligentTieringConfiguration("example-filtered", { * bucket: example.id, * name: "ImportantBlueDocuments", * status: "Disabled", * filter: { * prefix: "documents/", * tags: { * priority: "high", * "class": "blue", * }, * }, * tierings: [{ * accessTier: "ARCHIVE_ACCESS", * days: 125, * }], * }); * ``` * * ## Import * * Using `pulumi import`, import S3 bucket intelligent tiering configurations using `bucket:name`. For example: * * ```sh * $ pulumi import aws:s3/bucketIntelligentTieringConfiguration:BucketIntelligentTieringConfiguration my-bucket-entire-bucket my-bucket:EntireBucket * ``` */ export declare class BucketIntelligentTieringConfiguration extends pulumi.CustomResource { /** * Get an existing BucketIntelligentTieringConfiguration 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?: BucketIntelligentTieringConfigurationState, opts?: pulumi.CustomResourceOptions): BucketIntelligentTieringConfiguration; /** * Returns true if the given object is an instance of BucketIntelligentTieringConfiguration. 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 BucketIntelligentTieringConfiguration; /** * Name of the bucket this intelligent tiering configuration is associated with. */ readonly bucket: pulumi.Output<string>; /** * Bucket filter. The configuration only includes objects that meet the filter's criteria (documented below). */ readonly filter: pulumi.Output<outputs.s3.BucketIntelligentTieringConfigurationFilter | undefined>; /** * Unique name used to identify the S3 Intelligent-Tiering configuration for the bucket. */ readonly name: pulumi.Output<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ readonly region: pulumi.Output<string>; /** * Specifies the status of the configuration. Valid values: `Enabled`, `Disabled`. */ readonly status: pulumi.Output<string | undefined>; /** * S3 Intelligent-Tiering storage class tiers of the configuration (documented below). */ readonly tierings: pulumi.Output<outputs.s3.BucketIntelligentTieringConfigurationTiering[]>; /** * Create a BucketIntelligentTieringConfiguration 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: BucketIntelligentTieringConfigurationArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering BucketIntelligentTieringConfiguration resources. */ export interface BucketIntelligentTieringConfigurationState { /** * Name of the bucket this intelligent tiering configuration is associated with. */ bucket?: pulumi.Input<string>; /** * Bucket filter. The configuration only includes objects that meet the filter's criteria (documented below). */ filter?: pulumi.Input<inputs.s3.BucketIntelligentTieringConfigurationFilter>; /** * Unique name used to identify the S3 Intelligent-Tiering configuration for the bucket. */ name?: pulumi.Input<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input<string>; /** * Specifies the status of the configuration. Valid values: `Enabled`, `Disabled`. */ status?: pulumi.Input<string>; /** * S3 Intelligent-Tiering storage class tiers of the configuration (documented below). */ tierings?: pulumi.Input<pulumi.Input<inputs.s3.BucketIntelligentTieringConfigurationTiering>[]>; } /** * The set of arguments for constructing a BucketIntelligentTieringConfiguration resource. */ export interface BucketIntelligentTieringConfigurationArgs { /** * Name of the bucket this intelligent tiering configuration is associated with. */ bucket: pulumi.Input<string>; /** * Bucket filter. The configuration only includes objects that meet the filter's criteria (documented below). */ filter?: pulumi.Input<inputs.s3.BucketIntelligentTieringConfigurationFilter>; /** * Unique name used to identify the S3 Intelligent-Tiering configuration for the bucket. */ name?: pulumi.Input<string>; /** * Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration. */ region?: pulumi.Input<string>; /** * Specifies the status of the configuration. Valid values: `Enabled`, `Disabled`. */ status?: pulumi.Input<string>; /** * S3 Intelligent-Tiering storage class tiers of the configuration (documented below). */ tierings: pulumi.Input<pulumi.Input<inputs.s3.BucketIntelligentTieringConfigurationTiering>[]>; }