All Products
Search
Document Center

CloudOps Orchestration Service:ACS-ECS-BulkyResizeDisk

Last Updated:Nov 25, 2024

Template name

ACS-ECS-BulkyResizeDisk

Execute Now

Template description

Resizes multiple disks at a time.

Template type

Automated

Owner

Alibaba Cloud

Input parameters

Parameter

Description

Type

Required

Default value

Limit

diskIds

The IDs of disks to be resized.

List

Yes

newSize

The disk capacity after the disks are resized.

Number

Yes

regionId

The region ID.

String

No

{{ ACS::RegionId }}

type

The method to be used to resize the disks.

String

No

offline

rateControl

The rate control settings.

Json

No

{'Mode': 'Concurrency', 'MaxErrors': 0, 'Concurrency': 10}

OOSAssumeRole

The Resource Access Management (RAM) role that is assumed by CloudOps Orchestration Service (OOS).

String

No

""

Output parameters

None

Permission policy that is required to execute the template

{
    "Version": "1",
    "Statement": [
        {
            "Action": [
                "ecs:ResizeDisk"
            ],
            "Resource": "*",
            "Effect": "Allow"
        }
    ]
}

References

For more information, see ACS-ECS-BulkyResizeDisk.yml at GitHub.

Template content

FormatVersion: OOS-2019-06-01
Description:
  en: Bulky resize disk
  zh-cn: the description in Chinese
  name-en: ACS-ECS-BulkyResizeDisk
  name-zh-cn: the description in Chinese
  categories:
    - instance_manage
    - computenest
Parameters:
  regionId:
    Type: String
    Label:
      en: RegionId
      zh-cn: the description in Chinese
    AssociationProperty: RegionId
    Default: '{{ ACS::RegionId }}'
  diskIds:
    Label:
      en: DiskIds
      zh-cn: the description in Chinese
    AssociationProperty: ALIYUN::ECS::Disk::DiskId
    AssociationPropertyMetadata:
      RegionId: regionId
    Type: List
  newSize:
    Label:
      en: NewSize
      zh-cn: the description in Chinese
    Type: Number
    MinValue: 20
    MaxValue: 32768
  type:
    Label:
      en: Type
      zh-cn: the description in Chinese
    Description:
      en: < p class = "P" > value range:</p>
        <ul class="ul">
        < Li class = "Li" > offline (default):offline capacity expansion. After capacity expansion, you must restart the instance on the console or call the API to make the operation effective</ li>
        < Li class = "Li" > online:online capacity expansion, which can be completed without restarting the instance. The cloud disk type supports efficient cloud disk, SSD cloud disk and ESSD cloud disk</ li>
        </ul>
      zh-cn: the description in Chinese
        <ul class="ul">
          </li>
          </li>
        </ul>
    Type: String
    AllowedValues:
      - online
      - offline
    Default: offline
  rateControl:
    Label:
      en: RateControl
      zh-cn: the description in Chinese
    Type: Json
    AssociationProperty: RateControl
    Default:
      Mode: Concurrency
      MaxErrors: 0
      Concurrency: 10
  OOSAssumeRole:
    Label:
      en: OOSAssumeRole
      zh-cn: the description in Chinese
    Type: String
    Default: ''
RamRole: '{{ OOSAssumeRole }}'
Tasks:
- Name: resizeDisk
  Action: ACS::ExecuteApi
  Description:
    en: Resize disk
    zh-cn: the description in Chinese
  Properties:
    Service: ECS
    API: ResizeDisk
    Parameters:
      RegionId: '{{ regionId }}'
      DiskId: '{{ ACS::TaskLoopItem }}'
      NewSize: '{{ newSize }}'
      Type: '{{ type }}'
  Loop:
    RateControl: '{{ rateControl }}'
    Items: '{{ diskIds }}'
Metadata:
  ALIYUN::OOS::Interface:
    ParameterGroups:
      - Parameters:
          - regionId
          - diskIds
          - newSize
          - type
        Label:
          default:
            zh-cn: the description in Chinese
            en: Configure Parameters
      - Parameters:
          - rateControl
          - OOSAssumeRole
        Label:
          default:
            zh-cn: the description in Chinese
            en: Control Options