1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. edas
  5. ApplicationScale
Alibaba Cloud v3.52.1 published on Thursday, Apr 4, 2024 by Pulumi

alicloud.edas.ApplicationScale

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.52.1 published on Thursday, Apr 4, 2024 by Pulumi

    This operation is provided to scale out an EDAS application, see What is EDAS Application Scale.

    NOTE: Available since v1.82.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "tf-example";
    const defaultRegions = alicloud.getRegions({
        current: true,
    });
    const defaultZones = alicloud.getZones({
        availableResourceCreation: "VSwitch",
    });
    const defaultImages = alicloud.ecs.getImages({
        nameRegex: "^ubuntu_[0-9]+_[0-9]+_x64*",
        owners: "system",
    });
    const defaultInstanceTypes = defaultZones.then(defaultZones => alicloud.ecs.getInstanceTypes({
        availabilityZone: defaultZones.zones?.[0]?.id,
        cpuCoreCount: 1,
        memorySize: 2,
    }));
    const defaultNetwork = new alicloud.vpc.Network("defaultNetwork", {
        vpcName: name,
        cidrBlock: "10.4.0.0/16",
    });
    const defaultSwitch = new alicloud.vpc.Switch("defaultSwitch", {
        vswitchName: name,
        cidrBlock: "10.4.0.0/24",
        vpcId: defaultNetwork.id,
        zoneId: defaultZones.then(defaultZones => defaultZones.zones?.[0]?.id),
    });
    const defaultSecurityGroup = new alicloud.ecs.SecurityGroup("defaultSecurityGroup", {vpcId: defaultNetwork.id});
    const defaultInstance = new alicloud.ecs.Instance("defaultInstance", {
        availabilityZone: defaultZones.then(defaultZones => defaultZones.zones?.[0]?.id),
        instanceName: name,
        imageId: defaultImages.then(defaultImages => defaultImages.images?.[0]?.id),
        instanceType: defaultInstanceTypes.then(defaultInstanceTypes => defaultInstanceTypes.instanceTypes?.[0]?.id),
        securityGroups: [defaultSecurityGroup.id],
        vswitchId: defaultSwitch.id,
        internetMaxBandwidthOut: 10,
        internetChargeType: "PayByTraffic",
        instanceChargeType: "PostPaid",
        systemDiskCategory: "cloud_efficiency",
    });
    const defaultCluster = new alicloud.edas.Cluster("defaultCluster", {
        clusterName: name,
        clusterType: 2,
        networkMode: 2,
        logicalRegionId: defaultRegions.then(defaultRegions => defaultRegions.regions?.[0]?.id),
        vpcId: defaultNetwork.id,
    });
    const defaultInstanceClusterAttachment = new alicloud.edas.InstanceClusterAttachment("defaultInstanceClusterAttachment", {
        clusterId: defaultCluster.id,
        instanceIds: [defaultInstance.id],
    });
    const defaultApplication = new alicloud.edas.Application("defaultApplication", {
        applicationName: name,
        clusterId: defaultCluster.id,
        packageType: "WAR",
    });
    const defaultDeployGroup = new alicloud.edas.DeployGroup("defaultDeployGroup", {
        appId: defaultApplication.id,
        groupName: name,
    });
    const defaultDeployGroups = alicloud.edas.getDeployGroupsOutput({
        appId: defaultDeployGroup.appId,
    });
    const defaultApplicationScale = new alicloud.edas.ApplicationScale("defaultApplicationScale", {
        appId: defaultApplication.id,
        deployGroup: defaultDeployGroups.apply(defaultDeployGroups => defaultDeployGroups.groups?.[0]?.groupId),
        ecuInfos: [pulumi.all([defaultInstanceClusterAttachment.ecuMap, defaultInstance.id]).apply(([ecuMap, id]) => ecuMap[id])],
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "tf-example"
    default_regions = alicloud.get_regions(current=True)
    default_zones = alicloud.get_zones(available_resource_creation="VSwitch")
    default_images = alicloud.ecs.get_images(name_regex="^ubuntu_[0-9]+_[0-9]+_x64*",
        owners="system")
    default_instance_types = alicloud.ecs.get_instance_types(availability_zone=default_zones.zones[0].id,
        cpu_core_count=1,
        memory_size=2)
    default_network = alicloud.vpc.Network("defaultNetwork",
        vpc_name=name,
        cidr_block="10.4.0.0/16")
    default_switch = alicloud.vpc.Switch("defaultSwitch",
        vswitch_name=name,
        cidr_block="10.4.0.0/24",
        vpc_id=default_network.id,
        zone_id=default_zones.zones[0].id)
    default_security_group = alicloud.ecs.SecurityGroup("defaultSecurityGroup", vpc_id=default_network.id)
    default_instance = alicloud.ecs.Instance("defaultInstance",
        availability_zone=default_zones.zones[0].id,
        instance_name=name,
        image_id=default_images.images[0].id,
        instance_type=default_instance_types.instance_types[0].id,
        security_groups=[default_security_group.id],
        vswitch_id=default_switch.id,
        internet_max_bandwidth_out=10,
        internet_charge_type="PayByTraffic",
        instance_charge_type="PostPaid",
        system_disk_category="cloud_efficiency")
    default_cluster = alicloud.edas.Cluster("defaultCluster",
        cluster_name=name,
        cluster_type=2,
        network_mode=2,
        logical_region_id=default_regions.regions[0].id,
        vpc_id=default_network.id)
    default_instance_cluster_attachment = alicloud.edas.InstanceClusterAttachment("defaultInstanceClusterAttachment",
        cluster_id=default_cluster.id,
        instance_ids=[default_instance.id])
    default_application = alicloud.edas.Application("defaultApplication",
        application_name=name,
        cluster_id=default_cluster.id,
        package_type="WAR")
    default_deploy_group = alicloud.edas.DeployGroup("defaultDeployGroup",
        app_id=default_application.id,
        group_name=name)
    default_deploy_groups = alicloud.edas.get_deploy_groups_output(app_id=default_deploy_group.app_id)
    default_application_scale = alicloud.edas.ApplicationScale("defaultApplicationScale",
        app_id=default_application.id,
        deploy_group=default_deploy_groups.groups[0].group_id,
        ecu_infos=[pulumi.Output.all(default_instance_cluster_attachment.ecu_map, default_instance.id).apply(lambda ecu_map, id: ecu_map[id])])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/edas"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		name := "tf-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		defaultRegions, err := alicloud.GetRegions(ctx, &alicloud.GetRegionsArgs{
    			Current: pulumi.BoolRef(true),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultZones, err := alicloud.GetZones(ctx, &alicloud.GetZonesArgs{
    			AvailableResourceCreation: pulumi.StringRef("VSwitch"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultImages, err := ecs.GetImages(ctx, &ecs.GetImagesArgs{
    			NameRegex: pulumi.StringRef("^ubuntu_[0-9]+_[0-9]+_x64*"),
    			Owners:    pulumi.StringRef("system"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultInstanceTypes, err := ecs.GetInstanceTypes(ctx, &ecs.GetInstanceTypesArgs{
    			AvailabilityZone: pulumi.StringRef(defaultZones.Zones[0].Id),
    			CpuCoreCount:     pulumi.IntRef(1),
    			MemorySize:       pulumi.Float64Ref(2),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultNetwork, err := vpc.NewNetwork(ctx, "defaultNetwork", &vpc.NetworkArgs{
    			VpcName:   pulumi.String(name),
    			CidrBlock: pulumi.String("10.4.0.0/16"),
    		})
    		if err != nil {
    			return err
    		}
    		defaultSwitch, err := vpc.NewSwitch(ctx, "defaultSwitch", &vpc.SwitchArgs{
    			VswitchName: pulumi.String(name),
    			CidrBlock:   pulumi.String("10.4.0.0/24"),
    			VpcId:       defaultNetwork.ID(),
    			ZoneId:      pulumi.String(defaultZones.Zones[0].Id),
    		})
    		if err != nil {
    			return err
    		}
    		defaultSecurityGroup, err := ecs.NewSecurityGroup(ctx, "defaultSecurityGroup", &ecs.SecurityGroupArgs{
    			VpcId: defaultNetwork.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		defaultInstance, err := ecs.NewInstance(ctx, "defaultInstance", &ecs.InstanceArgs{
    			AvailabilityZone: pulumi.String(defaultZones.Zones[0].Id),
    			InstanceName:     pulumi.String(name),
    			ImageId:          pulumi.String(defaultImages.Images[0].Id),
    			InstanceType:     pulumi.String(defaultInstanceTypes.InstanceTypes[0].Id),
    			SecurityGroups: pulumi.StringArray{
    				defaultSecurityGroup.ID(),
    			},
    			VswitchId:               defaultSwitch.ID(),
    			InternetMaxBandwidthOut: pulumi.Int(10),
    			InternetChargeType:      pulumi.String("PayByTraffic"),
    			InstanceChargeType:      pulumi.String("PostPaid"),
    			SystemDiskCategory:      pulumi.String("cloud_efficiency"),
    		})
    		if err != nil {
    			return err
    		}
    		defaultCluster, err := edas.NewCluster(ctx, "defaultCluster", &edas.ClusterArgs{
    			ClusterName:     pulumi.String(name),
    			ClusterType:     pulumi.Int(2),
    			NetworkMode:     pulumi.Int(2),
    			LogicalRegionId: pulumi.String(defaultRegions.Regions[0].Id),
    			VpcId:           defaultNetwork.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		defaultInstanceClusterAttachment, err := edas.NewInstanceClusterAttachment(ctx, "defaultInstanceClusterAttachment", &edas.InstanceClusterAttachmentArgs{
    			ClusterId: defaultCluster.ID(),
    			InstanceIds: pulumi.StringArray{
    				defaultInstance.ID(),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		defaultApplication, err := edas.NewApplication(ctx, "defaultApplication", &edas.ApplicationArgs{
    			ApplicationName: pulumi.String(name),
    			ClusterId:       defaultCluster.ID(),
    			PackageType:     pulumi.String("WAR"),
    		})
    		if err != nil {
    			return err
    		}
    		defaultDeployGroup, err := edas.NewDeployGroup(ctx, "defaultDeployGroup", &edas.DeployGroupArgs{
    			AppId:     defaultApplication.ID(),
    			GroupName: pulumi.String(name),
    		})
    		if err != nil {
    			return err
    		}
    		defaultDeployGroups := edas.GetDeployGroupsOutput(ctx, edas.GetDeployGroupsOutputArgs{
    			AppId: defaultDeployGroup.AppId,
    		}, nil)
    		_, err = edas.NewApplicationScale(ctx, "defaultApplicationScale", &edas.ApplicationScaleArgs{
    			AppId: defaultApplication.ID(),
    			DeployGroup: defaultDeployGroups.ApplyT(func(defaultDeployGroups edas.GetDeployGroupsResult) (*string, error) {
    				return &defaultDeployGroups.Groups[0].GroupId, nil
    			}).(pulumi.StringPtrOutput),
    			EcuInfos: pulumi.StringArray{
    				pulumi.All(defaultInstanceClusterAttachment.EcuMap, defaultInstance.ID()).ApplyT(func(_args []interface{}) (string, error) {
    					ecuMap := _args[0].(map[string]string)
    					id := _args[1].(string)
    					return ecuMap[id], nil
    				}).(pulumi.StringOutput),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "tf-example";
        var defaultRegions = AliCloud.GetRegions.Invoke(new()
        {
            Current = true,
        });
    
        var defaultZones = AliCloud.GetZones.Invoke(new()
        {
            AvailableResourceCreation = "VSwitch",
        });
    
        var defaultImages = AliCloud.Ecs.GetImages.Invoke(new()
        {
            NameRegex = "^ubuntu_[0-9]+_[0-9]+_x64*",
            Owners = "system",
        });
    
        var defaultInstanceTypes = AliCloud.Ecs.GetInstanceTypes.Invoke(new()
        {
            AvailabilityZone = defaultZones.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
            CpuCoreCount = 1,
            MemorySize = 2,
        });
    
        var defaultNetwork = new AliCloud.Vpc.Network("defaultNetwork", new()
        {
            VpcName = name,
            CidrBlock = "10.4.0.0/16",
        });
    
        var defaultSwitch = new AliCloud.Vpc.Switch("defaultSwitch", new()
        {
            VswitchName = name,
            CidrBlock = "10.4.0.0/24",
            VpcId = defaultNetwork.Id,
            ZoneId = defaultZones.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
        });
    
        var defaultSecurityGroup = new AliCloud.Ecs.SecurityGroup("defaultSecurityGroup", new()
        {
            VpcId = defaultNetwork.Id,
        });
    
        var defaultInstance = new AliCloud.Ecs.Instance("defaultInstance", new()
        {
            AvailabilityZone = defaultZones.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
            InstanceName = name,
            ImageId = defaultImages.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
            InstanceType = defaultInstanceTypes.Apply(getInstanceTypesResult => getInstanceTypesResult.InstanceTypes[0]?.Id),
            SecurityGroups = new[]
            {
                defaultSecurityGroup.Id,
            },
            VswitchId = defaultSwitch.Id,
            InternetMaxBandwidthOut = 10,
            InternetChargeType = "PayByTraffic",
            InstanceChargeType = "PostPaid",
            SystemDiskCategory = "cloud_efficiency",
        });
    
        var defaultCluster = new AliCloud.Edas.Cluster("defaultCluster", new()
        {
            ClusterName = name,
            ClusterType = 2,
            NetworkMode = 2,
            LogicalRegionId = defaultRegions.Apply(getRegionsResult => getRegionsResult.Regions[0]?.Id),
            VpcId = defaultNetwork.Id,
        });
    
        var defaultInstanceClusterAttachment = new AliCloud.Edas.InstanceClusterAttachment("defaultInstanceClusterAttachment", new()
        {
            ClusterId = defaultCluster.Id,
            InstanceIds = new[]
            {
                defaultInstance.Id,
            },
        });
    
        var defaultApplication = new AliCloud.Edas.Application("defaultApplication", new()
        {
            ApplicationName = name,
            ClusterId = defaultCluster.Id,
            PackageType = "WAR",
        });
    
        var defaultDeployGroup = new AliCloud.Edas.DeployGroup("defaultDeployGroup", new()
        {
            AppId = defaultApplication.Id,
            GroupName = name,
        });
    
        var defaultDeployGroups = AliCloud.Edas.GetDeployGroups.Invoke(new()
        {
            AppId = defaultDeployGroup.AppId,
        });
    
        var defaultApplicationScale = new AliCloud.Edas.ApplicationScale("defaultApplicationScale", new()
        {
            AppId = defaultApplication.Id,
            DeployGroup = defaultDeployGroups.Apply(getDeployGroupsResult => getDeployGroupsResult.Groups[0]?.GroupId),
            EcuInfos = new[]
            {
                Output.Tuple(defaultInstanceClusterAttachment.EcuMap, defaultInstance.Id).Apply(values =>
                {
                    var ecuMap = values.Item1;
                    var id = values.Item2;
                    return ecuMap[id];
                }),
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.AlicloudFunctions;
    import com.pulumi.alicloud.inputs.GetRegionsArgs;
    import com.pulumi.alicloud.inputs.GetZonesArgs;
    import com.pulumi.alicloud.ecs.EcsFunctions;
    import com.pulumi.alicloud.ecs.inputs.GetImagesArgs;
    import com.pulumi.alicloud.ecs.inputs.GetInstanceTypesArgs;
    import com.pulumi.alicloud.vpc.Network;
    import com.pulumi.alicloud.vpc.NetworkArgs;
    import com.pulumi.alicloud.vpc.Switch;
    import com.pulumi.alicloud.vpc.SwitchArgs;
    import com.pulumi.alicloud.ecs.SecurityGroup;
    import com.pulumi.alicloud.ecs.SecurityGroupArgs;
    import com.pulumi.alicloud.ecs.Instance;
    import com.pulumi.alicloud.ecs.InstanceArgs;
    import com.pulumi.alicloud.edas.Cluster;
    import com.pulumi.alicloud.edas.ClusterArgs;
    import com.pulumi.alicloud.edas.InstanceClusterAttachment;
    import com.pulumi.alicloud.edas.InstanceClusterAttachmentArgs;
    import com.pulumi.alicloud.edas.Application;
    import com.pulumi.alicloud.edas.ApplicationArgs;
    import com.pulumi.alicloud.edas.DeployGroup;
    import com.pulumi.alicloud.edas.DeployGroupArgs;
    import com.pulumi.alicloud.edas.EdasFunctions;
    import com.pulumi.alicloud.edas.inputs.GetDeployGroupsArgs;
    import com.pulumi.alicloud.edas.ApplicationScale;
    import com.pulumi.alicloud.edas.ApplicationScaleArgs;
    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 config = ctx.config();
            final var name = config.get("name").orElse("tf-example");
            final var defaultRegions = AlicloudFunctions.getRegions(GetRegionsArgs.builder()
                .current(true)
                .build());
    
            final var defaultZones = AlicloudFunctions.getZones(GetZonesArgs.builder()
                .availableResourceCreation("VSwitch")
                .build());
    
            final var defaultImages = EcsFunctions.getImages(GetImagesArgs.builder()
                .nameRegex("^ubuntu_[0-9]+_[0-9]+_x64*")
                .owners("system")
                .build());
    
            final var defaultInstanceTypes = EcsFunctions.getInstanceTypes(GetInstanceTypesArgs.builder()
                .availabilityZone(defaultZones.applyValue(getZonesResult -> getZonesResult.zones()[0].id()))
                .cpuCoreCount(1)
                .memorySize(2)
                .build());
    
            var defaultNetwork = new Network("defaultNetwork", NetworkArgs.builder()        
                .vpcName(name)
                .cidrBlock("10.4.0.0/16")
                .build());
    
            var defaultSwitch = new Switch("defaultSwitch", SwitchArgs.builder()        
                .vswitchName(name)
                .cidrBlock("10.4.0.0/24")
                .vpcId(defaultNetwork.id())
                .zoneId(defaultZones.applyValue(getZonesResult -> getZonesResult.zones()[0].id()))
                .build());
    
            var defaultSecurityGroup = new SecurityGroup("defaultSecurityGroup", SecurityGroupArgs.builder()        
                .vpcId(defaultNetwork.id())
                .build());
    
            var defaultInstance = new Instance("defaultInstance", InstanceArgs.builder()        
                .availabilityZone(defaultZones.applyValue(getZonesResult -> getZonesResult.zones()[0].id()))
                .instanceName(name)
                .imageId(defaultImages.applyValue(getImagesResult -> getImagesResult.images()[0].id()))
                .instanceType(defaultInstanceTypes.applyValue(getInstanceTypesResult -> getInstanceTypesResult.instanceTypes()[0].id()))
                .securityGroups(defaultSecurityGroup.id())
                .vswitchId(defaultSwitch.id())
                .internetMaxBandwidthOut("10")
                .internetChargeType("PayByTraffic")
                .instanceChargeType("PostPaid")
                .systemDiskCategory("cloud_efficiency")
                .build());
    
            var defaultCluster = new Cluster("defaultCluster", ClusterArgs.builder()        
                .clusterName(name)
                .clusterType("2")
                .networkMode("2")
                .logicalRegionId(defaultRegions.applyValue(getRegionsResult -> getRegionsResult.regions()[0].id()))
                .vpcId(defaultNetwork.id())
                .build());
    
            var defaultInstanceClusterAttachment = new InstanceClusterAttachment("defaultInstanceClusterAttachment", InstanceClusterAttachmentArgs.builder()        
                .clusterId(defaultCluster.id())
                .instanceIds(defaultInstance.id())
                .build());
    
            var defaultApplication = new Application("defaultApplication", ApplicationArgs.builder()        
                .applicationName(name)
                .clusterId(defaultCluster.id())
                .packageType("WAR")
                .build());
    
            var defaultDeployGroup = new DeployGroup("defaultDeployGroup", DeployGroupArgs.builder()        
                .appId(defaultApplication.id())
                .groupName(name)
                .build());
    
            final var defaultDeployGroups = EdasFunctions.getDeployGroups(GetDeployGroupsArgs.builder()
                .appId(defaultDeployGroup.appId())
                .build());
    
            var defaultApplicationScale = new ApplicationScale("defaultApplicationScale", ApplicationScaleArgs.builder()        
                .appId(defaultApplication.id())
                .deployGroup(defaultDeployGroups.applyValue(getDeployGroupsResult -> getDeployGroupsResult).applyValue(defaultDeployGroups -> defaultDeployGroups.applyValue(getDeployGroupsResult -> getDeployGroupsResult.groups()[0].groupId())))
                .ecuInfos(Output.tuple(defaultInstanceClusterAttachment.ecuMap(), defaultInstance.id()).applyValue(values -> {
                    var ecuMap = values.t1;
                    var id = values.t2;
                    return ecuMap[id];
                }))
                .build());
    
        }
    }
    
    Coming soon!
    

    Create ApplicationScale Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ApplicationScale(name: string, args: ApplicationScaleArgs, opts?: CustomResourceOptions);
    @overload
    def ApplicationScale(resource_name: str,
                         args: ApplicationScaleArgs,
                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def ApplicationScale(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         app_id: Optional[str] = None,
                         deploy_group: Optional[str] = None,
                         ecu_infos: Optional[Sequence[str]] = None,
                         force_status: Optional[bool] = None)
    func NewApplicationScale(ctx *Context, name string, args ApplicationScaleArgs, opts ...ResourceOption) (*ApplicationScale, error)
    public ApplicationScale(string name, ApplicationScaleArgs args, CustomResourceOptions? opts = null)
    public ApplicationScale(String name, ApplicationScaleArgs args)
    public ApplicationScale(String name, ApplicationScaleArgs args, CustomResourceOptions options)
    
    type: alicloud:edas:ApplicationScale
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args ApplicationScaleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ApplicationScaleArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ApplicationScaleArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ApplicationScaleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ApplicationScaleArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var applicationScaleResource = new AliCloud.Edas.ApplicationScale("applicationScaleResource", new()
    {
        AppId = "string",
        DeployGroup = "string",
        EcuInfos = new[]
        {
            "string",
        },
        ForceStatus = false,
    });
    
    example, err := edas.NewApplicationScale(ctx, "applicationScaleResource", &edas.ApplicationScaleArgs{
    	AppId:       pulumi.String("string"),
    	DeployGroup: pulumi.String("string"),
    	EcuInfos: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	ForceStatus: pulumi.Bool(false),
    })
    
    var applicationScaleResource = new ApplicationScale("applicationScaleResource", ApplicationScaleArgs.builder()        
        .appId("string")
        .deployGroup("string")
        .ecuInfos("string")
        .forceStatus(false)
        .build());
    
    application_scale_resource = alicloud.edas.ApplicationScale("applicationScaleResource",
        app_id="string",
        deploy_group="string",
        ecu_infos=["string"],
        force_status=False)
    
    const applicationScaleResource = new alicloud.edas.ApplicationScale("applicationScaleResource", {
        appId: "string",
        deployGroup: "string",
        ecuInfos: ["string"],
        forceStatus: false,
    });
    
    type: alicloud:edas:ApplicationScale
    properties:
        appId: string
        deployGroup: string
        ecuInfos:
            - string
        forceStatus: false
    

    ApplicationScale Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The ApplicationScale resource accepts the following input properties:

    AppId string
    The ID of the application that you want to deploy.
    DeployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    EcuInfos List<string>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    ForceStatus bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    AppId string
    The ID of the application that you want to deploy.
    DeployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    EcuInfos []string
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    ForceStatus bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId String
    The ID of the application that you want to deploy.
    deployGroup String
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    ecuInfos List<String>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus Boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId string
    The ID of the application that you want to deploy.
    deployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    ecuInfos string[]
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    app_id str
    The ID of the application that you want to deploy.
    deploy_group str
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    ecu_infos Sequence[str]
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    force_status bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId String
    The ID of the application that you want to deploy.
    deployGroup String
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    ecuInfos List<String>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus Boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ApplicationScale resource produces the following output properties:

    EccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    Id string
    The provider-assigned unique ID for this managed resource.
    EccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    Id string
    The provider-assigned unique ID for this managed resource.
    eccInfo String
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    id String
    The provider-assigned unique ID for this managed resource.
    eccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    id string
    The provider-assigned unique ID for this managed resource.
    ecc_info str
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    id str
    The provider-assigned unique ID for this managed resource.
    eccInfo String
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing ApplicationScale Resource

    Get an existing ApplicationScale resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: ApplicationScaleState, opts?: CustomResourceOptions): ApplicationScale
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            app_id: Optional[str] = None,
            deploy_group: Optional[str] = None,
            ecc_info: Optional[str] = None,
            ecu_infos: Optional[Sequence[str]] = None,
            force_status: Optional[bool] = None) -> ApplicationScale
    func GetApplicationScale(ctx *Context, name string, id IDInput, state *ApplicationScaleState, opts ...ResourceOption) (*ApplicationScale, error)
    public static ApplicationScale Get(string name, Input<string> id, ApplicationScaleState? state, CustomResourceOptions? opts = null)
    public static ApplicationScale get(String name, Output<String> id, ApplicationScaleState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AppId string
    The ID of the application that you want to deploy.
    DeployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    EccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    EcuInfos List<string>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    ForceStatus bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    AppId string
    The ID of the application that you want to deploy.
    DeployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    EccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    EcuInfos []string
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    ForceStatus bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId String
    The ID of the application that you want to deploy.
    deployGroup String
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    eccInfo String
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    ecuInfos List<String>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus Boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId string
    The ID of the application that you want to deploy.
    deployGroup string
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    eccInfo string
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    ecuInfos string[]
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    app_id str
    The ID of the application that you want to deploy.
    deploy_group str
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    ecc_info str
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    ecu_infos Sequence[str]
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    force_status bool
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.
    appId String
    The ID of the application that you want to deploy.
    deployGroup String
    The ID of the instance group to which you want to add ECS instances to scale out the application.
    eccInfo String
    The ecc information of the resource supplied above. The value is formulated as <ecc1,ecc2>.
    ecuInfos List<String>
    The IDs of the Elastic Compute Unit (ECU) where you want to deploy the application. Type: List.
    forceStatus Boolean
    This parameter specifies whether to forcibly remove an ECS instance where the application is deployed. It is set as true only after the ECS instance expires. In normal cases, this parameter do not need to be specified.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.52.1 published on Thursday, Apr 4, 2024 by Pulumi