日本熟妇hd丰满老熟妇,中文字幕一区二区三区在线不卡 ,亚洲成片在线观看,免费女同在线一区二区

ACS-ECS-ScheduleToExecuteDiagnosticReports

ACS-ECS-ScheduleToExecuteDiagnosticReports.md

Blame歷史原始文件固定地址

編輯

模板名稱

ACS-ECS-ScheduleToExecuteDiagnosticReports 定時執(zhí)行ECS健康診斷

立即執(zhí)行

模板描述

定時運行ECS健康診斷

模板類型

自動化

所有者

Alibaba Cloud

輸入?yún)?shù)

參數(shù)名稱

描述

類型

是否必填

默認值

約束

targets

ECS實例

Json

timerTrigger

定時類型

Json

{‘expression’: ‘0 0 1 ? * *’, ‘endDate’: ‘2099-12-01T00:00:00Z’, ‘type’: ‘cron’, ‘timeZone’: ‘Asia/Shanghai’}

regionId

地域ID

String

{{ ACS::RegionId }}

whetherNotify

是否通知異常結果

Boolean

False

notifyURI

通知地址

String

“”

notifyAt

通知@

String

“”

rateControl

任務執(zhí)行的并發(fā)比率

Json

{‘Mode’: ‘Concurrency,’, ‘MaxErrors’: ‘0,’, ‘Concurrency’: 10}

OOSAssumeRole

OOS扮演的RAM角色

String

“”

輸出參數(shù)

參數(shù)名稱

描述

類型

metricResults

Json

執(zhí)行此模板需要的權限策略

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

詳情

ACS-ECS-ScheduleToExecuteDiagnosticReports詳情

模板內容

FormatVersion: OOS-2019-06-01
Description:
  en: Schedules to execute ECS diagnostic reports in bulk
  zh-cn: 定時運行ECS健康診斷
  name-en: ACS-ECS-ScheduleToExecuteDiagnosticReports
  name-zh-cn: 定時執(zhí)行ECS健康診斷
  categories:
    - time_trigger
Parameters:
  timerTrigger:
    Type: Json
    Label:
      en: TimerTrigger
      zh-cn: 定時類型
    AssociationProperty: ALIYUN::OOS::Component::TimerTrigger
    AssociationPropertyMetadata:
      MinuteInterval: 30
    Default:
      expression: 0 0 1 ? * *
      endDate: '2099-12-01T00:00:00Z'
      type: cron
      timeZone: Asia/Shanghai
  regionId:
    Type: String
    Label:
      en: RegionId
      zh-cn: 地域ID
    AssociationProperty: RegionId
    Default: '{{ ACS::RegionId }}'
  targets:
    Type: Json
    Description: ECS實例
    AssociationProperty: Targets
    AssociationPropertyMetadata:
      ResourceType: ALIYUN::ECS::Instance
      RegionId: regionId
  whetherNotify:
    Type: Boolean
    Description: 是否通知
    Default: false
    Label:
      en: whether notify
      zh-cn: 是否通知異常結果
  notifyURI:
    Type: String
    Description: 通知WebHook
    AssociationProperty: TextArea
    AssociationPropertyMetadata:
      Visible:
        Condition:
          Fn::Equals:
            - ${whetherNotify}
            - true
    Label:
      en: notify uri
      zh-cn: 通知地址
    Default: ''
  notifyAt:
    Type: String
    Description: 通知@人員
    AssociationProperty: TextArea
    AssociationPropertyMetadata:
      Visible:
        Condition:
          Fn::Equals:
            - ${whetherNotify}
            - true
    Label:
      en: notify@
      zh-cn: 通知@
    Default: ''
  rateControl:
    Description: 任務執(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: timerTrigger
    Action: ACS::TimerTrigger
    Description:
      en: Triggers a task as scheduled by specifying type and expression
      zh-cn: 通過指定觸發(fā)類型和表達式按計劃觸發(fā)任務
    Properties:
      Type:
        Fn::Select:
          - type
          - '{{timerTrigger}}'
      Expression:
        Fn::Select:
          - expression
          - '{{timerTrigger}}'
      EndDate:
        Fn::Select:
          - endDate
          - '{{ timerTrigger }}'
      TimeZone: Asia/Shanghai
    Outputs: {}
  - Name: getInstances
    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: createDiagnosticReports
    Action: ACS::ECS::CreateDiagnoseReport
    Description:
      en: Create diagnostic report for ECS instance
      zh-cn: 創(chuàng)建ECS實例診斷報告
    Properties:
      regionId: '{{ regionId }}'
      resourceId: '{{ ACS::TaskLoopItem }}'
      metricSetId: dms-instancedefault
    Loop:
      Items: '{{ getInstances.instanceIds }}'
      Outputs:
        metricResults:
          AggregateType: Fn::ListJoin
          AggregateField: metricResult
      RateControl:
        MaxErrors: 0
        Mode: Concurrency
        Concurrency: 1
    Outputs:
      metricResult:
        Type: Json
        ValueSelector: .metricResults | .MetricResult = (.MetricResult[] | select(.Issues.Issue | length > 0))
  - Name: wheatherNotify
    Action: ACS::Choice
    Description:
      en: wheather notify
      zh-cn: 通知選擇
    Properties:
      DefaultTask: notify
      Choices:
        - When:
            Fn::Equals:
              - false
              - '{{ whetherNotify }}'
          NextTask: ACS::END
  - Name: notify
    Action: ACS::Notify
    Description: 通知有異常Issue的診斷報告鏈接
    Properties:
      NotifyType: WebHook
      WebHook:
        URI: '{{ notifyURI }}'
        Headers:
          Content-Type: application/json
        Content:
          msgtype: text
          text:
            type: Json
            content: '{{ createDiagnosticReports.metricResults }}'
          At: '{{ notifyAt }}'
    Outputs: {}
Outputs:
  metricResults:
    Type: Json
    Value: '{{ createDiagnosticReports.metricResults }}'
Metadata:
  ALIYUN::OOS::Interface:
    ParameterGroups:
      - Parameters:
          - timerTrigger
        Label:
          default:
            zh-cn: 設置周期參數(shù)(必填)
            en: Configure Parameters
      - Parameters:
          - regionId
          - targets
          - rateControl
        Label:
          default:
            zh-cn: 設置地域、所選實例、并發(fā)個數(shù)(必填)
            en: Configure Parameters
      - Parameters:
          - OOSAssumeRole
        Label:
          default:
            zh-cn: 設置執(zhí)行的RAM角色(必填)
            en: Configure Parameters
      - Parameters:
          - whetherNotify
          - notifyURI
          - notifyAt
        Label:
          default:
            zh-cn: 設置類釘釘?shù)膮?shù)(選填)
            en: Configure Parameters