全部產品
Search
文件中心

:ALIYUN::OOS::PatchBaseline

更新時間:Jun 19, 2024

ALIYUN::OOS::PatchBaseline類型用於建立一個補丁基準。

文法

{
  "Type": "ALIYUN::OOS::PatchBaseline",
  "Properties": {
    "Description": String,
    "PatchBaselineName": String,
    "OperationSystem": String,
    "ApprovalRules": Map,
    "RejectedPatchesAction": String,
    "Sources": List,
    "ResourceGroupId": String,
    "ApprovedPatchesEnableNonSecurity": Boolean,
    "RejectedPatches": List,
    "ApprovedPatches": List,
    "Tags": List
  }
}

屬性

屬性名稱

類型

必須

允許更新

描述

約束

Description

String

補丁基準描述資訊。

PatchBaselineName

String

補丁基準名稱。

OperationSystem

String

作業系統類型。

取值:

  • Windows

  • Ubuntu

  • CentOS

  • Debian

  • AliyunLinux

  • RedhatEnterpriseLinux

  • Anolis

  • AlmaLinux

ApprovalRules

Map

接受規則。

RejectedPatchesAction

String

拒絕補丁的操作。

Sources

List

補丁源配置列表。

ResourceGroupId

String

資源群組ID。

ApprovedPatchesEnableNonSecurity

Boolean

批准補丁是否包括除安全性之外的更新。

RejectedPatches

List

拒絕補丁的名稱。

ApprovedPatches

List

批准補丁的列表。

Tags

List

標籤列表。

更多資訊,請參見Tags屬性

Tags文法

"Tags": [
  {
    "Key": String,
    "Value": String
  }
]

Tags屬性

屬性名稱

類型

必須

允許更新

描述

約束

Key

String

標籤鍵。

Value

String

標籤值。

傳回值

Fn::GetAtt

  • IsDefault:是否為預設補丁基準。

  • UpdatedBy:補丁基準更新者。

  • Description:補丁基準描述資訊。

  • CreatedBy:補丁基準建立者。

  • UpdatedDate:更新時間。

  • PatchBaselineName:補丁基準名稱。

  • CreateTime:建立時間。

  • OperationSystem:作業系統類型。

  • ApprovalRules:接受規則。

  • PatchBaselineId:補丁基準ID。

  • ShareType:補丁基準共用類型。

  • Tags: 補丁基準綁定的標籤。

  • RejectedPatches: 拒絕補丁的名稱列表。

  • Sources:補丁源配置列表。

  • RejectedPatchesAction:拒絕補丁的操作。

  • ResourceGroupId:資源群組ID。

  • ApprovedPatchesEnableNonSecurity:批准補丁是否包括除安全性之外的更新。

  • ApprovedPatches:批准補丁的列表。

樣本

YAML格式

ROSTemplateFormatVersion: '2015-09-01'
Parameters: {}
Resources:
  ExtensionResource:
    Type: ALIYUN::OOS::PatchBaseline
    Properties:
      PatchBaselineName: MyPatchBaseline
      OperationSystem: Windows
      ApprovalRules:
        PatchRules:
          - PatchFilterGroup:
              - Key: PatchSet
                Values:
                  - OS
              - Key: ProductFamily
                Values:
                  - Windows
              - Key: Product
                Values:
                  - Windows 10
                  - Windows 7
              - Key: Classification
                Values:
                  - Security Updates
                  - Updates
                  - Update Rollups
                  - Critical Updates
              - Key: Severity
                Values:
                  - Critical
                  - Important
                  - Moderate
            ApproveAfterDays: 7
            EnableNonSecurity: true
            ComplianceLevel: Medium
Outputs:
  IsDefault:
    Description: Indicates whether the patch baseline is set as the default patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - IsDefault
  UpdatedBy:
    Description: The user who last modified the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - UpdatedBy
  Description:
    Description: The description of the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - Description
  CreatedBy:
    Description: The creator of the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CreatedBy
  UpdatedDate:
    Description: The time when the patch baseline was last modified.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - UpdatedDate
  PatchBaselineName:
    Description: The name of the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - PatchBaselineName
  CreateTime:
    Description: The time when the patch baseline was created.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CreateTime
  OperationSystem:
    Description: The type of the operating system.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - OperationSystem
  ApprovalRules:
    Description: The rules of scanning and installing patches for the specified operating system.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - ApprovalRules
  PatchBaselineId:
    Description: The ID of the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - PatchBaselineId
  ShareType:
    Description: The share type of the patch baseline.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - ShareType

JSON格式

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
  },
  "Resources": {
    "ExtensionResource": {
      "Type": "ALIYUN::OOS::PatchBaseline",
      "Properties": {
        "PatchBaselineName": "MyPatchBaseline",
        "OperationSystem": "Windows",
        "ApprovalRules": {
          "PatchRules": [
            {
              "PatchFilterGroup": [
                {
                  "Key": "PatchSet",
                  "Values": [
                    "OS"
                  ]
                },
                {
                  "Key": "ProductFamily",
                  "Values": [
                    "Windows"
                  ]
                },
                {
                  "Key": "Product",
                  "Values": [
                    "Windows 10",
                    "Windows 7"
                  ]
                },
                {
                  "Key": "Classification",
                  "Values": [
                    "Security Updates",
                    "Updates",
                    "Update Rollups",
                    "Critical Updates"
                  ]
                },
                {
                  "Key": "Severity",
                  "Values": [
                    "Critical",
                    "Important",
                    "Moderate"
                  ]
                }
              ],
              "ApproveAfterDays": 7,
              "EnableNonSecurity": true,
              "ComplianceLevel": "Medium"
            }
          ]
        }
      }
    }
  },
  "Outputs": {
    "IsDefault": {
      "Description": "Indicates whether the patch baseline is set as the default patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "IsDefault"
        ]
      }
    },
    "UpdatedBy": {
      "Description": "The user who last modified the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "UpdatedBy"
        ]
      }
    },
    "Description": {
      "Description": "The description of the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "Description"
        ]
      }
    },
    "CreatedBy": {
      "Description": "The creator of the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CreatedBy"
        ]
      }
    },
    "UpdatedDate": {
      "Description": "The time when the patch baseline was last modified.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "UpdatedDate"
        ]
      }
    },
    "PatchBaselineName": {
      "Description": "The name of the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "PatchBaselineName"
        ]
      }
    },
    "CreateTime": {
      "Description": "The time when the patch baseline was created.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CreateTime"
        ]
      }
    },
    "OperationSystem": {
      "Description": "The type of the operating system.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "OperationSystem"
        ]
      }
    },
    "ApprovalRules": {
      "Description": "The rules of scanning and installing patches for the specified operating system.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "ApprovalRules"
        ]
      }
    },
    "PatchBaselineId": {
      "Description": "The ID of the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "PatchBaselineId"
        ]
      }
    },
    "ShareType": {
      "Description": "The share type of the patch baseline.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "ShareType"
        ]
      }
    }
  }
}