
com.pulumi.azure.compute.kotlin.inputs.OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.compute.kotlin.inputs
import com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
*
* @property action The repair action that will be used for repairing unhealthy virtual machines in the scale set. Possible values include `Replace`, `Restart`, `Reimage`.
* > **Note:** Once the `action` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
* > **Note:** If you wish to update the repair `action` of an existing `automatic_instance_repair` policy, you must first `disable` the `automatic_instance_repair` policy before you can re-enable the `automatic_instance_repair` policy with the new repair `action` defined.
* @property enabled Should the automatic instance repair be enabled on this Virtual Machine Scale Set? Possible values are `true` and `false`.
* @property gracePeriod Amount of time for which automatic repairs will be delayed. The grace period starts right after the VM is found unhealthy. Possible values are between `10` and `90` minutes. The time duration should be specified in `ISO 8601` format (e.g. `PT10M` to `PT90M`).
* > **Note:** Once the `grace_period` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
*/
public data class OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs(
public val action: Output? = null,
public val enabled: Output,
public val gracePeriod: Output? = null,
) :
ConvertibleToJava {
override fun toJava(): com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs =
com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs.builder()
.action(action?.applyValue({ args0 -> args0 }))
.enabled(enabled.applyValue({ args0 -> args0 }))
.gracePeriod(gracePeriod?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs].
*/
@PulumiTagMarker
public class OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgsBuilder internal constructor() {
private var action: Output? = null
private var enabled: Output? = null
private var gracePeriod: Output? = null
/**
* @param value The repair action that will be used for repairing unhealthy virtual machines in the scale set. Possible values include `Replace`, `Restart`, `Reimage`.
* > **Note:** Once the `action` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
* > **Note:** If you wish to update the repair `action` of an existing `automatic_instance_repair` policy, you must first `disable` the `automatic_instance_repair` policy before you can re-enable the `automatic_instance_repair` policy with the new repair `action` defined.
*/
@JvmName("hgrubgwjxlyifxbd")
public suspend fun action(`value`: Output) {
this.action = value
}
/**
* @param value Should the automatic instance repair be enabled on this Virtual Machine Scale Set? Possible values are `true` and `false`.
*/
@JvmName("floywfpacaoprygi")
public suspend fun enabled(`value`: Output) {
this.enabled = value
}
/**
* @param value Amount of time for which automatic repairs will be delayed. The grace period starts right after the VM is found unhealthy. Possible values are between `10` and `90` minutes. The time duration should be specified in `ISO 8601` format (e.g. `PT10M` to `PT90M`).
* > **Note:** Once the `grace_period` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
*/
@JvmName("xjxauvgygyrhdodm")
public suspend fun gracePeriod(`value`: Output) {
this.gracePeriod = value
}
/**
* @param value The repair action that will be used for repairing unhealthy virtual machines in the scale set. Possible values include `Replace`, `Restart`, `Reimage`.
* > **Note:** Once the `action` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
* > **Note:** If you wish to update the repair `action` of an existing `automatic_instance_repair` policy, you must first `disable` the `automatic_instance_repair` policy before you can re-enable the `automatic_instance_repair` policy with the new repair `action` defined.
*/
@JvmName("xmxgpnaptexedjhc")
public suspend fun action(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.action = mapped
}
/**
* @param value Should the automatic instance repair be enabled on this Virtual Machine Scale Set? Possible values are `true` and `false`.
*/
@JvmName("sornfxwrkfcooyqq")
public suspend fun enabled(`value`: Boolean) {
val toBeMapped = value
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.enabled = mapped
}
/**
* @param value Amount of time for which automatic repairs will be delayed. The grace period starts right after the VM is found unhealthy. Possible values are between `10` and `90` minutes. The time duration should be specified in `ISO 8601` format (e.g. `PT10M` to `PT90M`).
* > **Note:** Once the `grace_period` field has been set it will always return the last value it was assigned if it is removed from the configuration file.
*/
@JvmName("xwlccycyurbiinei")
public suspend fun gracePeriod(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.gracePeriod = mapped
}
internal fun build(): OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs =
OrchestratedVirtualMachineScaleSetAutomaticInstanceRepairArgs(
action = action,
enabled = enabled ?: throw PulumiNullFieldException("enabled"),
gracePeriod = gracePeriod,
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy