NamespaceAuthorizationRuleArgs

data class NamespaceAuthorizationRuleArgs(val authorizationRuleName: Output<String>? = null, val namespaceName: Output<String>? = null, val resourceGroupName: Output<String>? = null, val rights: Output<List<Either<String, AccessRights>>>? = null) : ConvertibleToJava<NamespaceAuthorizationRuleArgs>

Single item in a List or Get AuthorizationRule operation Uses Azure REST API version 2021-11-01. In version 1.x of the Azure Native provider, it used API version 2017-04-01. Other available API versions: 2017-04-01, 2024-01-01.

Example Usage

RelayNameSpaceAuthorizationRuleCreate

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var namespaceAuthorizationRule = new AzureNative.Relay.NamespaceAuthorizationRule("namespaceAuthorizationRule", new()
{
AuthorizationRuleName = "example-RelayAuthRules-01",
NamespaceName = "example-RelayNamespace-01",
ResourceGroupName = "resourcegroup",
Rights = new[]
{
AzureNative.Relay.AccessRights.Listen,
AzureNative.Relay.AccessRights.Send,
},
});
});
package main
import (
relay "github.com/pulumi/pulumi-azure-native-sdk/relay/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := relay.NewNamespaceAuthorizationRule(ctx, "namespaceAuthorizationRule", &relay.NamespaceAuthorizationRuleArgs{
AuthorizationRuleName: pulumi.String("example-RelayAuthRules-01"),
NamespaceName: pulumi.String("example-RelayNamespace-01"),
ResourceGroupName: pulumi.String("resourcegroup"),
Rights: pulumi.StringArray{
pulumi.String(relay.AccessRightsListen),
pulumi.String(relay.AccessRightsSend),
},
})
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.relay.NamespaceAuthorizationRule;
import com.pulumi.azurenative.relay.NamespaceAuthorizationRuleArgs;
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 namespaceAuthorizationRule = new NamespaceAuthorizationRule("namespaceAuthorizationRule", NamespaceAuthorizationRuleArgs.builder()
.authorizationRuleName("example-RelayAuthRules-01")
.namespaceName("example-RelayNamespace-01")
.resourceGroupName("resourcegroup")
.rights(
"Listen",
"Send")
.build());
}
}

Import

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

$ pulumi import azure-native:relay:NamespaceAuthorizationRule example-RelayAuthRules-01 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Relay/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}

Constructors

Link copied to clipboard
constructor(authorizationRuleName: Output<String>? = null, namespaceName: Output<String>? = null, resourceGroupName: Output<String>? = null, rights: Output<List<Either<String, AccessRights>>>? = null)

Properties

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

The authorization rule name.

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

The namespace name

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

Name of the Resource group within the Azure subscription.

Link copied to clipboard
val rights: Output<List<Either<String, AccessRights>>>? = null

The rights associated with the rule.

Functions

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