@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
321 lines (320 loc) • 12.1 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* Manages an Image Builder Infrastructure Configuration.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = new aws.imagebuilder.InfrastructureConfiguration("example", {
* description: "example description",
* instanceProfileName: exampleAwsIamInstanceProfile.name,
* instanceTypes: [
* "t2.nano",
* "t3.micro",
* ],
* keyPair: exampleAwsKeyPair.keyName,
* name: "example",
* securityGroupIds: [exampleAwsSecurityGroup.id],
* snsTopicArn: exampleAwsSnsTopic.arn,
* subnetId: main.id,
* terminateInstanceOnFailure: true,
* logging: {
* s3Logs: {
* s3BucketName: exampleAwsS3Bucket.bucket,
* s3KeyPrefix: "logs",
* },
* },
* tags: {
* foo: "bar",
* },
* });
* ```
*
* ## Import
*
* ### Identity Schema
*
* #### Required
*
* - `arn` (String) Amazon Resource Name (ARN) of the Image Builder infrastructure configuration.
*
* Using `pulumi import`, import `aws_imagebuilder_infrastructure_configuration` using the Amazon Resource Name (ARN). For example:
*
* console
*
* % pulumi import aws_imagebuilder_infrastructure_configuration.example arn:aws:imagebuilder:us-east-1:123456789012:infrastructure-configuration/example
*/
export declare class InfrastructureConfiguration extends pulumi.CustomResource {
/**
* Get an existing InfrastructureConfiguration 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?: InfrastructureConfigurationState, opts?: pulumi.CustomResourceOptions): InfrastructureConfiguration;
/**
* Returns true if the given object is an instance of InfrastructureConfiguration. 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 InfrastructureConfiguration;
/**
* Amazon Resource Name (ARN) of the configuration.
*/
readonly arn: pulumi.Output<string>;
/**
* Date when the configuration was created.
*/
readonly dateCreated: pulumi.Output<string>;
/**
* Date when the configuration was updated.
*/
readonly dateUpdated: pulumi.Output<string>;
/**
* Description for the configuration.
*/
readonly description: pulumi.Output<string | undefined>;
/**
* Configuration block with instance metadata options for the HTTP requests that pipeline builds use to launch EC2 build and test instances. Detailed below.
*/
readonly instanceMetadataOptions: pulumi.Output<outputs.imagebuilder.InfrastructureConfigurationInstanceMetadataOptions | undefined>;
/**
* Name of IAM Instance Profile.
*/
readonly instanceProfileName: pulumi.Output<string>;
/**
* Set of EC2 Instance Types.
*/
readonly instanceTypes: pulumi.Output<string[] | undefined>;
/**
* Name of EC2 Key Pair.
*/
readonly keyPair: pulumi.Output<string | undefined>;
/**
* Configuration block with logging settings. Detailed below.
*/
readonly logging: pulumi.Output<outputs.imagebuilder.InfrastructureConfigurationLogging | undefined>;
/**
* Name for the configuration.
*
* The following arguments are optional:
*/
readonly name: pulumi.Output<string>;
/**
* Configuration block with placement settings that define where the instances that are launched from your image will run. Detailed below.
*/
readonly placement: pulumi.Output<outputs.imagebuilder.InfrastructureConfigurationPlacement | undefined>;
/**
* 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>;
/**
* Key-value map of resource tags to assign to infrastructure created by the configuration.
*/
readonly resourceTags: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* Set of EC2 Security Group identifiers.
*/
readonly securityGroupIds: pulumi.Output<string[] | undefined>;
/**
* Amazon Resource Name (ARN) of SNS Topic.
*/
readonly snsTopicArn: pulumi.Output<string | undefined>;
/**
* EC2 Subnet identifier. Also requires `securityGroupIds` argument.
*/
readonly subnetId: pulumi.Output<string | undefined>;
/**
* Key-value map of resource tags to assign to the configuration. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
readonly tags: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
*/
readonly tagsAll: pulumi.Output<{
[key: string]: string;
}>;
/**
* Enable if the instance should be terminated when the pipeline fails. Defaults to `false`.
*/
readonly terminateInstanceOnFailure: pulumi.Output<boolean | undefined>;
/**
* Create a InfrastructureConfiguration 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: InfrastructureConfigurationArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering InfrastructureConfiguration resources.
*/
export interface InfrastructureConfigurationState {
/**
* Amazon Resource Name (ARN) of the configuration.
*/
arn?: pulumi.Input<string>;
/**
* Date when the configuration was created.
*/
dateCreated?: pulumi.Input<string>;
/**
* Date when the configuration was updated.
*/
dateUpdated?: pulumi.Input<string>;
/**
* Description for the configuration.
*/
description?: pulumi.Input<string>;
/**
* Configuration block with instance metadata options for the HTTP requests that pipeline builds use to launch EC2 build and test instances. Detailed below.
*/
instanceMetadataOptions?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationInstanceMetadataOptions>;
/**
* Name of IAM Instance Profile.
*/
instanceProfileName?: pulumi.Input<string>;
/**
* Set of EC2 Instance Types.
*/
instanceTypes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Name of EC2 Key Pair.
*/
keyPair?: pulumi.Input<string>;
/**
* Configuration block with logging settings. Detailed below.
*/
logging?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationLogging>;
/**
* Name for the configuration.
*
* The following arguments are optional:
*/
name?: pulumi.Input<string>;
/**
* Configuration block with placement settings that define where the instances that are launched from your image will run. Detailed below.
*/
placement?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationPlacement>;
/**
* 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>;
/**
* Key-value map of resource tags to assign to infrastructure created by the configuration.
*/
resourceTags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Set of EC2 Security Group identifiers.
*/
securityGroupIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Amazon Resource Name (ARN) of SNS Topic.
*/
snsTopicArn?: pulumi.Input<string>;
/**
* EC2 Subnet identifier. Also requires `securityGroupIds` argument.
*/
subnetId?: pulumi.Input<string>;
/**
* Key-value map of resource tags to assign to the configuration. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
tags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
*/
tagsAll?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Enable if the instance should be terminated when the pipeline fails. Defaults to `false`.
*/
terminateInstanceOnFailure?: pulumi.Input<boolean>;
}
/**
* The set of arguments for constructing a InfrastructureConfiguration resource.
*/
export interface InfrastructureConfigurationArgs {
/**
* Description for the configuration.
*/
description?: pulumi.Input<string>;
/**
* Configuration block with instance metadata options for the HTTP requests that pipeline builds use to launch EC2 build and test instances. Detailed below.
*/
instanceMetadataOptions?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationInstanceMetadataOptions>;
/**
* Name of IAM Instance Profile.
*/
instanceProfileName: pulumi.Input<string>;
/**
* Set of EC2 Instance Types.
*/
instanceTypes?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Name of EC2 Key Pair.
*/
keyPair?: pulumi.Input<string>;
/**
* Configuration block with logging settings. Detailed below.
*/
logging?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationLogging>;
/**
* Name for the configuration.
*
* The following arguments are optional:
*/
name?: pulumi.Input<string>;
/**
* Configuration block with placement settings that define where the instances that are launched from your image will run. Detailed below.
*/
placement?: pulumi.Input<inputs.imagebuilder.InfrastructureConfigurationPlacement>;
/**
* 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>;
/**
* Key-value map of resource tags to assign to infrastructure created by the configuration.
*/
resourceTags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Set of EC2 Security Group identifiers.
*/
securityGroupIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Amazon Resource Name (ARN) of SNS Topic.
*/
snsTopicArn?: pulumi.Input<string>;
/**
* EC2 Subnet identifier. Also requires `securityGroupIds` argument.
*/
subnetId?: pulumi.Input<string>;
/**
* Key-value map of resource tags to assign to the configuration. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
tags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Enable if the instance should be terminated when the pipeline fails. Defaults to `false`.
*/
terminateInstanceOnFailure?: pulumi.Input<boolean>;
}