com.pulumi.gcp.artifactregistry.kotlin.VpcscConfigArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-gcp-kotlin Show documentation
Show all versions of pulumi-gcp-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gcp.artifactregistry.kotlin
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.artifactregistry.VpcscConfigArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
* ## Example Usage
* ### Artifact Registry Vpcsc Config
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
* const my_config = new gcp.artifactregistry.VpcscConfig("my-config", {
* location: "us-central1",
* vpcscPolicy: "ALLOW",
* });
* ```
* ```python
* import pulumi
* import pulumi_gcp as gcp
* my_config = gcp.artifactregistry.VpcscConfig("my-config",
* location="us-central1",
* vpcsc_policy="ALLOW")
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Gcp = Pulumi.Gcp;
* return await Deployment.RunAsync(() =>
* {
* var my_config = new Gcp.ArtifactRegistry.VpcscConfig("my-config", new()
* {
* Location = "us-central1",
* VpcscPolicy = "ALLOW",
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/artifactregistry"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := artifactregistry.NewVpcscConfig(ctx, "my-config", &artifactregistry.VpcscConfigArgs{
* Location: pulumi.String("us-central1"),
* VpcscPolicy: pulumi.String("ALLOW"),
* })
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gcp.artifactregistry.VpcscConfig;
* import com.pulumi.gcp.artifactregistry.VpcscConfigArgs;
* import java.util.List;
* import java.util.ArrayList;
* import java.util.Map;
* import java.io.File;
* import java.nio.file.Files;
* import java.nio.file.Paths;
* public class App {
* public static void main(String[] args) {
* Pulumi.run(App::stack);
* }
* public static void stack(Context ctx) {
* var my_config = new VpcscConfig("my-config", VpcscConfigArgs.builder()
* .location("us-central1")
* .vpcscPolicy("ALLOW")
* .build());
* }
* }
* ```
* ```yaml
* resources:
* my-config:
* type: gcp:artifactregistry:VpcscConfig
* properties:
* location: us-central1
* vpcscPolicy: ALLOW
* ```
*
* ## Import
* VPCSCConfig can be imported using any of these accepted formats:
* * `projects/{{project}}/locations/{{location}}/vpcscConfig/{{name}}`
* * `{{project}}/{{location}}/{{name}}`
* * `{{location}}/{{name}}`
* When using the `pulumi import` command, VPCSCConfig can be imported using one of the formats above. For example:
* ```sh
* $ pulumi import gcp:artifactregistry/vpcscConfig:VpcscConfig default projects/{{project}}/locations/{{location}}/vpcscConfig/{{name}}
* ```
* ```sh
* $ pulumi import gcp:artifactregistry/vpcscConfig:VpcscConfig default {{project}}/{{location}}/{{name}}
* ```
* ```sh
* $ pulumi import gcp:artifactregistry/vpcscConfig:VpcscConfig default {{location}}/{{name}}
* ```
* @property location The name of the location this config is located in.
* @property project The ID of the project in which the resource belongs.
* If it is not provided, the provider project is used.
* @property vpcscPolicy The VPC SC policy for project and location.
* Possible values are: `DENY`, `ALLOW`.
*/
public data class VpcscConfigArgs(
public val location: Output? = null,
public val project: Output? = null,
public val vpcscPolicy: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.gcp.artifactregistry.VpcscConfigArgs =
com.pulumi.gcp.artifactregistry.VpcscConfigArgs.builder()
.location(location?.applyValue({ args0 -> args0 }))
.project(project?.applyValue({ args0 -> args0 }))
.vpcscPolicy(vpcscPolicy?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [VpcscConfigArgs].
*/
@PulumiTagMarker
public class VpcscConfigArgsBuilder internal constructor() {
private var location: Output? = null
private var project: Output? = null
private var vpcscPolicy: Output? = null
/**
* @param value The name of the location this config is located in.
*/
@JvmName("wulnjeseayfuwlik")
public suspend fun location(`value`: Output) {
this.location = value
}
/**
* @param value The ID of the project in which the resource belongs.
* If it is not provided, the provider project is used.
*/
@JvmName("qewrdtxkpqpxvbaa")
public suspend fun project(`value`: Output) {
this.project = value
}
/**
* @param value The VPC SC policy for project and location.
* Possible values are: `DENY`, `ALLOW`.
*/
@JvmName("jksdwkxdxnhpdjqv")
public suspend fun vpcscPolicy(`value`: Output) {
this.vpcscPolicy = value
}
/**
* @param value The name of the location this config is located in.
*/
@JvmName("ojvtltbkhoyfimcw")
public suspend fun location(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.location = mapped
}
/**
* @param value The ID of the project in which the resource belongs.
* If it is not provided, the provider project is used.
*/
@JvmName("pucxpmagjgxnscil")
public suspend fun project(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.project = mapped
}
/**
* @param value The VPC SC policy for project and location.
* Possible values are: `DENY`, `ALLOW`.
*/
@JvmName("tfemsqenuksmvmxt")
public suspend fun vpcscPolicy(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.vpcscPolicy = mapped
}
internal fun build(): VpcscConfigArgs = VpcscConfigArgs(
location = location,
project = project,
vpcscPolicy = vpcscPolicy,
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy