全部产品
Search
文档中心

CloudOps Orchestration Service:ACS-CS-BulkyEnableDeletionProtection

更新时间:Jun 28, 2025

Nama template

ACS-CS-BulkyEnableDeletionProtection

Jalankan Sekarang

Deskripsi template

Mengaktifkan perlindungan penghapusan untuk kluster.

Tipe template

Otomatis

Pemilik

Alibaba Cloud

Parameter input

Parameter

Deskripsi

Tipe

Diperlukan

Nilai default

Batasan

clusterIds

ID dari kluster.

Daftar

Ya

regionId

ID wilayah.

String

Tidak

{{ ACS::RegionId }}

rateControl

Pengaturan kontrol laju.

Json

Tidak

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

OOSAssumeRole

Peran RAM yang diasumsikan oleh CloudOps Orchestration Service (OOS).

String

Tidak

""

Parameter output

Tidak ada

Kebijakan izin yang diperlukan untuk mengeksekusi template

{
    "Version": "1",
    "Statement": [
        {
            "Action": [
                "cs:ModifyCluster"
            ],
            "Resource": "*",
            "Effect": "Allow"
        }
    ]
}

Referensi

Untuk informasi lebih lanjut, lihat ACS-CS-BulkyEnableDeletionProtection.yml di GitHub.

Konten Template

FormatVersion: OOS-2019-06-01
Description:
  en: Enable deletion protection for the cluster
   
  name-en: ACS-CS-BulkyEnableDeletionProtection
   
  categories:
    - security
Parameters:
  regionId:
    Label:
      en: RegionId
       
    Type: String
    AssociationProperty: RegionId
    Default: '{{ ACS::RegionId }}'
  clusterIds:
    Label:
      en: Cluster Ids
       
    Type: List
  rateControl:
    Label:
      en: RateControl
       
    Type: Json
    AssociationProperty: RateControl
    Default:
      Mode: Concurrency
      MaxErrors: 0
      Concurrency: 10
  OOSAssumeRole:
    Label:
      en: OOSAssumeRole
       
    Type: String
    Default: ''
RamRole: '{{ OOSAssumeRole }}'
Tasks:
  - Name: modifyCluster
    Action: ACS::ExecuteAPI
    Properties:
      Service: CS
      API: ModifyCluster
      Method: PUT
      URI: /api/v2/clusters/{{ ACS::TaskLoopItem }}
      Parameters: null
      Body: '{"deletion_protection":true}'
    Description:
      en: Executes a command in cluster
       
    Loop:
      RateControl: '{{ rateControl }}'
      Items: '{{ clusterIds }}'
Metadata:
  ALIYUN::OOS::Interface:
    ParameterGroups:
      - Parameters:
          - clusterIds
          - regionId
        Label:
          default:
             
            en: Configure Parameters
      - Parameters:
          - OOSAssumeRole
        Label:
          default:
             
            en: Control Options