AWS Classic

v5.21.1 published on Thursday, Nov 17, 2022 by Pulumi

getGroup

Use this data source to get information on an existing autoscaling group.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var foo = Aws.AutoScaling.GetGroup.Invoke(new()
    {
        Name = "foo",
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/autoscaling"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := autoscaling.LookupGroup(ctx, &autoscaling.LookupGroupArgs{
			Name: "foo",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.autoscaling.AutoscalingFunctions;
import com.pulumi.aws.alb.inputs.GetTargetGroupArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var foo = AutoscalingFunctions.getGroup(GetTargetGroupArgs.builder()
            .name("foo")
            .build());

    }
}
import pulumi
import pulumi_aws as aws

foo = aws.autoscaling.get_group(name="foo")
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const foo = pulumi.output(aws.autoscaling.getGroup({
    name: "foo",
}));
variables:
  foo:
    Fn::Invoke:
      Function: aws:autoscaling:getGroup
      Arguments:
        name: foo

Using getGroup

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getGroup(args: GetGroupArgs, opts?: InvokeOptions): Promise<GetGroupResult>
function getGroupOutput(args: GetGroupOutputArgs, opts?: InvokeOptions): Output<GetGroupResult>
def get_group(name: Optional[str] = None,
              opts: Optional[InvokeOptions] = None) -> GetGroupResult
def get_group_output(name: Optional[pulumi.Input[str]] = None,
              opts: Optional[InvokeOptions] = None) -> Output[GetGroupResult]
func LookupGroup(ctx *Context, args *LookupGroupArgs, opts ...InvokeOption) (*LookupGroupResult, error)
func LookupGroupOutput(ctx *Context, args *LookupGroupOutputArgs, opts ...InvokeOption) LookupGroupResultOutput

> Note: This function is named LookupGroup in the Go SDK.

