All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.kubernetes.node.v1alpha1.kotlin.outputs.SchedulingPatch.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.kubernetes.node.v1alpha1.kotlin.outputs

import com.pulumi.kubernetes.core.v1.kotlin.outputs.TolerationPatch
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List
import kotlin.collections.Map

/**
 * Scheduling specifies the scheduling constraints for nodes supporting a RuntimeClass.
 * @property nodeSelector nodeSelector lists labels that must be present on nodes that support this RuntimeClass. Pods using this RuntimeClass can only be scheduled to a node matched by this selector. The RuntimeClass nodeSelector is merged with a pod's existing nodeSelector. Any conflicts will cause the pod to be rejected in admission.
 * @property tolerations tolerations are appended (excluding duplicates) to pods running with this RuntimeClass during admission, effectively unioning the set of nodes tolerated by the pod and the RuntimeClass.
 */
public data class SchedulingPatch(
    public val nodeSelector: Map? = null,
    public val tolerations: List? = null,
) {
    public companion object {
        public fun toKotlin(javaType: com.pulumi.kubernetes.node.v1alpha1.outputs.SchedulingPatch): SchedulingPatch = SchedulingPatch(
            nodeSelector = javaType.nodeSelector().map({ args0 -> args0.key.to(args0.value) }).toMap(),
            tolerations = javaType.tolerations().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.core.v1.kotlin.outputs.TolerationPatch.Companion.toKotlin(args0)
                })
            }),
        )
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy