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.azure.appplatform.kotlin.SpringCloudStorageArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.appplatform.kotlin
import com.pulumi.azure.appplatform.SpringCloudStorageArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName
/**
* Manages a Spring Cloud Storage.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azure from "@pulumi/azure";
* const example = new azure.core.ResourceGroup("example", {
* name: "example-resources",
* location: "West Europe",
* });
* const exampleAccount = new azure.storage.Account("example", {
* name: "example",
* resourceGroupName: example.name,
* location: example.location,
* accountTier: "Standard",
* accountReplicationType: "GRS",
* });
* const exampleSpringCloudService = new azure.appplatform.SpringCloudService("example", {
* name: "example",
* location: example.location,
* resourceGroupName: example.name,
* });
* const exampleSpringCloudStorage = new azure.appplatform.SpringCloudStorage("example", {
* name: "example",
* springCloudServiceId: exampleSpringCloudService.id,
* storageAccountName: exampleAccount.name,
* storageAccountKey: exampleAccount.primaryAccessKey,
* });
* ```
* ```python
* import pulumi
* import pulumi_azure as azure
* example = azure.core.ResourceGroup("example",
* name="example-resources",
* location="West Europe")
* example_account = azure.storage.Account("example",
* name="example",
* resource_group_name=example.name,
* location=example.location,
* account_tier="Standard",
* account_replication_type="GRS")
* example_spring_cloud_service = azure.appplatform.SpringCloudService("example",
* name="example",
* location=example.location,
* resource_group_name=example.name)
* example_spring_cloud_storage = azure.appplatform.SpringCloudStorage("example",
* name="example",
* spring_cloud_service_id=example_spring_cloud_service.id,
* storage_account_name=example_account.name,
* storage_account_key=example_account.primary_access_key)
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Azure = Pulumi.Azure;
* return await Deployment.RunAsync(() =>
* {
* var example = new Azure.Core.ResourceGroup("example", new()
* {
* Name = "example-resources",
* Location = "West Europe",
* });
* var exampleAccount = new Azure.Storage.Account("example", new()
* {
* Name = "example",
* ResourceGroupName = example.Name,
* Location = example.Location,
* AccountTier = "Standard",
* AccountReplicationType = "GRS",
* });
* var exampleSpringCloudService = new Azure.AppPlatform.SpringCloudService("example", new()
* {
* Name = "example",
* Location = example.Location,
* ResourceGroupName = example.Name,
* });
* var exampleSpringCloudStorage = new Azure.AppPlatform.SpringCloudStorage("example", new()
* {
* Name = "example",
* SpringCloudServiceId = exampleSpringCloudService.Id,
* StorageAccountName = exampleAccount.Name,
* StorageAccountKey = exampleAccount.PrimaryAccessKey,
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/appplatform"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/storage"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
* Name: pulumi.String("example-resources"),
* Location: pulumi.String("West Europe"),
* })
* if err != nil {
* return err
* }
* exampleAccount, err := storage.NewAccount(ctx, "example", &storage.AccountArgs{
* Name: pulumi.String("example"),
* ResourceGroupName: example.Name,
* Location: example.Location,
* AccountTier: pulumi.String("Standard"),
* AccountReplicationType: pulumi.String("GRS"),
* })
* if err != nil {
* return err
* }
* exampleSpringCloudService, err := appplatform.NewSpringCloudService(ctx, "example", &appplatform.SpringCloudServiceArgs{
* Name: pulumi.String("example"),
* Location: example.Location,
* ResourceGroupName: example.Name,
* })
* if err != nil {
* return err
* }
* _, err = appplatform.NewSpringCloudStorage(ctx, "example", &appplatform.SpringCloudStorageArgs{
* Name: pulumi.String("example"),
* SpringCloudServiceId: exampleSpringCloudService.ID(),
* StorageAccountName: exampleAccount.Name,
* StorageAccountKey: exampleAccount.PrimaryAccessKey,
* })
* 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.azure.core.ResourceGroup;
* import com.pulumi.azure.core.ResourceGroupArgs;
* import com.pulumi.azure.storage.Account;
* import com.pulumi.azure.storage.AccountArgs;
* import com.pulumi.azure.appplatform.SpringCloudService;
* import com.pulumi.azure.appplatform.SpringCloudServiceArgs;
* import com.pulumi.azure.appplatform.SpringCloudStorage;
* import com.pulumi.azure.appplatform.SpringCloudStorageArgs;
* 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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
* .name("example-resources")
* .location("West Europe")
* .build());
* var exampleAccount = new Account("exampleAccount", AccountArgs.builder()
* .name("example")
* .resourceGroupName(example.name())
* .location(example.location())
* .accountTier("Standard")
* .accountReplicationType("GRS")
* .build());
* var exampleSpringCloudService = new SpringCloudService("exampleSpringCloudService", SpringCloudServiceArgs.builder()
* .name("example")
* .location(example.location())
* .resourceGroupName(example.name())
* .build());
* var exampleSpringCloudStorage = new SpringCloudStorage("exampleSpringCloudStorage", SpringCloudStorageArgs.builder()
* .name("example")
* .springCloudServiceId(exampleSpringCloudService.id())
* .storageAccountName(exampleAccount.name())
* .storageAccountKey(exampleAccount.primaryAccessKey())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: azure:core:ResourceGroup
* properties:
* name: example-resources
* location: West Europe
* exampleAccount:
* type: azure:storage:Account
* name: example
* properties:
* name: example
* resourceGroupName: ${example.name}
* location: ${example.location}
* accountTier: Standard
* accountReplicationType: GRS
* exampleSpringCloudService:
* type: azure:appplatform:SpringCloudService
* name: example
* properties:
* name: example
* location: ${example.location}
* resourceGroupName: ${example.name}
* exampleSpringCloudStorage:
* type: azure:appplatform:SpringCloudStorage
* name: example
* properties:
* name: example
* springCloudServiceId: ${exampleSpringCloudService.id}
* storageAccountName: ${exampleAccount.name}
* storageAccountKey: ${exampleAccount.primaryAccessKey}
* ```
*
* ## Import
* Spring Cloud Storages can be imported using the `resource id`, e.g.
* ```sh
* $ pulumi import azure:appplatform/springCloudStorage:SpringCloudStorage example /subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/resourceGroup1/providers/Microsoft.AppPlatform/spring/service1/storages/storage1
* ```
* @property name The name which should be used for this Spring Cloud Storage. Changing this forces a new Spring Cloud Storage to be created.
* @property springCloudServiceId The ID of the Spring Cloud Service where the Spring Cloud Storage should exist. Changing this forces a new Spring Cloud Storage to be created.
* @property storageAccountKey The access key of the Azure Storage Account.
* @property storageAccountName The account name of the Azure Storage Account.
*/
public data class SpringCloudStorageArgs(
public val name: Output? = null,
public val springCloudServiceId: Output? = null,
public val storageAccountKey: Output? = null,
public val storageAccountName: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azure.appplatform.SpringCloudStorageArgs =
com.pulumi.azure.appplatform.SpringCloudStorageArgs.builder()
.name(name?.applyValue({ args0 -> args0 }))
.springCloudServiceId(springCloudServiceId?.applyValue({ args0 -> args0 }))
.storageAccountKey(storageAccountKey?.applyValue({ args0 -> args0 }))
.storageAccountName(storageAccountName?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [SpringCloudStorageArgs].
*/
@PulumiTagMarker
public class SpringCloudStorageArgsBuilder internal constructor() {
private var name: Output? = null
private var springCloudServiceId: Output? = null
private var storageAccountKey: Output? = null
private var storageAccountName: Output? = null
/**
* @param value The name which should be used for this Spring Cloud Storage. Changing this forces a new Spring Cloud Storage to be created.
*/
@JvmName("ixnakngynamejxer")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value The ID of the Spring Cloud Service where the Spring Cloud Storage should exist. Changing this forces a new Spring Cloud Storage to be created.
*/
@JvmName("nbcxhouwrqrldtve")
public suspend fun springCloudServiceId(`value`: Output) {
this.springCloudServiceId = value
}
/**
* @param value The access key of the Azure Storage Account.
*/
@JvmName("eewiejbyoseyvfbl")
public suspend fun storageAccountKey(`value`: Output) {
this.storageAccountKey = value
}
/**
* @param value The account name of the Azure Storage Account.
*/
@JvmName("ghgfwonwlbnetmdg")
public suspend fun storageAccountName(`value`: Output) {
this.storageAccountName = value
}
/**
* @param value The name which should be used for this Spring Cloud Storage. Changing this forces a new Spring Cloud Storage to be created.
*/
@JvmName("arwsipwfxuwhdgiw")
public suspend fun name(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.name = mapped
}
/**
* @param value The ID of the Spring Cloud Service where the Spring Cloud Storage should exist. Changing this forces a new Spring Cloud Storage to be created.
*/
@JvmName("yrxwuslpfbfxelad")
public suspend fun springCloudServiceId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.springCloudServiceId = mapped
}
/**
* @param value The access key of the Azure Storage Account.
*/
@JvmName("bnfmxjmrqnijxcng")
public suspend fun storageAccountKey(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.storageAccountKey = mapped
}
/**
* @param value The account name of the Azure Storage Account.
*/
@JvmName("qyauqxkjajhdgiyn")
public suspend fun storageAccountName(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.storageAccountName = mapped
}
internal fun build(): SpringCloudStorageArgs = SpringCloudStorageArgs(
name = name,
springCloudServiceId = springCloudServiceId,
storageAccountKey = storageAccountKey,
storageAccountName = storageAccountName,
)
}