UNPKG

@pulumi/aws

Version:

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

72 lines 2.29 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.getStackOutput = exports.getStack = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * The CloudFormation Stack data source allows access to stack * outputs and other useful data including the template body. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const network = aws.cloudformation.getStack({ * name: "my-network-stack", * }); * const web = new aws.ec2.Instance("web", { * ami: "ami-abb07bcb", * instanceType: aws.ec2.InstanceType.T2_Micro, * subnetId: network.then(network => network.outputs?.SubnetId), * tags: { * Name: "HelloWorld", * }, * }); * ``` */ function getStack(args, opts) { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invoke("aws:cloudformation/getStack:getStack", { "name": args.name, "region": args.region, "tags": args.tags, }, opts); } exports.getStack = getStack; /** * The CloudFormation Stack data source allows access to stack * outputs and other useful data including the template body. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as aws from "@pulumi/aws"; * * const network = aws.cloudformation.getStack({ * name: "my-network-stack", * }); * const web = new aws.ec2.Instance("web", { * ami: "ami-abb07bcb", * instanceType: aws.ec2.InstanceType.T2_Micro, * subnetId: network.then(network => network.outputs?.SubnetId), * tags: { * Name: "HelloWorld", * }, * }); * ``` */ function getStackOutput(args, opts) { opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {}); return pulumi.runtime.invokeOutput("aws:cloudformation/getStack:getStack", { "name": args.name, "region": args.region, "tags": args.tags, }, opts); } exports.getStackOutput = getStackOutput; //# sourceMappingURL=getStack.js.map