@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
80 lines • 2.95 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.getTargetGroupOutput = exports.getTargetGroup = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* > **Note:** `aws.alb.TargetGroup` is known as `aws.lb.TargetGroup`. The functionality is identical.
*
* Provides information about a Load Balancer Target Group.
*
* This data source can prove useful when a module accepts an LB Target Group as an
* input variable and needs to know its attributes. It can also be used to get the ARN of
* an LB Target Group for use in other resources, given LB Target Group name.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const config = new pulumi.Config();
* const lbTgArn = config.get("lbTgArn") || "";
* const lbTgName = config.get("lbTgName") || "";
* const test = aws.lb.getTargetGroup({
* arn: lbTgArn,
* name: lbTgName,
* });
* ```
*/
function getTargetGroup(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("aws:lb/getTargetGroup:getTargetGroup", {
"arn": args.arn,
"loadBalancingAnomalyMitigation": args.loadBalancingAnomalyMitigation,
"name": args.name,
"region": args.region,
"tags": args.tags,
}, opts);
}
exports.getTargetGroup = getTargetGroup;
/**
* > **Note:** `aws.alb.TargetGroup` is known as `aws.lb.TargetGroup`. The functionality is identical.
*
* Provides information about a Load Balancer Target Group.
*
* This data source can prove useful when a module accepts an LB Target Group as an
* input variable and needs to know its attributes. It can also be used to get the ARN of
* an LB Target Group for use in other resources, given LB Target Group name.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const config = new pulumi.Config();
* const lbTgArn = config.get("lbTgArn") || "";
* const lbTgName = config.get("lbTgName") || "";
* const test = aws.lb.getTargetGroup({
* arn: lbTgArn,
* name: lbTgName,
* });
* ```
*/
function getTargetGroupOutput(args, opts) {
args = args || {};
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("aws:lb/getTargetGroup:getTargetGroup", {
"arn": args.arn,
"loadBalancingAnomalyMitigation": args.loadBalancingAnomalyMitigation,
"name": args.name,
"region": args.region,
"tags": args.tags,
}, opts);
}
exports.getTargetGroupOutput = getTargetGroupOutput;
//# sourceMappingURL=getTargetGroup.js.map
;