UNPKG

@pulumi/aws

Version:

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

136 lines • 9.13 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.LaunchTemplate = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Provides an EC2 launch template resource. Can be used to create instances or auto scaling groups. * * ## Import * * Using `pulumi import`, import Launch Templates using the `id`. For example: * * ```sh * $ pulumi import aws:ec2/launchTemplate:LaunchTemplate web lt-12345678 * ``` */ class LaunchTemplate extends pulumi.CustomResource { /** * Get an existing LaunchTemplate 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, id, state, opts) { return new LaunchTemplate(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of LaunchTemplate. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === LaunchTemplate.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["arn"] = state ? state.arn : undefined; resourceInputs["blockDeviceMappings"] = state ? state.blockDeviceMappings : undefined; resourceInputs["capacityReservationSpecification"] = state ? state.capacityReservationSpecification : undefined; resourceInputs["cpuOptions"] = state ? state.cpuOptions : undefined; resourceInputs["creditSpecification"] = state ? state.creditSpecification : undefined; resourceInputs["defaultVersion"] = state ? state.defaultVersion : undefined; resourceInputs["description"] = state ? state.description : undefined; resourceInputs["disableApiStop"] = state ? state.disableApiStop : undefined; resourceInputs["disableApiTermination"] = state ? state.disableApiTermination : undefined; resourceInputs["ebsOptimized"] = state ? state.ebsOptimized : undefined; resourceInputs["enclaveOptions"] = state ? state.enclaveOptions : undefined; resourceInputs["hibernationOptions"] = state ? state.hibernationOptions : undefined; resourceInputs["iamInstanceProfile"] = state ? state.iamInstanceProfile : undefined; resourceInputs["imageId"] = state ? state.imageId : undefined; resourceInputs["instanceInitiatedShutdownBehavior"] = state ? state.instanceInitiatedShutdownBehavior : undefined; resourceInputs["instanceMarketOptions"] = state ? state.instanceMarketOptions : undefined; resourceInputs["instanceRequirements"] = state ? state.instanceRequirements : undefined; resourceInputs["instanceType"] = state ? state.instanceType : undefined; resourceInputs["kernelId"] = state ? state.kernelId : undefined; resourceInputs["keyName"] = state ? state.keyName : undefined; resourceInputs["latestVersion"] = state ? state.latestVersion : undefined; resourceInputs["licenseSpecifications"] = state ? state.licenseSpecifications : undefined; resourceInputs["maintenanceOptions"] = state ? state.maintenanceOptions : undefined; resourceInputs["metadataOptions"] = state ? state.metadataOptions : undefined; resourceInputs["monitoring"] = state ? state.monitoring : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["namePrefix"] = state ? state.namePrefix : undefined; resourceInputs["networkInterfaces"] = state ? state.networkInterfaces : undefined; resourceInputs["placement"] = state ? state.placement : undefined; resourceInputs["privateDnsNameOptions"] = state ? state.privateDnsNameOptions : undefined; resourceInputs["ramDiskId"] = state ? state.ramDiskId : undefined; resourceInputs["region"] = state ? state.region : undefined; resourceInputs["securityGroupNames"] = state ? state.securityGroupNames : undefined; resourceInputs["tagSpecifications"] = state ? state.tagSpecifications : undefined; resourceInputs["tags"] = state ? state.tags : undefined; resourceInputs["tagsAll"] = state ? state.tagsAll : undefined; resourceInputs["updateDefaultVersion"] = state ? state.updateDefaultVersion : undefined; resourceInputs["userData"] = state ? state.userData : undefined; resourceInputs["vpcSecurityGroupIds"] = state ? state.vpcSecurityGroupIds : undefined; } else { const args = argsOrState; resourceInputs["blockDeviceMappings"] = args ? args.blockDeviceMappings : undefined; resourceInputs["capacityReservationSpecification"] = args ? args.capacityReservationSpecification : undefined; resourceInputs["cpuOptions"] = args ? args.cpuOptions : undefined; resourceInputs["creditSpecification"] = args ? args.creditSpecification : undefined; resourceInputs["defaultVersion"] = args ? args.defaultVersion : undefined; resourceInputs["description"] = args ? args.description : undefined; resourceInputs["disableApiStop"] = args ? args.disableApiStop : undefined; resourceInputs["disableApiTermination"] = args ? args.disableApiTermination : undefined; resourceInputs["ebsOptimized"] = args ? args.ebsOptimized : undefined; resourceInputs["enclaveOptions"] = args ? args.enclaveOptions : undefined; resourceInputs["hibernationOptions"] = args ? args.hibernationOptions : undefined; resourceInputs["iamInstanceProfile"] = args ? args.iamInstanceProfile : undefined; resourceInputs["imageId"] = args ? args.imageId : undefined; resourceInputs["instanceInitiatedShutdownBehavior"] = args ? args.instanceInitiatedShutdownBehavior : undefined; resourceInputs["instanceMarketOptions"] = args ? args.instanceMarketOptions : undefined; resourceInputs["instanceRequirements"] = args ? args.instanceRequirements : undefined; resourceInputs["instanceType"] = args ? args.instanceType : undefined; resourceInputs["kernelId"] = args ? args.kernelId : undefined; resourceInputs["keyName"] = args ? args.keyName : undefined; resourceInputs["licenseSpecifications"] = args ? args.licenseSpecifications : undefined; resourceInputs["maintenanceOptions"] = args ? args.maintenanceOptions : undefined; resourceInputs["metadataOptions"] = args ? args.metadataOptions : undefined; resourceInputs["monitoring"] = args ? args.monitoring : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["namePrefix"] = args ? args.namePrefix : undefined; resourceInputs["networkInterfaces"] = args ? args.networkInterfaces : undefined; resourceInputs["placement"] = args ? args.placement : undefined; resourceInputs["privateDnsNameOptions"] = args ? args.privateDnsNameOptions : undefined; resourceInputs["ramDiskId"] = args ? args.ramDiskId : undefined; resourceInputs["region"] = args ? args.region : undefined; resourceInputs["securityGroupNames"] = args ? args.securityGroupNames : undefined; resourceInputs["tagSpecifications"] = args ? args.tagSpecifications : undefined; resourceInputs["tags"] = args ? args.tags : undefined; resourceInputs["updateDefaultVersion"] = args ? args.updateDefaultVersion : undefined; resourceInputs["userData"] = args ? args.userData : undefined; resourceInputs["vpcSecurityGroupIds"] = args ? args.vpcSecurityGroupIds : undefined; resourceInputs["arn"] = undefined /*out*/; resourceInputs["latestVersion"] = undefined /*out*/; resourceInputs["tagsAll"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(LaunchTemplate.__pulumiType, name, resourceInputs, opts); } } exports.LaunchTemplate = LaunchTemplate; /** @internal */ LaunchTemplate.__pulumiType = 'aws:ec2/launchTemplate:LaunchTemplate'; //# sourceMappingURL=launchTemplate.js.map