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

com.pulumi.azurenative.eventhub.NamespaceNetworkRuleSet Maven / Gradle / Ivy

There is a newer version: 2.82.0
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.azurenative.eventhub;

import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.eventhub.NamespaceNetworkRuleSetArgs;
import com.pulumi.azurenative.eventhub.outputs.NWRuleSetIpRulesResponse;
import com.pulumi.azurenative.eventhub.outputs.NWRuleSetVirtualNetworkRulesResponse;
import com.pulumi.azurenative.eventhub.outputs.SystemDataResponse;
import com.pulumi.core.Alias;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * Description of topic resource.
 * Azure REST API version: 2022-10-01-preview. Prior API version in Azure Native 1.x: 2017-04-01.
 * 
 * Other available API versions: 2023-01-01-preview, 2024-01-01, 2024-05-01-preview.
 * 
 * ## Example Usage
 * ### NameSpaceNetworkRuleSetCreate
 * 
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.eventhub.NamespaceNetworkRuleSet;
 * import com.pulumi.azurenative.eventhub.NamespaceNetworkRuleSetArgs;
 * import com.pulumi.azurenative.eventhub.inputs.NWRuleSetIpRulesArgs;
 * import com.pulumi.azurenative.eventhub.inputs.NWRuleSetVirtualNetworkRulesArgs;
 * import com.pulumi.azurenative.eventhub.inputs.SubnetArgs;
 * 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 namespaceNetworkRuleSet = new NamespaceNetworkRuleSet("namespaceNetworkRuleSet", NamespaceNetworkRuleSetArgs.builder()
 *             .defaultAction("Deny")
 *             .ipRules(            
 *                 NWRuleSetIpRulesArgs.builder()
 *                     .action("Allow")
 *                     .ipMask("1.1.1.1")
 *                     .build(),
 *                 NWRuleSetIpRulesArgs.builder()
 *                     .action("Allow")
 *                     .ipMask("1.1.1.2")
 *                     .build(),
 *                 NWRuleSetIpRulesArgs.builder()
 *                     .action("Allow")
 *                     .ipMask("1.1.1.3")
 *                     .build(),
 *                 NWRuleSetIpRulesArgs.builder()
 *                     .action("Allow")
 *                     .ipMask("1.1.1.4")
 *                     .build(),
 *                 NWRuleSetIpRulesArgs.builder()
 *                     .action("Allow")
 *                     .ipMask("1.1.1.5")
 *                     .build())
 *             .namespaceName("sdk-Namespace-6019")
 *             .resourceGroupName("ResourceGroup")
 *             .virtualNetworkRules(            
 *                 NWRuleSetVirtualNetworkRulesArgs.builder()
 *                     .ignoreMissingVnetServiceEndpoint(true)
 *                     .subnet(SubnetArgs.builder()
 *                         .id("/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet2")
 *                         .build())
 *                     .build(),
 *                 NWRuleSetVirtualNetworkRulesArgs.builder()
 *                     .ignoreMissingVnetServiceEndpoint(false)
 *                     .subnet(SubnetArgs.builder()
 *                         .id("/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet3")
 *                         .build())
 *                     .build(),
 *                 NWRuleSetVirtualNetworkRulesArgs.builder()
 *                     .ignoreMissingVnetServiceEndpoint(false)
 *                     .subnet(SubnetArgs.builder()
 *                         .id("/subscriptions/subscriptionid/resourcegroups/resourcegroupid/providers/Microsoft.Network/virtualNetworks/myvn/subnets/subnet6")
 *                         .build())
 *                     .build())
 *             .build());
 * 
 *     }
 * }
 * 
 * }
 * 
* * ## Import * * An existing resource can be imported using its type token, name, and identifier, e.g. * * ```sh * $ pulumi import azure-native:eventhub:NamespaceNetworkRuleSet default /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/networkRuleSets/default * ``` * */ @ResourceType(type="azure-native:eventhub:NamespaceNetworkRuleSet") public class NamespaceNetworkRuleSet extends com.pulumi.resources.CustomResource { /** * Default Action for Network Rule Set * */ @Export(name="defaultAction", refs={String.class}, tree="[0]") private Output defaultAction; /** * @return Default Action for Network Rule Set * */ public Output> defaultAction() { return Codegen.optional(this.defaultAction); } /** * List of IpRules * */ @Export(name="ipRules", refs={List.class,NWRuleSetIpRulesResponse.class}, tree="[0,1]") private Output> ipRules; /** * @return List of IpRules * */ public Output>> ipRules() { return Codegen.optional(this.ipRules); } /** * The geo-location where the resource lives * */ @Export(name="location", refs={String.class}, tree="[0]") private Output location; /** * @return The geo-location where the resource lives * */ public Output location() { return this.location; } /** * The name of the resource * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return The name of the resource * */ public Output name() { return this.name; } /** * This determines if traffic is allowed over public network. By default it is enabled. If value is SecuredByPerimeter then Inbound and Outbound communication is controlled by the network security perimeter and profile's access rules. * */ @Export(name="publicNetworkAccess", refs={String.class}, tree="[0]") private Output publicNetworkAccess; /** * @return This determines if traffic is allowed over public network. By default it is enabled. If value is SecuredByPerimeter then Inbound and Outbound communication is controlled by the network security perimeter and profile's access rules. * */ public Output> publicNetworkAccess() { return Codegen.optional(this.publicNetworkAccess); } /** * The system meta data relating to this resource. * */ @Export(name="systemData", refs={SystemDataResponse.class}, tree="[0]") private Output systemData; /** * @return The system meta data relating to this resource. * */ public Output systemData() { return this.systemData; } /** * Value that indicates whether Trusted Service Access is Enabled or not. * */ @Export(name="trustedServiceAccessEnabled", refs={Boolean.class}, tree="[0]") private Output trustedServiceAccessEnabled; /** * @return Value that indicates whether Trusted Service Access is Enabled or not. * */ public Output> trustedServiceAccessEnabled() { return Codegen.optional(this.trustedServiceAccessEnabled); } /** * The type of the resource. E.g. "Microsoft.EventHub/Namespaces" or "Microsoft.EventHub/Namespaces/EventHubs" * */ @Export(name="type", refs={String.class}, tree="[0]") private Output type; /** * @return The type of the resource. E.g. "Microsoft.EventHub/Namespaces" or "Microsoft.EventHub/Namespaces/EventHubs" * */ public Output type() { return this.type; } /** * List VirtualNetwork Rules * */ @Export(name="virtualNetworkRules", refs={List.class,NWRuleSetVirtualNetworkRulesResponse.class}, tree="[0,1]") private Output> virtualNetworkRules; /** * @return List VirtualNetwork Rules * */ public Output>> virtualNetworkRules() { return Codegen.optional(this.virtualNetworkRules); } /** * * @param name The _unique_ name of the resulting resource. */ public NamespaceNetworkRuleSet(java.lang.String name) { this(name, NamespaceNetworkRuleSetArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public NamespaceNetworkRuleSet(java.lang.String name, NamespaceNetworkRuleSetArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public NamespaceNetworkRuleSet(java.lang.String name, NamespaceNetworkRuleSetArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:eventhub:NamespaceNetworkRuleSet", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private NamespaceNetworkRuleSet(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("azure-native:eventhub:NamespaceNetworkRuleSet", name, null, makeResourceOptions(options, id), false); } private static NamespaceNetworkRuleSetArgs makeArgs(NamespaceNetworkRuleSetArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? NamespaceNetworkRuleSetArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .aliases(List.of( Output.of(Alias.builder().type("azure-native:eventhub/v20170401:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20180101preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20210101preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20210601preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20211101:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20220101preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20221001preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20230101preview:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20240101:NamespaceNetworkRuleSet").build()), Output.of(Alias.builder().type("azure-native:eventhub/v20240501preview:NamespaceNetworkRuleSet").build()) )) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param options Optional settings to control the behavior of the CustomResource. */ public static NamespaceNetworkRuleSet get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new NamespaceNetworkRuleSet(name, id, options); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy