1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. ess
  5. InstanceRefresh
Viewing docs for Alibaba Cloud v3.97.0
published on Saturday, Mar 14, 2026 by Pulumi
alicloud logo
Viewing docs for Alibaba Cloud v3.97.0
published on Saturday, Mar 14, 2026 by Pulumi

    Provides a ESS instance refresh resource.

    For information about ess instance refresh, see StartInstanceRefresh.

    NOTE: Available since v1.261.0.

    Example Usage

    Basic Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    import * as random from "@pulumi/random";
    
    const config = new pulumi.Config();
    const name = config.get("name") || "terraform-example";
    const defaultInteger = new random.index.Integer("default", {
        min: 10000,
        max: 99999,
    });
    const myName = `${name}-${defaultInteger.result}`;
    const _default = alicloud.getZones({
        availableDiskCategory: "cloud_efficiency",
        availableResourceCreation: "VSwitch",
    });
    const defaultNetwork = new alicloud.vpc.Network("default", {
        vpcName: myName,
        cidrBlock: "172.16.0.0/16",
    });
    const default1 = _default.then(_default => alicloud.ecs.getInstanceTypes({
        availabilityZone: _default.zones?.[0]?.id,
    }));
    const defaultSwitch = new alicloud.vpc.Switch("default", {
        vpcId: defaultNetwork.id,
        cidrBlock: "172.16.0.0/24",
        zoneId: _default.then(_default => _default.zones?.[0]?.id),
        vswitchName: myName,
    });
    const defaultSecurityGroup = new alicloud.ecs.SecurityGroup("default", {
        securityGroupName: myName,
        vpcId: defaultNetwork.id,
    });
    const default1GetImages = alicloud.ecs.getImages({
        nameRegex: "^ubu",
        mostRecent: true,
        owners: "system",
    });
    const default2 = alicloud.ecs.getImages({
        nameRegex: "^aliyun",
        mostRecent: true,
        owners: "system",
    });
    const defaultScalingGroup = new alicloud.ess.ScalingGroup("default", {
        minSize: 0,
        maxSize: 10,
        scalingGroupName: myName,
        removalPolicies: [
            "OldestInstance",
            "NewestInstance",
        ],
        vswitchIds: [defaultSwitch.id],
        desiredCapacity: 1,
    });
    const defaultScalingConfiguration = new alicloud.ess.ScalingConfiguration("default", {
        scalingGroupId: defaultScalingGroup.id,
        imageId: default1GetImages.then(default1GetImages => default1GetImages.images?.[0]?.id),
        instanceType: default1.then(default1 => default1.instanceTypes?.[0]?.id),
        securityGroupId: defaultSecurityGroup.id,
        forceDelete: true,
        active: true,
        enable: true,
    });
    const defaultInstanceRefresh = new alicloud.ess.InstanceRefresh("default", {
        scalingGroupId: defaultScalingConfiguration.scalingGroupId,
        desiredConfigurationImageId: default2.then(default2 => default2.images?.[0]?.id),
        minHealthyPercentage: 90,
        maxHealthyPercentage: 150,
        checkpointPauseTime: 60,
        skipMatching: false,
        checkpoints: [{
            percentage: 100,
        }],
    });
    
    import pulumi
    import pulumi_alicloud as alicloud
    import pulumi_random as random
    
    config = pulumi.Config()
    name = config.get("name")
    if name is None:
        name = "terraform-example"
    default_integer = random.index.Integer("default",
        min=10000,
        max=99999)
    my_name = f"{name}-{default_integer['result']}"
    default = alicloud.get_zones(available_disk_category="cloud_efficiency",
        available_resource_creation="VSwitch")
    default_network = alicloud.vpc.Network("default",
        vpc_name=my_name,
        cidr_block="172.16.0.0/16")
    default1 = alicloud.ecs.get_instance_types(availability_zone=default.zones[0].id)
    default_switch = alicloud.vpc.Switch("default",
        vpc_id=default_network.id,
        cidr_block="172.16.0.0/24",
        zone_id=default.zones[0].id,
        vswitch_name=my_name)
    default_security_group = alicloud.ecs.SecurityGroup("default",
        security_group_name=my_name,
        vpc_id=default_network.id)
    default1_get_images = alicloud.ecs.get_images(name_regex="^ubu",
        most_recent=True,
        owners="system")
    default2 = alicloud.ecs.get_images(name_regex="^aliyun",
        most_recent=True,
        owners="system")
    default_scaling_group = alicloud.ess.ScalingGroup("default",
        min_size=0,
        max_size=10,
        scaling_group_name=my_name,
        removal_policies=[
            "OldestInstance",
            "NewestInstance",
        ],
        vswitch_ids=[default_switch.id],
        desired_capacity=1)
    default_scaling_configuration = alicloud.ess.ScalingConfiguration("default",
        scaling_group_id=default_scaling_group.id,
        image_id=default1_get_images.images[0].id,
        instance_type=default1.instance_types[0].id,
        security_group_id=default_security_group.id,
        force_delete=True,
        active=True,
        enable=True)
    default_instance_refresh = alicloud.ess.InstanceRefresh("default",
        scaling_group_id=default_scaling_configuration.scaling_group_id,
        desired_configuration_image_id=default2.images[0].id,
        min_healthy_percentage=90,
        max_healthy_percentage=150,
        checkpoint_pause_time=60,
        skip_matching=False,
        checkpoints=[{
            "percentage": 100,
        }])
    
    package main
    
    import (
    	"fmt"
    
    	"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/ess"
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
    	"github.com/pulumi/pulumi-random/sdk/v4/go/random"
    	"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 := "terraform-example"
    		if param := cfg.Get("name"); param != "" {
    			name = param
    		}
    		defaultInteger, err := random.NewInteger(ctx, "default", &random.IntegerArgs{
    			Min: 10000,
    			Max: 99999,
    		})
    		if err != nil {
    			return err
    		}
    		myName := fmt.Sprintf("%v-%v", name, defaultInteger.Result)
    		_default, err := alicloud.GetZones(ctx, &alicloud.GetZonesArgs{
    			AvailableDiskCategory:     pulumi.StringRef("cloud_efficiency"),
    			AvailableResourceCreation: pulumi.StringRef("VSwitch"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultNetwork, err := vpc.NewNetwork(ctx, "default", &vpc.NetworkArgs{
    			VpcName:   pulumi.String(myName),
    			CidrBlock: pulumi.String("172.16.0.0/16"),
    		})
    		if err != nil {
    			return err
    		}
    		default1, err := ecs.GetInstanceTypes(ctx, &ecs.GetInstanceTypesArgs{
    			AvailabilityZone: pulumi.StringRef(_default.Zones[0].Id),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultSwitch, err := vpc.NewSwitch(ctx, "default", &vpc.SwitchArgs{
    			VpcId:       defaultNetwork.ID(),
    			CidrBlock:   pulumi.String("172.16.0.0/24"),
    			ZoneId:      pulumi.String(_default.Zones[0].Id),
    			VswitchName: pulumi.String(myName),
    		})
    		if err != nil {
    			return err
    		}
    		defaultSecurityGroup, err := ecs.NewSecurityGroup(ctx, "default", &ecs.SecurityGroupArgs{
    			SecurityGroupName: pulumi.String(myName),
    			VpcId:             defaultNetwork.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		default1GetImages, err := ecs.GetImages(ctx, &ecs.GetImagesArgs{
    			NameRegex:  pulumi.StringRef("^ubu"),
    			MostRecent: pulumi.BoolRef(true),
    			Owners:     pulumi.StringRef("system"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		default2, err := ecs.GetImages(ctx, &ecs.GetImagesArgs{
    			NameRegex:  pulumi.StringRef("^aliyun"),
    			MostRecent: pulumi.BoolRef(true),
    			Owners:     pulumi.StringRef("system"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		defaultScalingGroup, err := ess.NewScalingGroup(ctx, "default", &ess.ScalingGroupArgs{
    			MinSize:          pulumi.Int(0),
    			MaxSize:          pulumi.Int(10),
    			ScalingGroupName: pulumi.String(myName),
    			RemovalPolicies: pulumi.StringArray{
    				pulumi.String("OldestInstance"),
    				pulumi.String("NewestInstance"),
    			},
    			VswitchIds: pulumi.StringArray{
    				defaultSwitch.ID(),
    			},
    			DesiredCapacity: pulumi.Int(1),
    		})
    		if err != nil {
    			return err
    		}
    		defaultScalingConfiguration, err := ess.NewScalingConfiguration(ctx, "default", &ess.ScalingConfigurationArgs{
    			ScalingGroupId:  defaultScalingGroup.ID(),
    			ImageId:         pulumi.String(default1GetImages.Images[0].Id),
    			InstanceType:    pulumi.String(default1.InstanceTypes[0].Id),
    			SecurityGroupId: defaultSecurityGroup.ID(),
    			ForceDelete:     pulumi.Bool(true),
    			Active:          pulumi.Bool(true),
    			Enable:          pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ess.NewInstanceRefresh(ctx, "default", &ess.InstanceRefreshArgs{
    			ScalingGroupId:              defaultScalingConfiguration.ScalingGroupId,
    			DesiredConfigurationImageId: pulumi.String(default2.Images[0].Id),
    			MinHealthyPercentage:        pulumi.Int(90),
    			MaxHealthyPercentage:        pulumi.Int(150),
    			CheckpointPauseTime:         pulumi.Int(60),
    			SkipMatching:                pulumi.Bool(false),
    			Checkpoints: ess.InstanceRefreshCheckpointArray{
    				&ess.InstanceRefreshCheckpointArgs{
    					Percentage: pulumi.Int(100),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    using Random = Pulumi.Random;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var name = config.Get("name") ?? "terraform-example";
        var defaultInteger = new Random.Index.Integer("default", new()
        {
            Min = 10000,
            Max = 99999,
        });
    
        var myName = $"{name}-{defaultInteger.Result}";
    
        var @default = AliCloud.GetZones.Invoke(new()
        {
            AvailableDiskCategory = "cloud_efficiency",
            AvailableResourceCreation = "VSwitch",
        });
    
        var defaultNetwork = new AliCloud.Vpc.Network("default", new()
        {
            VpcName = myName,
            CidrBlock = "172.16.0.0/16",
        });
    
        var default1 = AliCloud.Ecs.GetInstanceTypes.Invoke(new()
        {
            AvailabilityZone = @default.Apply(getZonesResult => getZonesResult.Zones[0]?.Id),
        });
    
        var defaultSwitch = new AliCloud.Vpc.Switch("default", new()
        {
            VpcId = defaultNetwork.Id,
            CidrBlock = "172.16.0.0/24",
            ZoneId = @default.Apply(@default => @default.Apply(getZonesResult => getZonesResult.Zones[0]?.Id)),
            VswitchName = myName,
        });
    
        var defaultSecurityGroup = new AliCloud.Ecs.SecurityGroup("default", new()
        {
            SecurityGroupName = myName,
            VpcId = defaultNetwork.Id,
        });
    
        var default1GetImages = AliCloud.Ecs.GetImages.Invoke(new()
        {
            NameRegex = "^ubu",
            MostRecent = true,
            Owners = "system",
        });
    
        var default2 = AliCloud.Ecs.GetImages.Invoke(new()
        {
            NameRegex = "^aliyun",
            MostRecent = true,
            Owners = "system",
        });
    
        var defaultScalingGroup = new AliCloud.Ess.ScalingGroup("default", new()
        {
            MinSize = 0,
            MaxSize = 10,
            ScalingGroupName = myName,
            RemovalPolicies = new[]
            {
                "OldestInstance",
                "NewestInstance",
            },
            VswitchIds = new[]
            {
                defaultSwitch.Id,
            },
            DesiredCapacity = 1,
        });
    
        var defaultScalingConfiguration = new AliCloud.Ess.ScalingConfiguration("default", new()
        {
            ScalingGroupId = defaultScalingGroup.Id,
            ImageId = default1GetImages.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
            InstanceType = default1.Apply(getInstanceTypesResult => getInstanceTypesResult.InstanceTypes[0]?.Id),
            SecurityGroupId = defaultSecurityGroup.Id,
            ForceDelete = true,
            Active = true,
            Enable = true,
        });
    
        var defaultInstanceRefresh = new AliCloud.Ess.InstanceRefresh("default", new()
        {
            ScalingGroupId = defaultScalingConfiguration.ScalingGroupId,
            DesiredConfigurationImageId = default2.Apply(getImagesResult => getImagesResult.Images[0]?.Id),
            MinHealthyPercentage = 90,
            MaxHealthyPercentage = 150,
            CheckpointPauseTime = 60,
            SkipMatching = false,
            Checkpoints = new[]
            {
                new AliCloud.Ess.Inputs.InstanceRefreshCheckpointArgs
                {
                    Percentage = 100,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.random.Integer;
    import com.pulumi.random.IntegerArgs;
    import com.pulumi.alicloud.AlicloudFunctions;
    import com.pulumi.alicloud.inputs.GetZonesArgs;
    import com.pulumi.alicloud.vpc.Network;
    import com.pulumi.alicloud.vpc.NetworkArgs;
    import com.pulumi.alicloud.ecs.EcsFunctions;
    import com.pulumi.alicloud.ecs.inputs.GetInstanceTypesArgs;
    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.inputs.GetImagesArgs;
    import com.pulumi.alicloud.ess.ScalingGroup;
    import com.pulumi.alicloud.ess.ScalingGroupArgs;
    import com.pulumi.alicloud.ess.ScalingConfiguration;
    import com.pulumi.alicloud.ess.ScalingConfigurationArgs;
    import com.pulumi.alicloud.ess.InstanceRefresh;
    import com.pulumi.alicloud.ess.InstanceRefreshArgs;
    import com.pulumi.alicloud.ess.inputs.InstanceRefreshCheckpointArgs;
    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("terraform-example");
            var defaultInteger = new Integer("defaultInteger", IntegerArgs.builder()
                .min(10000)
                .max(99999)
                .build());
    
            final var myName = String.format("%s-%s", name,defaultInteger.result());
    
            final var default = AlicloudFunctions.getZones(GetZonesArgs.builder()
                .availableDiskCategory("cloud_efficiency")
                .availableResourceCreation("VSwitch")
                .build());
    
            var defaultNetwork = new Network("defaultNetwork", NetworkArgs.builder()
                .vpcName(myName)
                .cidrBlock("172.16.0.0/16")
                .build());
    
            final var default1 = EcsFunctions.getInstanceTypes(GetInstanceTypesArgs.builder()
                .availabilityZone(default_.zones()[0].id())
                .build());
    
            var defaultSwitch = new Switch("defaultSwitch", SwitchArgs.builder()
                .vpcId(defaultNetwork.id())
                .cidrBlock("172.16.0.0/24")
                .zoneId(default_.zones()[0].id())
                .vswitchName(myName)
                .build());
    
            var defaultSecurityGroup = new SecurityGroup("defaultSecurityGroup", SecurityGroupArgs.builder()
                .securityGroupName(myName)
                .vpcId(defaultNetwork.id())
                .build());
    
            final var default1GetImages = EcsFunctions.getImages(GetImagesArgs.builder()
                .nameRegex("^ubu")
                .mostRecent(true)
                .owners("system")
                .build());
    
            final var default2 = EcsFunctions.getImages(GetImagesArgs.builder()
                .nameRegex("^aliyun")
                .mostRecent(true)
                .owners("system")
                .build());
    
            var defaultScalingGroup = new ScalingGroup("defaultScalingGroup", ScalingGroupArgs.builder()
                .minSize(0)
                .maxSize(10)
                .scalingGroupName(myName)
                .removalPolicies(            
                    "OldestInstance",
                    "NewestInstance")
                .vswitchIds(defaultSwitch.id())
                .desiredCapacity(1)
                .build());
    
            var defaultScalingConfiguration = new ScalingConfiguration("defaultScalingConfiguration", ScalingConfigurationArgs.builder()
                .scalingGroupId(defaultScalingGroup.id())
                .imageId(default1GetImages.images()[0].id())
                .instanceType(default1.instanceTypes()[0].id())
                .securityGroupId(defaultSecurityGroup.id())
                .forceDelete(true)
                .active(true)
                .enable(true)
                .build());
    
            var defaultInstanceRefresh = new InstanceRefresh("defaultInstanceRefresh", InstanceRefreshArgs.builder()
                .scalingGroupId(defaultScalingConfiguration.scalingGroupId())
                .desiredConfigurationImageId(default2.images()[0].id())
                .minHealthyPercentage(90)
                .maxHealthyPercentage(150)
                .checkpointPauseTime(60)
                .skipMatching(false)
                .checkpoints(InstanceRefreshCheckpointArgs.builder()
                    .percentage(100)
                    .build())
                .build());
    
        }
    }
    
    configuration:
      name:
        type: string
        default: terraform-example
    resources:
      defaultInteger:
        type: random:Integer
        name: default
        properties:
          min: 10000
          max: 99999
      defaultNetwork:
        type: alicloud:vpc:Network
        name: default
        properties:
          vpcName: ${myName}
          cidrBlock: 172.16.0.0/16
      defaultSwitch:
        type: alicloud:vpc:Switch
        name: default
        properties:
          vpcId: ${defaultNetwork.id}
          cidrBlock: 172.16.0.0/24
          zoneId: ${default.zones[0].id}
          vswitchName: ${myName}
      defaultSecurityGroup:
        type: alicloud:ecs:SecurityGroup
        name: default
        properties:
          securityGroupName: ${myName}
          vpcId: ${defaultNetwork.id}
      defaultScalingGroup:
        type: alicloud:ess:ScalingGroup
        name: default
        properties:
          minSize: 0
          maxSize: 10
          scalingGroupName: ${myName}
          removalPolicies:
            - OldestInstance
            - NewestInstance
          vswitchIds:
            - ${defaultSwitch.id}
          desiredCapacity: 1
      defaultScalingConfiguration:
        type: alicloud:ess:ScalingConfiguration
        name: default
        properties:
          scalingGroupId: ${defaultScalingGroup.id}
          imageId: ${default1GetImages.images[0].id}
          instanceType: ${default1.instanceTypes[0].id}
          securityGroupId: ${defaultSecurityGroup.id}
          forceDelete: true
          active: true
          enable: true
      defaultInstanceRefresh:
        type: alicloud:ess:InstanceRefresh
        name: default
        properties:
          scalingGroupId: ${defaultScalingConfiguration.scalingGroupId}
          desiredConfigurationImageId: ${default2.images[0].id}
          minHealthyPercentage: 90
          maxHealthyPercentage: 150
          checkpointPauseTime: 60
          skipMatching: false
          checkpoints:
            - percentage: 100
    variables:
      myName: ${name}-${defaultInteger.result}
      default:
        fn::invoke:
          function: alicloud:getZones
          arguments:
            availableDiskCategory: cloud_efficiency
            availableResourceCreation: VSwitch
      default1:
        fn::invoke:
          function: alicloud:ecs:getInstanceTypes
          arguments:
            availabilityZone: ${default.zones[0].id}
      default1GetImages:
        fn::invoke:
          function: alicloud:ecs:getImages
          arguments:
            nameRegex: ^ubu
            mostRecent: true
            owners: system
      default2:
        fn::invoke:
          function: alicloud:ecs:getImages
          arguments:
            nameRegex: ^aliyun
            mostRecent: true
            owners: system
    

    Deleting alicloud.ess.InstanceRefresh or removing it from your configuration

    The alicloud.ess.InstanceRefresh resource allows you to manage status = "RollbackInProgress" instance refresh, but Terraform cannot destroy it. Deleting will remove it from your state file and management, but will not destroy the Instance Refresh. You can resume managing the instance refresh via the AlibabaCloud Console.

    📚 Need more examples? VIEW MORE EXAMPLES

    Create InstanceRefresh Resource

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

    Constructor syntax

    new InstanceRefresh(name: string, args: InstanceRefreshArgs, opts?: CustomResourceOptions);
    @overload
    def InstanceRefresh(resource_name: str,
                        args: InstanceRefreshArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def InstanceRefresh(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        scaling_group_id: Optional[str] = None,
                        checkpoint_pause_time: Optional[int] = None,
                        checkpoints: Optional[Sequence[InstanceRefreshCheckpointArgs]] = None,
                        desired_configuration_containers: Optional[Sequence[InstanceRefreshDesiredConfigurationContainerArgs]] = None,
                        desired_configuration_image_id: Optional[str] = None,
                        desired_configuration_launch_template_id: Optional[str] = None,
                        desired_configuration_launch_template_overrides: Optional[Sequence[InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs]] = None,
                        desired_configuration_launch_template_version: Optional[str] = None,
                        max_healthy_percentage: Optional[int] = None,
                        min_healthy_percentage: Optional[int] = None,
                        skip_matching: Optional[bool] = None,
                        status: Optional[str] = None)
    func NewInstanceRefresh(ctx *Context, name string, args InstanceRefreshArgs, opts ...ResourceOption) (*InstanceRefresh, error)
    public InstanceRefresh(string name, InstanceRefreshArgs args, CustomResourceOptions? opts = null)
    public InstanceRefresh(String name, InstanceRefreshArgs args)
    public InstanceRefresh(String name, InstanceRefreshArgs args, CustomResourceOptions options)
    
    type: alicloud:ess:InstanceRefresh
    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 InstanceRefreshArgs
    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 InstanceRefreshArgs
    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 InstanceRefreshArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args InstanceRefreshArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args InstanceRefreshArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

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

    var instanceRefreshResource = new AliCloud.Ess.InstanceRefresh("instanceRefreshResource", new()
    {
        ScalingGroupId = "string",
        CheckpointPauseTime = 0,
        Checkpoints = new[]
        {
            new AliCloud.Ess.Inputs.InstanceRefreshCheckpointArgs
            {
                Percentage = 0,
            },
        },
        DesiredConfigurationContainers = new[]
        {
            new AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationContainerArgs
            {
                Args = new[]
                {
                    "string",
                },
                Commands = new[]
                {
                    "string",
                },
                EnvironmentVars = new[]
                {
                    new AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationContainerEnvironmentVarArgs
                    {
                        FieldRefFieldPath = "string",
                        Key = "string",
                        Value = "string",
                    },
                },
                Image = "string",
                Name = "string",
            },
        },
        DesiredConfigurationImageId = "string",
        DesiredConfigurationLaunchTemplateId = "string",
        DesiredConfigurationLaunchTemplateOverrides = new[]
        {
            new AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs
            {
                InstanceType = "string",
            },
        },
        DesiredConfigurationLaunchTemplateVersion = "string",
        MaxHealthyPercentage = 0,
        MinHealthyPercentage = 0,
        SkipMatching = false,
        Status = "string",
    });
    
    example, err := ess.NewInstanceRefresh(ctx, "instanceRefreshResource", &ess.InstanceRefreshArgs{
    	ScalingGroupId:      pulumi.String("string"),
    	CheckpointPauseTime: pulumi.Int(0),
    	Checkpoints: ess.InstanceRefreshCheckpointArray{
    		&ess.InstanceRefreshCheckpointArgs{
    			Percentage: pulumi.Int(0),
    		},
    	},
    	DesiredConfigurationContainers: ess.InstanceRefreshDesiredConfigurationContainerArray{
    		&ess.InstanceRefreshDesiredConfigurationContainerArgs{
    			Args: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    			Commands: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    			EnvironmentVars: ess.InstanceRefreshDesiredConfigurationContainerEnvironmentVarArray{
    				&ess.InstanceRefreshDesiredConfigurationContainerEnvironmentVarArgs{
    					FieldRefFieldPath: pulumi.String("string"),
    					Key:               pulumi.String("string"),
    					Value:             pulumi.String("string"),
    				},
    			},
    			Image: pulumi.String("string"),
    			Name:  pulumi.String("string"),
    		},
    	},
    	DesiredConfigurationImageId:          pulumi.String("string"),
    	DesiredConfigurationLaunchTemplateId: pulumi.String("string"),
    	DesiredConfigurationLaunchTemplateOverrides: ess.InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArray{
    		&ess.InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs{
    			InstanceType: pulumi.String("string"),
    		},
    	},
    	DesiredConfigurationLaunchTemplateVersion: pulumi.String("string"),
    	MaxHealthyPercentage:                      pulumi.Int(0),
    	MinHealthyPercentage:                      pulumi.Int(0),
    	SkipMatching:                              pulumi.Bool(false),
    	Status:                                    pulumi.String("string"),
    })
    
    var instanceRefreshResource = new InstanceRefresh("instanceRefreshResource", InstanceRefreshArgs.builder()
        .scalingGroupId("string")
        .checkpointPauseTime(0)
        .checkpoints(InstanceRefreshCheckpointArgs.builder()
            .percentage(0)
            .build())
        .desiredConfigurationContainers(InstanceRefreshDesiredConfigurationContainerArgs.builder()
            .args("string")
            .commands("string")
            .environmentVars(InstanceRefreshDesiredConfigurationContainerEnvironmentVarArgs.builder()
                .fieldRefFieldPath("string")
                .key("string")
                .value("string")
                .build())
            .image("string")
            .name("string")
            .build())
        .desiredConfigurationImageId("string")
        .desiredConfigurationLaunchTemplateId("string")
        .desiredConfigurationLaunchTemplateOverrides(InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs.builder()
            .instanceType("string")
            .build())
        .desiredConfigurationLaunchTemplateVersion("string")
        .maxHealthyPercentage(0)
        .minHealthyPercentage(0)
        .skipMatching(false)
        .status("string")
        .build());
    
    instance_refresh_resource = alicloud.ess.InstanceRefresh("instanceRefreshResource",
        scaling_group_id="string",
        checkpoint_pause_time=0,
        checkpoints=[{
            "percentage": 0,
        }],
        desired_configuration_containers=[{
            "args": ["string"],
            "commands": ["string"],
            "environment_vars": [{
                "field_ref_field_path": "string",
                "key": "string",
                "value": "string",
            }],
            "image": "string",
            "name": "string",
        }],
        desired_configuration_image_id="string",
        desired_configuration_launch_template_id="string",
        desired_configuration_launch_template_overrides=[{
            "instance_type": "string",
        }],
        desired_configuration_launch_template_version="string",
        max_healthy_percentage=0,
        min_healthy_percentage=0,
        skip_matching=False,
        status="string")
    
    const instanceRefreshResource = new alicloud.ess.InstanceRefresh("instanceRefreshResource", {
        scalingGroupId: "string",
        checkpointPauseTime: 0,
        checkpoints: [{
            percentage: 0,
        }],
        desiredConfigurationContainers: [{
            args: ["string"],
            commands: ["string"],
            environmentVars: [{
                fieldRefFieldPath: "string",
                key: "string",
                value: "string",
            }],
            image: "string",
            name: "string",
        }],
        desiredConfigurationImageId: "string",
        desiredConfigurationLaunchTemplateId: "string",
        desiredConfigurationLaunchTemplateOverrides: [{
            instanceType: "string",
        }],
        desiredConfigurationLaunchTemplateVersion: "string",
        maxHealthyPercentage: 0,
        minHealthyPercentage: 0,
        skipMatching: false,
        status: "string",
    });
    
    type: alicloud:ess:InstanceRefresh
    properties:
        checkpointPauseTime: 0
        checkpoints:
            - percentage: 0
        desiredConfigurationContainers:
            - args:
                - string
              commands:
                - string
              environmentVars:
                - fieldRefFieldPath: string
                  key: string
                  value: string
              image: string
              name: string
        desiredConfigurationImageId: string
        desiredConfigurationLaunchTemplateId: string
        desiredConfigurationLaunchTemplateOverrides:
            - instanceType: string
        desiredConfigurationLaunchTemplateVersion: string
        maxHealthyPercentage: 0
        minHealthyPercentage: 0
        scalingGroupId: string
        skipMatching: false
        status: string
    

    InstanceRefresh Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The InstanceRefresh resource accepts the following input properties:

    ScalingGroupId string
    The ID of the scaling group.
    CheckpointPauseTime int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    Checkpoints List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshCheckpoint>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    DesiredConfigurationContainers List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationContainer>
    The list of containers in the instance. See desired_configuration_containers below for details.
    DesiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    DesiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    DesiredConfigurationLaunchTemplateOverrides List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationLaunchTemplateOverride>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    DesiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    MaxHealthyPercentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    MinHealthyPercentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    SkipMatching bool
    Indicates whether to skip instances that match the desired configuration.
    Status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    ScalingGroupId string
    The ID of the scaling group.
    CheckpointPauseTime int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    Checkpoints []InstanceRefreshCheckpointArgs
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    DesiredConfigurationContainers []InstanceRefreshDesiredConfigurationContainerArgs
    The list of containers in the instance. See desired_configuration_containers below for details.
    DesiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    DesiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    DesiredConfigurationLaunchTemplateOverrides []InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    DesiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    MaxHealthyPercentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    MinHealthyPercentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    SkipMatching bool
    Indicates whether to skip instances that match the desired configuration.
    Status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    scalingGroupId String
    The ID of the scaling group.
    checkpointPauseTime Integer
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints List<InstanceRefreshCheckpoint>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers List<InstanceRefreshDesiredConfigurationContainer>
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId String
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId String
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides List<InstanceRefreshDesiredConfigurationLaunchTemplateOverride>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion String
    The version of the launch template.
    maxHealthyPercentage Integer
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage Integer
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    skipMatching Boolean
    Indicates whether to skip instances that match the desired configuration.
    status String
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    scalingGroupId string
    The ID of the scaling group.
    checkpointPauseTime number
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints InstanceRefreshCheckpoint[]
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers InstanceRefreshDesiredConfigurationContainer[]
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides InstanceRefreshDesiredConfigurationLaunchTemplateOverride[]
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    maxHealthyPercentage number
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage number
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    skipMatching boolean
    Indicates whether to skip instances that match the desired configuration.
    status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    scaling_group_id str
    The ID of the scaling group.
    checkpoint_pause_time int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints Sequence[InstanceRefreshCheckpointArgs]
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desired_configuration_containers Sequence[InstanceRefreshDesiredConfigurationContainerArgs]
    The list of containers in the instance. See desired_configuration_containers below for details.
    desired_configuration_image_id str
    The ID of the image file. This is the image resource used for automatic instance creation.
    desired_configuration_launch_template_id str
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desired_configuration_launch_template_overrides Sequence[InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs]
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desired_configuration_launch_template_version str
    The version of the launch template.
    max_healthy_percentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    min_healthy_percentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    skip_matching bool
    Indicates whether to skip instances that match the desired configuration.
    status str
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    scalingGroupId String
    The ID of the scaling group.
    checkpointPauseTime Number
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints List<Property Map>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers List<Property Map>
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId String
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId String
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides List<Property Map>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion String
    The version of the launch template.
    maxHealthyPercentage Number
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage Number
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    skipMatching Boolean
    Indicates whether to skip instances that match the desired configuration.
    status String
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing InstanceRefresh Resource

    Get an existing InstanceRefresh 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?: InstanceRefreshState, opts?: CustomResourceOptions): InstanceRefresh
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            checkpoint_pause_time: Optional[int] = None,
            checkpoints: Optional[Sequence[InstanceRefreshCheckpointArgs]] = None,
            desired_configuration_containers: Optional[Sequence[InstanceRefreshDesiredConfigurationContainerArgs]] = None,
            desired_configuration_image_id: Optional[str] = None,
            desired_configuration_launch_template_id: Optional[str] = None,
            desired_configuration_launch_template_overrides: Optional[Sequence[InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs]] = None,
            desired_configuration_launch_template_version: Optional[str] = None,
            max_healthy_percentage: Optional[int] = None,
            min_healthy_percentage: Optional[int] = None,
            scaling_group_id: Optional[str] = None,
            skip_matching: Optional[bool] = None,
            status: Optional[str] = None) -> InstanceRefresh
    func GetInstanceRefresh(ctx *Context, name string, id IDInput, state *InstanceRefreshState, opts ...ResourceOption) (*InstanceRefresh, error)
    public static InstanceRefresh Get(string name, Input<string> id, InstanceRefreshState? state, CustomResourceOptions? opts = null)
    public static InstanceRefresh get(String name, Output<String> id, InstanceRefreshState state, CustomResourceOptions options)
    resources:  _:    type: alicloud:ess:InstanceRefresh    get:      id: ${id}
    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:
    CheckpointPauseTime int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    Checkpoints List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshCheckpoint>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    DesiredConfigurationContainers List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationContainer>
    The list of containers in the instance. See desired_configuration_containers below for details.
    DesiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    DesiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    DesiredConfigurationLaunchTemplateOverrides List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationLaunchTemplateOverride>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    DesiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    MaxHealthyPercentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    MinHealthyPercentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    ScalingGroupId string
    The ID of the scaling group.
    SkipMatching bool
    Indicates whether to skip instances that match the desired configuration.
    Status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    CheckpointPauseTime int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    Checkpoints []InstanceRefreshCheckpointArgs
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    DesiredConfigurationContainers []InstanceRefreshDesiredConfigurationContainerArgs
    The list of containers in the instance. See desired_configuration_containers below for details.
    DesiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    DesiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    DesiredConfigurationLaunchTemplateOverrides []InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    DesiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    MaxHealthyPercentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    MinHealthyPercentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    ScalingGroupId string
    The ID of the scaling group.
    SkipMatching bool
    Indicates whether to skip instances that match the desired configuration.
    Status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    checkpointPauseTime Integer
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints List<InstanceRefreshCheckpoint>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers List<InstanceRefreshDesiredConfigurationContainer>
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId String
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId String
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides List<InstanceRefreshDesiredConfigurationLaunchTemplateOverride>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion String
    The version of the launch template.
    maxHealthyPercentage Integer
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage Integer
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    scalingGroupId String
    The ID of the scaling group.
    skipMatching Boolean
    Indicates whether to skip instances that match the desired configuration.
    status String
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    checkpointPauseTime number
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints InstanceRefreshCheckpoint[]
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers InstanceRefreshDesiredConfigurationContainer[]
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId string
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId string
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides InstanceRefreshDesiredConfigurationLaunchTemplateOverride[]
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion string
    The version of the launch template.
    maxHealthyPercentage number
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage number
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    scalingGroupId string
    The ID of the scaling group.
    skipMatching boolean
    Indicates whether to skip instances that match the desired configuration.
    status string
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    checkpoint_pause_time int
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints Sequence[InstanceRefreshCheckpointArgs]
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desired_configuration_containers Sequence[InstanceRefreshDesiredConfigurationContainerArgs]
    The list of containers in the instance. See desired_configuration_containers below for details.
    desired_configuration_image_id str
    The ID of the image file. This is the image resource used for automatic instance creation.
    desired_configuration_launch_template_id str
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desired_configuration_launch_template_overrides Sequence[InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs]
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desired_configuration_launch_template_version str
    The version of the launch template.
    max_healthy_percentage int
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    min_healthy_percentage int
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    scaling_group_id str
    The ID of the scaling group.
    skip_matching bool
    Indicates whether to skip instances that match the desired configuration.
    status str
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.
    checkpointPauseTime Number
    The duration of the pause when the task reaches a checkpoint. Unit: minutes.
    checkpoints List<Property Map>
    The checkpoints for the refresh task. The task automatically pauses for the duration specified by CheckpointPauseTime when the percentage of new instances reaches a specified value. See checkpoints below for details.
    desiredConfigurationContainers List<Property Map>
    The list of containers in the instance. See desired_configuration_containers below for details.
    desiredConfigurationImageId String
    The ID of the image file. This is the image resource used for automatic instance creation.
    desiredConfigurationLaunchTemplateId String
    The ID of the launch template. The scaling group uses this template to obtain launch configuration information.
    desiredConfigurationLaunchTemplateOverrides List<Property Map>
    The instance type information in the launch template overrides. See desired_configuration_launch_template_overrides below for details.
    desiredConfigurationLaunchTemplateVersion String
    The version of the launch template.
    maxHealthyPercentage Number
    The percentage by which the number of instances in the scaling group can exceed the group's capacity during the instance refresh.
    minHealthyPercentage Number
    The percentage of instances that must be healthy in the scaling group during the instance refresh. The value is a percentage of the scaling group's capacity.
    scalingGroupId String
    The ID of the scaling group.
    skipMatching Boolean
    Indicates whether to skip instances that match the desired configuration.
    status String
    The current status of the instance refresh task. Possible values:

    • Pending: The instance refresh task is created and waiting to be scheduled.
    • InProgress: The instance refresh task is in progress.
    • Paused: The instance refresh task is paused.
    • CheckpointPause: The task is paused because it has reached a checkpoint (Checkpoint.Percentage).
    • Failed: The instance refresh task failed.
    • Successful: The instance refresh task was successful.
    • Cancelling: The instance refresh task is being canceled.
    • RollbackInProgress: The instance refresh task is being rolled back.
    • RollbackSuccessful: The instance refresh task was rolled back successfully. Set RollbackSuccessful to rollback the instance refresh task.
    • RollbackFailed: The rollback of the instance refresh task failed.
    • Cancelled: The instance refresh task is canceled. Set Cancelled to cancel the instance refresh task.

    Supporting Types

    InstanceRefreshCheckpoint, InstanceRefreshCheckpointArgs

    Percentage int
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.
    Percentage int
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.
    percentage Integer
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.
    percentage number
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.
    percentage int
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.
    percentage Number
    The percentage of new instances out of the total instances in the scaling group. The task automatically pauses when this percentage is reached.

    InstanceRefreshDesiredConfigurationContainer, InstanceRefreshDesiredConfigurationContainerArgs

    Args List<string>
    The arguments for the container startup command.
    Commands List<string>
    The container startup command.
    EnvironmentVars List<Pulumi.AliCloud.Ess.Inputs.InstanceRefreshDesiredConfigurationContainerEnvironmentVar>
    Information about the environment variables. See environment_vars below for details.
    Image string
    The container image.
    Name string
    The custom name of the container.
    Args []string
    The arguments for the container startup command.
    Commands []string
    The container startup command.
    EnvironmentVars []InstanceRefreshDesiredConfigurationContainerEnvironmentVar
    Information about the environment variables. See environment_vars below for details.
    Image string
    The container image.
    Name string
    The custom name of the container.
    args List<String>
    The arguments for the container startup command.
    commands List<String>
    The container startup command.
    environmentVars List<InstanceRefreshDesiredConfigurationContainerEnvironmentVar>
    Information about the environment variables. See environment_vars below for details.
    image String
    The container image.
    name String
    The custom name of the container.
    args string[]
    The arguments for the container startup command.
    commands string[]
    The container startup command.
    environmentVars InstanceRefreshDesiredConfigurationContainerEnvironmentVar[]
    Information about the environment variables. See environment_vars below for details.
    image string
    The container image.
    name string
    The custom name of the container.
    args Sequence[str]
    The arguments for the container startup command.
    commands Sequence[str]
    The container startup command.
    environment_vars Sequence[InstanceRefreshDesiredConfigurationContainerEnvironmentVar]
    Information about the environment variables. See environment_vars below for details.
    image str
    The container image.
    name str
    The custom name of the container.
    args List<String>
    The arguments for the container startup command.
    commands List<String>
    The container startup command.
    environmentVars List<Property Map>
    Information about the environment variables. See environment_vars below for details.
    image String
    The container image.
    name String
    The custom name of the container.

    InstanceRefreshDesiredConfigurationContainerEnvironmentVar, InstanceRefreshDesiredConfigurationContainerEnvironmentVarArgs

    FieldRefFieldPath string
    This parameter is not available for use.
    Key string
    The name of the environment variable.
    Value string
    The value of the environment variable.
    FieldRefFieldPath string
    This parameter is not available for use.
    Key string
    The name of the environment variable.
    Value string
    The value of the environment variable.
    fieldRefFieldPath String
    This parameter is not available for use.
    key String
    The name of the environment variable.
    value String
    The value of the environment variable.
    fieldRefFieldPath string
    This parameter is not available for use.
    key string
    The name of the environment variable.
    value string
    The value of the environment variable.
    field_ref_field_path str
    This parameter is not available for use.
    key str
    The name of the environment variable.
    value str
    The value of the environment variable.
    fieldRefFieldPath String
    This parameter is not available for use.
    key String
    The name of the environment variable.
    value String
    The value of the environment variable.

    InstanceRefreshDesiredConfigurationLaunchTemplateOverride, InstanceRefreshDesiredConfigurationLaunchTemplateOverrideArgs

    InstanceType string
    The specified instance type, which overwrites the instance type in the launch template.
    InstanceType string
    The specified instance type, which overwrites the instance type in the launch template.
    instanceType String
    The specified instance type, which overwrites the instance type in the launch template.
    instanceType string
    The specified instance type, which overwrites the instance type in the launch template.
    instance_type str
    The specified instance type, which overwrites the instance type in the launch template.
    instanceType String
    The specified instance type, which overwrites the instance type in the launch template.

    Import

    ESS instance refresh can be imported using the id, e.g.

    $ pulumi import alicloud:ess/instanceRefresh:InstanceRefresh example ir-abc123456
    

    To learn more about importing existing cloud resources, see Importing resources.

    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
    Viewing docs for Alibaba Cloud v3.97.0
    published on Saturday, Mar 14, 2026 by Pulumi
      Try Pulumi Cloud free. Your team will thank you.