ACS-ECS-BulkyModifyPostPaidInstanceSpec
模板名稱
ACS-ECS-BulkyModifyPostPaidInstanceSpec 批量修改按量付費ECS實例的實例規(guī)格
模板描述
批量修改按量付費ECS實例的實例規(guī)格
模板類型
自動化
所有者
Alibaba Cloud
輸入?yún)?shù)
參數(shù)名稱 | 描述 | 類型 | 是否必填 | 默認(rèn)值 | 約束 |
targets | 目標(biāo)實例 | Json | 是 | ||
instanceType | 實例類型 | String | 是 | ||
regionId | 地域ID | String | 否 | {{ ACS::RegionId }} | |
rateControl | 任務(wù)執(zhí)行的并發(fā)比率 | Json | 否 | {‘Mode’: ‘Concurrency’, ‘MaxErrors’: 0, ‘Concurrency’: 10} | |
OOSAssumeRole | OOS扮演的RAM角色 | String | 否 | “” |
輸出參數(shù)
無
執(zhí)行此模板需要的權(quán)限策略
{
"Version": "1",
"Statement": [
{
"Action": [
"ecs:DescribeInstances",
"ecs:ModifyInstanceSpec",
"ecs:StartInstance",
"ecs:StopInstance"
],
"Resource": "*",
"Effect": "Allow"
}
]
}
詳情
ACS-ECS-BulkyModifyPostPaidInstanceSpec詳情
模板內(nèi)容
FormatVersion: OOS-2019-06-01
Description:
en: Bulky modify postpaid instance spec
zh-cn: 批量修改按量付費ECS實例的實例規(guī)格
name-en: ACS-ECS-BulkyModifyPostPaidInstanceSpec
name-zh-cn: 批量修改按量付費ECS實例的實例規(guī)格
categories:
- instance_manage
- computenest
Parameters:
regionId:
Type: String
Label:
en: RegionId
zh-cn: 地域ID
AssociationProperty: RegionId
Default: '{{ ACS::RegionId }}'
targets:
Type: Json
Label:
en: TargetInstance
zh-cn: 目標(biāo)實例
AssociationProperty: Targets
AssociationPropertyMetadata:
ResourceType: 'ALIYUN::ECS::Instance'
RegionId: regionId
instanceType:
Label:
en: InstanceType
zh-cn: 實例類型
Type: String
AssociationProperty: 'ALIYUN::ECS::Instance::InstanceType'
rateControl:
Label:
en: RateControl
zh-cn: 任務(wù)執(zhí)行的并發(fā)比率
Type: Json
AssociationProperty: RateControl
Default:
Mode: Concurrency
MaxErrors: 0
Concurrency: 10
OOSAssumeRole:
Label:
en: OOSAssumeRole
zh-cn: OOS扮演的RAM角色
Type: String
Default: ''
RamRole: '{{ OOSAssumeRole }}'
Tasks:
- Name: getInstance
Description:
en: Views the ECS instances
zh-cn: 獲取ECS實例
Action: 'ACS::SelectTargets'
Properties:
ResourceType: 'ALIYUN::ECS::Instance'
RegionId: '{{ regionId }}'
Filters:
- '{{ targets }}'
Outputs:
instanceIds:
Type: List
ValueSelector: 'Instances.Instance[].InstanceId'
- Name: modifyPostPaidInstanceSpec
Action: ACS::ECS::ModifyInstanceSpec
Description:
en: Modify the type of postpaid instance
zh-cn: 修改按量付費實例的實例規(guī)格
Properties:
regionId: '{{ regionId }}'
instanceId: '{{ ACS::TaskLoopItem }}'
instanceType: '{{ instanceType }}'
Loop:
RateControl: '{{ rateControl }}'
Items: '{{ getInstance.instanceIds }}'
Metadata:
ALIYUN::OOS::Interface:
ParameterGroups:
- Parameters:
- instanceType
Label:
default:
zh-cn: 設(shè)置參數(shù)
en: Configure Parameters
- Parameters:
- regionId
- targets
Label:
default:
zh-cn: 選擇實例
en: Select ECS Instances
- Parameters:
- rateControl
- OOSAssumeRole
Label:
default:
zh-cn: 高級選項
en: Control Options
文檔內(nèi)容是否對您有幫助?