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

com.pulumi.gcp.accesscontextmanager.kotlin.inputs.ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs.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.

There is a newer version: 8.13.1.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.accesscontextmanager.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.accesscontextmanager.inputs.ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property identities Identities can be an individual user, service account, Google group,
 * or third-party identity. For third-party identity, only single identities
 * are supported and other identity types are not supported.The v1 identities
 * that have the prefix user, group and serviceAccount in
 * https://cloud.google.com/iam/docs/principal-identifiers#v1 are supported.
 * @property identityType Specifies the type of identities that are allowed access to outside the
 * perimeter. If left unspecified, then members of `identities` field will
 * be allowed access.
 * Possible values are: `IDENTITY_TYPE_UNSPECIFIED`, `ANY_IDENTITY`, `ANY_USER_ACCOUNT`, `ANY_SERVICE_ACCOUNT`.
 * @property sourceRestriction Whether to enforce traffic restrictions based on `sources` field. If the `sources` field is non-empty, then this field must be set to `SOURCE_RESTRICTION_ENABLED`.
 * Possible values are: `SOURCE_RESTRICTION_UNSPECIFIED`, `SOURCE_RESTRICTION_ENABLED`, `SOURCE_RESTRICTION_DISABLED`.
 * @property sources Sources that this EgressPolicy authorizes access from.
 * Structure is documented below.
 */
public data class ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs(
    public val identities: Output>? = null,
    public val identityType: Output? = null,
    public val sourceRestriction: Output? = null,
    public val sources: Output>? = null,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.accesscontextmanager.inputs.ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs =
        com.pulumi.gcp.accesscontextmanager.inputs.ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs.builder()
            .identities(identities?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .identityType(identityType?.applyValue({ args0 -> args0 }))
            .sourceRestriction(sourceRestriction?.applyValue({ args0 -> args0 }))
            .sources(
                sources?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs].
 */
@PulumiTagMarker
public class ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgsBuilder internal constructor() {
    private var identities: Output>? = null

    private var identityType: Output? = null

    private var sourceRestriction: Output? = null

    private var sources:
        Output>? = null

    /**
     * @param value Identities can be an individual user, service account, Google group,
     * or third-party identity. For third-party identity, only single identities
     * are supported and other identity types are not supported.The v1 identities
     * that have the prefix user, group and serviceAccount in
     * https://cloud.google.com/iam/docs/principal-identifiers#v1 are supported.
     */
    @JvmName("dwxddmymbpdbgdxg")
    public suspend fun identities(`value`: Output>) {
        this.identities = value
    }

    @JvmName("lmhbuqqwpwpwpqvp")
    public suspend fun identities(vararg values: Output) {
        this.identities = Output.all(values.asList())
    }

    /**
     * @param values Identities can be an individual user, service account, Google group,
     * or third-party identity. For third-party identity, only single identities
     * are supported and other identity types are not supported.The v1 identities
     * that have the prefix user, group and serviceAccount in
     * https://cloud.google.com/iam/docs/principal-identifiers#v1 are supported.
     */
    @JvmName("bicpivhpwjrdngbj")
    public suspend fun identities(values: List>) {
        this.identities = Output.all(values)
    }

    /**
     * @param value Specifies the type of identities that are allowed access to outside the
     * perimeter. If left unspecified, then members of `identities` field will
     * be allowed access.
     * Possible values are: `IDENTITY_TYPE_UNSPECIFIED`, `ANY_IDENTITY`, `ANY_USER_ACCOUNT`, `ANY_SERVICE_ACCOUNT`.
     */
    @JvmName("tyfspfvojjjnbclh")
    public suspend fun identityType(`value`: Output) {
        this.identityType = value
    }

    /**
     * @param value Whether to enforce traffic restrictions based on `sources` field. If the `sources` field is non-empty, then this field must be set to `SOURCE_RESTRICTION_ENABLED`.
     * Possible values are: `SOURCE_RESTRICTION_UNSPECIFIED`, `SOURCE_RESTRICTION_ENABLED`, `SOURCE_RESTRICTION_DISABLED`.
     */
    @JvmName("nvjldtfckorkjkgn")
    public suspend fun sourceRestriction(`value`: Output) {
        this.sourceRestriction = value
    }

    /**
     * @param value Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("qraclktpvywlisjo")
    public suspend fun sources(`value`: Output>) {
        this.sources = value
    }

    @JvmName("qcyjuujelaxnhqna")
    public suspend fun sources(vararg values: Output) {
        this.sources = Output.all(values.asList())
    }

    /**
     * @param values Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("ycbndaogyqchlsfw")
    public suspend fun sources(values: List>) {
        this.sources = Output.all(values)
    }

    /**
     * @param value Identities can be an individual user, service account, Google group,
     * or third-party identity. For third-party identity, only single identities
     * are supported and other identity types are not supported.The v1 identities
     * that have the prefix user, group and serviceAccount in
     * https://cloud.google.com/iam/docs/principal-identifiers#v1 are supported.
     */
    @JvmName("higcfbkqfkvjnmai")
    public suspend fun identities(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.identities = mapped
    }

    /**
     * @param values Identities can be an individual user, service account, Google group,
     * or third-party identity. For third-party identity, only single identities
     * are supported and other identity types are not supported.The v1 identities
     * that have the prefix user, group and serviceAccount in
     * https://cloud.google.com/iam/docs/principal-identifiers#v1 are supported.
     */
    @JvmName("oaheqrnxuiixhwxm")
    public suspend fun identities(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.identities = mapped
    }

    /**
     * @param value Specifies the type of identities that are allowed access to outside the
     * perimeter. If left unspecified, then members of `identities` field will
     * be allowed access.
     * Possible values are: `IDENTITY_TYPE_UNSPECIFIED`, `ANY_IDENTITY`, `ANY_USER_ACCOUNT`, `ANY_SERVICE_ACCOUNT`.
     */
    @JvmName("lbcxdptrsejfvvus")
    public suspend fun identityType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.identityType = mapped
    }

    /**
     * @param value Whether to enforce traffic restrictions based on `sources` field. If the `sources` field is non-empty, then this field must be set to `SOURCE_RESTRICTION_ENABLED`.
     * Possible values are: `SOURCE_RESTRICTION_UNSPECIFIED`, `SOURCE_RESTRICTION_ENABLED`, `SOURCE_RESTRICTION_DISABLED`.
     */
    @JvmName("uuppvjguhlwpjprs")
    public suspend fun sourceRestriction(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sourceRestriction = mapped
    }

    /**
     * @param value Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("gexburpcildikvml")
    public suspend fun sources(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sources = mapped
    }

    /**
     * @param argument Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("uwvocqfmpqmwfggv")
    public suspend fun sources(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param argument Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("ryptqcajhjulwhsq")
    public suspend fun sources(vararg argument: suspend ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param argument Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("rhacvlidcmldoxaa")
    public suspend fun sources(argument: suspend ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgsBuilder().applySuspend
                    { argument() }.build(),
            )
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param values Sources that this EgressPolicy authorizes access from.
     * Structure is documented below.
     */
    @JvmName("hflrpxkdvaqtnlip")
    public suspend fun sources(vararg values: ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromSourceArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.sources = mapped
    }

    internal fun build(): ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs =
        ServicePerimetersServicePerimeterSpecEgressPolicyEgressFromArgs(
            identities = identities,
            identityType = identityType,
            sourceRestriction = sourceRestriction,
            sources = sources,
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy