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

com.pulumi.kubernetes.extensions.v1beta1.kotlin.outputs.IngressSpec.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.extensions.v1beta1.kotlin.outputs

import kotlin.String
import kotlin.Suppress
import kotlin.collections.List

/**
 * IngressSpec describes the Ingress the user wishes to exist.
 * @property backend A default backend capable of servicing requests that don't match any rule. At least one of 'backend' or 'rules' must be specified. This field is optional to allow the loadbalancer controller or defaulting logic to specify a global default.
 * @property ingressClassName IngressClassName is the name of the IngressClass cluster resource. The associated IngressClass defines which controller will implement the resource. This replaces the deprecated `kubernetes.io/ingress.class` annotation. For backwards compatibility, when that annotation is set, it must be given precedence over this field. The controller may emit a warning if the field and annotation have different values. Implementations of this API should ignore Ingresses without a class specified. An IngressClass resource may be marked as default, which can be used to set a default value for this field. For more information, refer to the IngressClass documentation.
 * @property rules A list of host rules used to configure the Ingress. If unspecified, or no rule matches, all traffic is sent to the default backend.
 * @property tls TLS configuration. Currently the Ingress only supports a single TLS port, 443. If multiple members of this list specify different hosts, they will be multiplexed on the same port according to the hostname specified through the SNI TLS extension, if the ingress controller fulfilling the ingress supports SNI.
 */
public data class IngressSpec(
    public val backend: IngressBackend? = null,
    public val ingressClassName: String? = null,
    public val rules: List? = null,
    public val tls: List? = null,
) {
    public companion object {
        public fun toKotlin(javaType: com.pulumi.kubernetes.extensions.v1beta1.outputs.IngressSpec): IngressSpec = IngressSpec(
            backend = javaType.backend().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.extensions.v1beta1.kotlin.outputs.IngressBackend.Companion.toKotlin(args0)
                })
            }).orElse(null),
            ingressClassName = javaType.ingressClassName().map({ args0 -> args0 }).orElse(null),
            rules = javaType.rules().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.extensions.v1beta1.kotlin.outputs.IngressRule.Companion.toKotlin(args0)
                })
            }),
            tls = javaType.tls().map({ args0 ->
                args0.let({ args0 ->
                    com.pulumi.kubernetes.extensions.v1beta1.kotlin.outputs.IngressTLS.Companion.toKotlin(args0)
                })
            }),
        )
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy