BindingArgs

data class BindingArgs(val appName: Output<String>? = null, val bindingName: Output<String>? = null, val properties: Output<BindingResourcePropertiesArgs>? = null, val resourceGroupName: Output<String>? = null, val serviceName: Output<String>? = null) : ConvertibleToJava<BindingArgs>

Binding resource payload Uses Azure REST API version 2024-01-01-preview. In version 2.x of the Azure Native provider, it used API version 2023-05-01-preview. Other available API versions: 2023-05-01-preview, 2023-07-01-preview, 2023-09-01-preview, 2023-11-01-preview, 2023-12-01, 2024-05-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native appplatform [ApiVersion]. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.

Example Usage

Bindings_CreateOrUpdate

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var binding = new AzureNative.AppPlatform.Binding("binding", new()
{
AppName = "myapp",
BindingName = "mybinding",
Properties = new AzureNative.AppPlatform.Inputs.BindingResourcePropertiesArgs
{
BindingParameters =
{
{ "apiType", "SQL" },
{ "databaseName", "db1" },
},
Key = "xxxx",
ResourceId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.DocumentDB/databaseAccounts/my-cosmosdb-1",
},
ResourceGroupName = "myResourceGroup",
ServiceName = "myservice",
});
});
package main
import (
appplatform "github.com/pulumi/pulumi-azure-native-sdk/appplatform/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := appplatform.NewBinding(ctx, "binding", &appplatform.BindingArgs{
AppName: pulumi.String("myapp"),
BindingName: pulumi.String("mybinding"),
Properties: &appplatform.BindingResourcePropertiesArgs{
BindingParameters: pulumi.StringMap{
"apiType": pulumi.String("SQL"),
"databaseName": pulumi.String("db1"),
},
Key: pulumi.String("xxxx"),
ResourceId: pulumi.String("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.DocumentDB/databaseAccounts/my-cosmosdb-1"),
},
ResourceGroupName: pulumi.String("myResourceGroup"),
ServiceName: pulumi.String("myservice"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.appplatform.Binding;
import com.pulumi.azurenative.appplatform.BindingArgs;
import com.pulumi.azurenative.appplatform.inputs.BindingResourcePropertiesArgs;
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 binding = new Binding("binding", BindingArgs.builder()
.appName("myapp")
.bindingName("mybinding")
.properties(BindingResourcePropertiesArgs.builder()
.bindingParameters(Map.ofEntries(
Map.entry("apiType", "SQL"),
Map.entry("databaseName", "db1")
))
.key("xxxx")
.resourceId("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.DocumentDB/databaseAccounts/my-cosmosdb-1")
.build())
.resourceGroupName("myResourceGroup")
.serviceName("myservice")
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:appplatform:Binding mybinding /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/apps/{appName}/bindings/{bindingName}

Constructors

Link copied to clipboard
constructor(appName: Output<String>? = null, bindingName: Output<String>? = null, properties: Output<BindingResourcePropertiesArgs>? = null, resourceGroupName: Output<String>? = null, serviceName: Output<String>? = null)

Properties

Link copied to clipboard
val appName: Output<String>? = null

The name of the App resource.

Link copied to clipboard
val bindingName: Output<String>? = null

The name of the Binding resource.

Link copied to clipboard

Properties of the Binding resource

Link copied to clipboard
val resourceGroupName: Output<String>? = null

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

Link copied to clipboard
val serviceName: Output<String>? = null

The name of the Service resource.

Functions

Link copied to clipboard
open override fun toJava(): BindingArgs