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

com.pulumi.vault.kotlin.PluginPinnedVersionArgs.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: 6.6.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.vault.kotlin

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.vault.PluginPinnedVersionArgs.builder
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 * ## Example Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as vault from "@pulumi/vault";
 * const jwt = new vault.Plugin("jwt", {
 *     type: "auth",
 *     name: "jwt",
 *     command: "vault-plugin-auth-jwt",
 *     version: "v0.17.0",
 *     sha256: "6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc",
 *     envs: ["HTTP_PROXY=http://proxy.example.com:8080"],
 * });
 * const jwtPin = new vault.PluginPinnedVersion("jwt_pin", {
 *     type: jwt.type,
 *     name: jwt.name,
 *     version: jwt.version,
 * });
 * const jwtAuth = new vault.AuthBackend("jwt_auth", {type: jwtPin.name});
 * ```
 * ```python
 * import pulumi
 * import pulumi_vault as vault
 * jwt = vault.Plugin("jwt",
 *     type="auth",
 *     name="jwt",
 *     command="vault-plugin-auth-jwt",
 *     version="v0.17.0",
 *     sha256="6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc",
 *     envs=["HTTP_PROXY=http://proxy.example.com:8080"])
 * jwt_pin = vault.PluginPinnedVersion("jwt_pin",
 *     type=jwt.type,
 *     name=jwt.name,
 *     version=jwt.version)
 * jwt_auth = vault.AuthBackend("jwt_auth", type=jwt_pin.name)
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Vault = Pulumi.Vault;
 * return await Deployment.RunAsync(() =>
 * {
 *     var jwt = new Vault.Plugin("jwt", new()
 *     {
 *         Type = "auth",
 *         Name = "jwt",
 *         Command = "vault-plugin-auth-jwt",
 *         Version = "v0.17.0",
 *         Sha256 = "6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc",
 *         Envs = new[]
 *         {
 *             "HTTP_PROXY=http://proxy.example.com:8080",
 *         },
 *     });
 *     var jwtPin = new Vault.PluginPinnedVersion("jwt_pin", new()
 *     {
 *         Type = jwt.Type,
 *         Name = jwt.Name,
 *         Version = jwt.Version,
 *     });
 *     var jwtAuth = new Vault.AuthBackend("jwt_auth", new()
 *     {
 *         Type = jwtPin.Name,
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-vault/sdk/v6/go/vault"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		jwt, err := vault.NewPlugin(ctx, "jwt", &vault.PluginArgs{
 * 			Type:    pulumi.String("auth"),
 * 			Name:    pulumi.String("jwt"),
 * 			Command: pulumi.String("vault-plugin-auth-jwt"),
 * 			Version: pulumi.String("v0.17.0"),
 * 			Sha256:  pulumi.String("6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc"),
 * 			Envs: pulumi.StringArray{
 * 				pulumi.String("HTTP_PROXY=http://proxy.example.com:8080"),
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		jwtPin, err := vault.NewPluginPinnedVersion(ctx, "jwt_pin", &vault.PluginPinnedVersionArgs{
 * 			Type:    jwt.Type,
 * 			Name:    jwt.Name,
 * 			Version: jwt.Version,
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = vault.NewAuthBackend(ctx, "jwt_auth", &vault.AuthBackendArgs{
 * 			Type: jwtPin.Name,
 * 		})
 * 		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.vault.Plugin;
 * import com.pulumi.vault.PluginArgs;
 * import com.pulumi.vault.PluginPinnedVersion;
 * import com.pulumi.vault.PluginPinnedVersionArgs;
 * import com.pulumi.vault.AuthBackend;
 * import com.pulumi.vault.AuthBackendArgs;
 * 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 jwt = new Plugin("jwt", PluginArgs.builder()
 *             .type("auth")
 *             .name("jwt")
 *             .command("vault-plugin-auth-jwt")
 *             .version("v0.17.0")
 *             .sha256("6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc")
 *             .envs("HTTP_PROXY=http://proxy.example.com:8080")
 *             .build());
 *         var jwtPin = new PluginPinnedVersion("jwtPin", PluginPinnedVersionArgs.builder()
 *             .type(jwt.type())
 *             .name(jwt.name())
 *             .version(jwt.version())
 *             .build());
 *         var jwtAuth = new AuthBackend("jwtAuth", AuthBackendArgs.builder()
 *             .type(jwtPin.name())
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   jwt:
 *     type: vault:Plugin
 *     properties:
 *       type: auth
 *       name: jwt
 *       command: vault-plugin-auth-jwt
 *       version: v0.17.0
 *       sha256: 6bd0a803ed742aa3ce35e4fa23d2c8d550e6c1567bf63410cec489c28b68b0fc
 *       envs:
 *         - HTTP_PROXY=http://proxy.example.com:8080
 *   jwtPin:
 *     type: vault:PluginPinnedVersion
 *     name: jwt_pin
 *     properties:
 *       type: ${jwt.type}
 *       name: ${jwt.name}
 *       version: ${jwt.version}
 *   jwtAuth:
 *     type: vault:AuthBackend
 *     name: jwt_auth
 *     properties:
 *       type: ${jwtPin.name}
 * ```
 * 
 * ## Import
 * Pinned plugin versions can be imported using `type/name` as the ID, e.g.
 * ```sh
 * $ pulumi import vault:index/pluginPinnedVersion:PluginPinnedVersion jwt_pin auth/jwt
 * ```
 * @property name Name of the plugin.
 * @property type Type of plugin; one of "auth", "secret", or "database".
 * @property version Semantic version of the plugin to pin.
 */
public data class PluginPinnedVersionArgs(
    public val name: Output? = null,
    public val type: Output? = null,
    public val version: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.vault.PluginPinnedVersionArgs =
        com.pulumi.vault.PluginPinnedVersionArgs.builder()
            .name(name?.applyValue({ args0 -> args0 }))
            .type(type?.applyValue({ args0 -> args0 }))
            .version(version?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [PluginPinnedVersionArgs].
 */
@PulumiTagMarker
public class PluginPinnedVersionArgsBuilder internal constructor() {
    private var name: Output? = null

    private var type: Output? = null

    private var version: Output? = null

    /**
     * @param value Name of the plugin.
     */
    @JvmName("tjkkiftjaesnabik")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value Type of plugin; one of "auth", "secret", or "database".
     */
    @JvmName("sbgwdwlmlvkcalay")
    public suspend fun type(`value`: Output) {
        this.type = value
    }

    /**
     * @param value Semantic version of the plugin to pin.
     */
    @JvmName("vvwvpokcfsdabxpg")
    public suspend fun version(`value`: Output) {
        this.version = value
    }

    /**
     * @param value Name of the plugin.
     */
    @JvmName("yrwvaivtpryagibe")
    public suspend fun name(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value Type of plugin; one of "auth", "secret", or "database".
     */
    @JvmName("blwdusahdmvmmbla")
    public suspend fun type(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.type = mapped
    }

    /**
     * @param value Semantic version of the plugin to pin.
     */
    @JvmName("rwdxalyarpcixlhw")
    public suspend fun version(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.version = mapped
    }

    internal fun build(): PluginPinnedVersionArgs = PluginPinnedVersionArgs(
        name = name,
        type = type,
        version = version,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy