你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

AutomaticRepairsPolicy Class

Specifies the configuration parameters for automatic repairs on the virtual machine scale set.

Inheritance
azure.mgmt.compute._serialization.Model
AutomaticRepairsPolicy

Constructor

AutomaticRepairsPolicy(*, enabled: bool | None = None, grace_period: str | None = None, repair_action: str | _models.RepairAction | None = None, **kwargs: Any)

Keyword-Only Parameters

Name Description
enabled

Specifies whether automatic repairs should be enabled on the virtual machine scale set. The default value is false.

grace_period
str

The amount of time for which automatic repairs are suspended due to a state change on VM. The grace time starts after the state change has completed. This helps avoid premature or accidental repairs. The time duration should be specified in ISO 8601 format. The minimum allowed grace period is 10 minutes (PT10M), which is also the default value. The maximum allowed grace period is 90 minutes (PT90M).

repair_action

Type of repair action (replace, restart, reimage) that will be used for repairing unhealthy virtual machines in the scale set. Default value is replace. Known values are: "Replace", "Restart", and "Reimage".

Variables

Name Description
enabled

Specifies whether automatic repairs should be enabled on the virtual machine scale set. The default value is false.

grace_period
str

The amount of time for which automatic repairs are suspended due to a state change on VM. The grace time starts after the state change has completed. This helps avoid premature or accidental repairs. The time duration should be specified in ISO 8601 format. The minimum allowed grace period is 10 minutes (PT10M), which is also the default value. The maximum allowed grace period is 90 minutes (PT90M).

repair_action

Type of repair action (replace, restart, reimage) that will be used for repairing unhealthy virtual machines in the scale set. Default value is replace. Known values are: "Replace", "Restart", and "Reimage".