public static class GetGroup 
{
    public static Task<GetGroupResult> InvokeAsync(GetGroupArgs args, InvokeOptions? opts = null)
    public static Output<GetGroupResult> Invoke(GetGroupInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetGroupResult> getGroup(GetGroupArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: aws:autoscaling/getGroup:getGroup
  arguments:
    # arguments dictionary

The following arguments are supported:

Name string

Specify the exact name of the desired autoscaling group.

Name string

Specify the exact name of the desired autoscaling group.

name String

Specify the exact name of the desired autoscaling group.

name string

Specify the exact name of the desired autoscaling group.

name str

Specify the exact name of the desired autoscaling group.

name String

Specify the exact name of the desired autoscaling group.

getGroup Result

The following output properties are available:

Arn string

ARN of the Auto Scaling group.

AvailabilityZones List<string>

One or more Availability Zones for the group.

DefaultCooldown int
DesiredCapacity int

Desired size of the group.

EnabledMetrics List<string>

List of metrics enabled for collection.

HealthCheckGracePeriod int

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

HealthCheckType string

Service to use for the health checks. The valid values are EC2 and ELB.

Id string

The provider-assigned unique ID for this managed resource.

LaunchConfiguration string

The name of the associated launch configuration.

LaunchTemplates List<GetGroupLaunchTemplate>
LoadBalancers List<string>

One or more load balancers associated with the group.

MaxSize int

Maximum size of the group.

MinSize int

Minimum size of the group.

Name string

Name of the Auto Scaling Group.

NewInstancesProtectedFromScaleIn bool
PlacementGroup string

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

ServiceLinkedRoleArn string

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

Status string

Current state of the group when DeleteAutoScalingGroup is in progress.

TargetGroupArns List<string>

ARNs of the target groups for your load balancer.

TerminationPolicies List<string>

The termination policies for the group.

VpcZoneIdentifier string

VPC ID for the group.

Arn string

ARN of the Auto Scaling group.

AvailabilityZones []string

One or more Availability Zones for the group.

DefaultCooldown int
DesiredCapacity int

Desired size of the group.

EnabledMetrics []string

List of metrics enabled for collection.

HealthCheckGracePeriod int

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

HealthCheckType string

Service to use for the health checks. The valid values are EC2 and ELB.

Id string

The provider-assigned unique ID for this managed resource.

LaunchConfiguration string

The name of the associated launch configuration.

LaunchTemplates []GetGroupLaunchTemplate
LoadBalancers []string

One or more load balancers associated with the group.

MaxSize int

Maximum size of the group.

MinSize int

Minimum size of the group.

Name string

Name of the Auto Scaling Group.

NewInstancesProtectedFromScaleIn bool
PlacementGroup string

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

ServiceLinkedRoleArn string

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

Status string

Current state of the group when DeleteAutoScalingGroup is in progress.

TargetGroupArns []string

ARNs of the target groups for your load balancer.

TerminationPolicies []string

The termination policies for the group.

VpcZoneIdentifier string

VPC ID for the group.

arn String

ARN of the Auto Scaling group.

availabilityZones List<String>

One or more Availability Zones for the group.

defaultCooldown Integer
desiredCapacity Integer

Desired size of the group.

enabledMetrics List<String>

List of metrics enabled for collection.

healthCheckGracePeriod Integer

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

healthCheckType String

Service to use for the health checks. The valid values are EC2 and ELB.

id String

The provider-assigned unique ID for this managed resource.

launchConfiguration String

The name of the associated launch configuration.

launchTemplates List<GetGroupLaunchTemplate>
loadBalancers List<String>

One or more load balancers associated with the group.

maxSize Integer

Maximum size of the group.

minSize Integer

Minimum size of the group.

name String

Name of the Auto Scaling Group.

newInstancesProtectedFromScaleIn Boolean
placementGroup String

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

serviceLinkedRoleArn String

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

status String

Current state of the group when DeleteAutoScalingGroup is in progress.

targetGroupArns List<String>

ARNs of the target groups for your load balancer.

terminationPolicies List<String>

The termination policies for the group.

vpcZoneIdentifier String

VPC ID for the group.

arn string

ARN of the Auto Scaling group.

availabilityZones string[]

One or more Availability Zones for the group.

defaultCooldown number
desiredCapacity number

Desired size of the group.

enabledMetrics string[]

List of metrics enabled for collection.

healthCheckGracePeriod number

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

healthCheckType string

Service to use for the health checks. The valid values are EC2 and ELB.

id string

The provider-assigned unique ID for this managed resource.

launchConfiguration string

The name of the associated launch configuration.

launchTemplates GetGroupLaunchTemplate[]
loadBalancers string[]

One or more load balancers associated with the group.

maxSize number

Maximum size of the group.

minSize number

Minimum size of the group.

name string

Name of the Auto Scaling Group.

newInstancesProtectedFromScaleIn boolean
placementGroup string

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

serviceLinkedRoleArn string

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

status string

Current state of the group when DeleteAutoScalingGroup is in progress.

targetGroupArns string[]

ARNs of the target groups for your load balancer.

terminationPolicies string[]

The termination policies for the group.

vpcZoneIdentifier string

VPC ID for the group.

arn str

ARN of the Auto Scaling group.

availability_zones Sequence[str]

One or more Availability Zones for the group.

default_cooldown int
desired_capacity int

Desired size of the group.

enabled_metrics Sequence[str]

List of metrics enabled for collection.

health_check_grace_period int

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

health_check_type str

Service to use for the health checks. The valid values are EC2 and ELB.

id str

The provider-assigned unique ID for this managed resource.

launch_configuration str

The name of the associated launch configuration.

launch_templates Sequence[GetGroupLaunchTemplate]
load_balancers Sequence[str]

One or more load balancers associated with the group.

max_size int

Maximum size of the group.

min_size int

Minimum size of the group.

name str

Name of the Auto Scaling Group.

new_instances_protected_from_scale_in bool
placement_group str

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

service_linked_role_arn str

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

status str

Current state of the group when DeleteAutoScalingGroup is in progress.

target_group_arns Sequence[str]

ARNs of the target groups for your load balancer.

termination_policies Sequence[str]

The termination policies for the group.

vpc_zone_identifier str

VPC ID for the group.

arn String

ARN of the Auto Scaling group.

availabilityZones List<String>

One or more Availability Zones for the group.

defaultCooldown Number
desiredCapacity Number

Desired size of the group.

enabledMetrics List<String>

List of metrics enabled for collection.

healthCheckGracePeriod Number

The amount of time, in seconds, that Amazon EC2 Auto Scaling waits before checking the health status of an EC2 instance that has come into service.

healthCheckType String

Service to use for the health checks. The valid values are EC2 and ELB.

id String

The provider-assigned unique ID for this managed resource.

launchConfiguration String

The name of the associated launch configuration.

launchTemplates List<Property Map>
loadBalancers List<String>

One or more load balancers associated with the group.

maxSize Number

Maximum size of the group.

minSize Number

Minimum size of the group.

name String

Name of the Auto Scaling Group.

newInstancesProtectedFromScaleIn Boolean
placementGroup String

Name of the placement group into which to launch your instances, if any. For more information, see Placement Groups (http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/placement-groups.html) in the Amazon Elastic Compute Cloud User Guide.

serviceLinkedRoleArn String

ARN of the service-linked role that the Auto Scaling group uses to call other AWS services on your behalf.

status String

Current state of the group when DeleteAutoScalingGroup is in progress.

targetGroupArns List<String>

ARNs of the target groups for your load balancer.

terminationPolicies List<String>

The termination policies for the group.

vpcZoneIdentifier String

VPC ID for the group.

Supporting Types

GetGroupLaunchTemplate

Id string

Name of the Auto Scaling Group.

Name string

Specify the exact name of the desired autoscaling group.

Version string
Id string

Name of the Auto Scaling Group.

Name string

Specify the exact name of the desired autoscaling group.

Version string
id String

Name of the Auto Scaling Group.

name String

Specify the exact name of the desired autoscaling group.

version String
id string

Name of the Auto Scaling Group.

name string

Specify the exact name of the desired autoscaling group.

version string
id str

Name of the Auto Scaling Group.

name str

Specify the exact name of the desired autoscaling group.

version str
id String

Name of the Auto Scaling Group.

name String

Specify the exact name of the desired autoscaling group.

version String

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.