All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.azurenative.servicefabricmesh.kotlin.SecretArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azurenative.servicefabricmesh.kotlin
import com.pulumi.azurenative.servicefabricmesh.SecretArgs.builder
import com.pulumi.azurenative.servicefabricmesh.kotlin.inputs.SecretResourcePropertiesArgs
import com.pulumi.azurenative.servicefabricmesh.kotlin.inputs.SecretResourcePropertiesArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* This type describes a secret resource.
* Azure REST API version: 2018-09-01-preview. Prior API version in Azure Native 1.x: 2018-09-01-preview.
* ## Example Usage
* ### CreateOrUpdateSecret
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using AzureNative = Pulumi.AzureNative;
* return await Deployment.RunAsync(() =>
* {
* var secret = new AzureNative.ServiceFabricMesh.Secret("secret", new()
* {
* Location = "EastUS",
* Properties = null,
* ResourceGroupName = "sbz_demo",
* SecretResourceName = "dbConnectionString",
* Tags = null,
* });
* });
* ```
* ```go
* package main
* import (
* servicefabricmesh "github.com/pulumi/pulumi-azure-native-sdk/servicefabricmesh/v2"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := servicefabricmesh.NewSecret(ctx, "secret", &servicefabricmesh.SecretArgs{
* Location: pulumi.String("EastUS"),
* Properties: nil,
* ResourceGroupName: pulumi.String("sbz_demo"),
* SecretResourceName: pulumi.String("dbConnectionString"),
* Tags: nil,
* })
* 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.azurenative.servicefabricmesh.Secret;
* import com.pulumi.azurenative.servicefabricmesh.SecretArgs;
* import com.pulumi.azurenative.servicefabricmesh.inputs.SecretResourcePropertiesArgs;
* 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 secret = new Secret("secret", SecretArgs.builder()
* .location("EastUS")
* .properties()
* .resourceGroupName("sbz_demo")
* .secretResourceName("dbConnectionString")
* .tags()
* .build());
* }
* }
* ```
* ## Import
* An existing resource can be imported using its type token, name, and identifier, e.g.
* ```sh
* $ pulumi import azure-native:servicefabricmesh:Secret dbConnectionString /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceFabricMesh/secrets/{secretResourceName}
* ```
* @property location The geo-location where the resource lives
* @property properties Describes the properties of a secret resource.
* @property resourceGroupName Azure resource group name
* @property secretResourceName The name of the secret resource.
* @property tags Resource tags.
*/
public data class SecretArgs(
public val location: Output? = null,
public val properties: Output? = null,
public val resourceGroupName: Output? = null,
public val secretResourceName: Output? = null,
public val tags: Output>? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azurenative.servicefabricmesh.SecretArgs =
com.pulumi.azurenative.servicefabricmesh.SecretArgs.builder()
.location(location?.applyValue({ args0 -> args0 }))
.properties(properties?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
.secretResourceName(secretResourceName?.applyValue({ args0 -> args0 }))
.tags(
tags?.applyValue({ args0 ->
args0.map({ args0 ->
args0.key.to(args0.value)
}).toMap()
}),
).build()
}
/**
* Builder for [SecretArgs].
*/
@PulumiTagMarker
public class SecretArgsBuilder internal constructor() {
private var location: Output? = null
private var properties: Output? = null
private var resourceGroupName: Output? = null
private var secretResourceName: Output? = null
private var tags: Output>? = null
/**
* @param value The geo-location where the resource lives
*/
@JvmName("kusmoymwssorbqqn")
public suspend fun location(`value`: Output) {
this.location = value
}
/**
* @param value Describes the properties of a secret resource.
*/
@JvmName("paluecbvdgpsnedf")
public suspend fun properties(`value`: Output) {
this.properties = value
}
/**
* @param value Azure resource group name
*/
@JvmName("uucpjwwbtedkwpcu")
public suspend fun resourceGroupName(`value`: Output) {
this.resourceGroupName = value
}
/**
* @param value The name of the secret resource.
*/
@JvmName("mxqqbbjrucoddpgw")
public suspend fun secretResourceName(`value`: Output) {
this.secretResourceName = value
}
/**
* @param value Resource tags.
*/
@JvmName("wpywntsprjeerjew")
public suspend fun tags(`value`: Output>) {
this.tags = value
}
/**
* @param value The geo-location where the resource lives
*/
@JvmName("oymixjkmvcmxlpun")
public suspend fun location(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.location = mapped
}
/**
* @param value Describes the properties of a secret resource.
*/
@JvmName("txjtdopnspwwvcjw")
public suspend fun properties(`value`: SecretResourcePropertiesArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.properties = mapped
}
/**
* @param argument Describes the properties of a secret resource.
*/
@JvmName("sbbikaxqdpewnwbu")
public suspend fun properties(argument: suspend SecretResourcePropertiesArgsBuilder.() -> Unit) {
val toBeMapped = SecretResourcePropertiesArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.properties = mapped
}
/**
* @param value Azure resource group name
*/
@JvmName("ufqsqbmxsxlwvbrl")
public suspend fun resourceGroupName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.resourceGroupName = mapped
}
/**
* @param value The name of the secret resource.
*/
@JvmName("mmimemugjomflhsi")
public suspend fun secretResourceName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.secretResourceName = mapped
}
/**
* @param value Resource tags.
*/
@JvmName("rgjshjnyuythlwtc")
public suspend fun tags(`value`: Map?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tags = mapped
}
/**
* @param values Resource tags.
*/
@JvmName("wlxxvhqgtlqmuram")
public fun tags(vararg values: Pair) {
val toBeMapped = values.toMap()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.tags = mapped
}
internal fun build(): SecretArgs = SecretArgs(
location = location,
properties = properties,
resourceGroupName = resourceGroupName,
secretResourceName = secretResourceName,
tags = tags,
)
}