@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
84 lines • 2.5 kB
JavaScript
// *** 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.getAttachmentsOutput = exports.getAttachments = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Get information on EC2 Transit Gateway Attachments.
*
* ## Example Usage
*
* ### By Filter
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const filtered = aws.ec2transitgateway.getAttachments({
* filters: [
* {
* name: "state",
* values: ["pendingAcceptance"],
* },
* {
* name: "resource-type",
* values: ["vpc"],
* },
* ],
* });
* const unit = .map(__index => (aws.ec2transitgateway.getAttachment({
* transitGatewayAttachmentId: _arg0_.ids[__index],
* })));
* ```
*/
function getAttachments(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("aws:ec2transitgateway/getAttachments:getAttachments", {
"filters": args.filters,
"region": args.region,
"tags": args.tags,
}, opts);
}
exports.getAttachments = getAttachments;
/**
* Get information on EC2 Transit Gateway Attachments.
*
* ## Example Usage
*
* ### By Filter
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const filtered = aws.ec2transitgateway.getAttachments({
* filters: [
* {
* name: "state",
* values: ["pendingAcceptance"],
* },
* {
* name: "resource-type",
* values: ["vpc"],
* },
* ],
* });
* const unit = .map(__index => (aws.ec2transitgateway.getAttachment({
* transitGatewayAttachmentId: _arg0_.ids[__index],
* })));
* ```
*/
function getAttachmentsOutput(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("aws:ec2transitgateway/getAttachments:getAttachments", {
"filters": args.filters,
"region": args.region,
"tags": args.tags,
}, opts);
}
exports.getAttachmentsOutput = getAttachmentsOutput;
//# sourceMappingURL=getAttachments.js.map
;