com.pulumi.azure.paloalto.kotlin.LocalRulestack.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-azure-kotlin Show documentation
Show all versions of pulumi-azure-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.paloalto.kotlin
import com.pulumi.core.Output
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
/**
* Builder for [LocalRulestack].
*/
@PulumiTagMarker
public class LocalRulestackResourceBuilder internal constructor() {
public var name: String? = null
public var args: LocalRulestackArgs = LocalRulestackArgs()
public var opts: CustomResourceOptions = CustomResourceOptions()
/**
* @param name The _unique_ name of the resulting resource.
*/
public fun name(`value`: String) {
this.name = value
}
/**
* @param block The arguments to use to populate this resource's properties.
*/
public suspend fun args(block: suspend LocalRulestackArgsBuilder.() -> Unit) {
val builder = LocalRulestackArgsBuilder()
block(builder)
this.args = builder.build()
}
/**
* @param block A bag of options that control this resource's behavior.
*/
public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
}
internal fun build(): LocalRulestack {
val builtJavaResource = com.pulumi.azure.paloalto.LocalRulestack(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return LocalRulestack(builtJavaResource)
}
}
/**
* Manages a Palo Alto Networks Rulestack.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azure from "@pulumi/azure";
* const example = new azure.core.ResourceGroup("example", {
* name: "rg-example",
* location: "West Europe",
* });
* const exampleLocalRulestack = new azure.paloalto.LocalRulestack("example", {
* name: "example",
* resourceGroupName: example.name,
* location: example.location,
* });
* ```
* ```python
* import pulumi
* import pulumi_azure as azure
* example = azure.core.ResourceGroup("example",
* name="rg-example",
* location="West Europe")
* example_local_rulestack = azure.paloalto.LocalRulestack("example",
* name="example",
* resource_group_name=example.name,
* location=example.location)
* ```
* ```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 = "rg-example",
* Location = "West Europe",
* });
* var exampleLocalRulestack = new Azure.PaloAlto.LocalRulestack("example", new()
* {
* Name = "example",
* ResourceGroupName = example.Name,
* Location = example.Location,
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/paloalto"
* "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("rg-example"),
* Location: pulumi.String("West Europe"),
* })
* if err != nil {
* return err
* }
* _, err = paloalto.NewLocalRulestack(ctx, "example", &paloalto.LocalRulestackArgs{
* Name: pulumi.String("example"),
* ResourceGroupName: example.Name,
* Location: example.Location,
* })
* 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.paloalto.LocalRulestack;
* import com.pulumi.azure.paloalto.LocalRulestackArgs;
* 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("rg-example")
* .location("West Europe")
* .build());
* var exampleLocalRulestack = new LocalRulestack("exampleLocalRulestack", LocalRulestackArgs.builder()
* .name("example")
* .resourceGroupName(example.name())
* .location(example.location())
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: azure:core:ResourceGroup
* properties:
* name: rg-example
* location: West Europe
* exampleLocalRulestack:
* type: azure:paloalto:LocalRulestack
* name: example
* properties:
* name: example
* resourceGroupName: ${example.name}
* location: ${example.location}
* ```
*
* ## Import
* Palo Alto Networks Rulestacks can be imported using the `resource id`, e.g.
* ```sh
* $ pulumi import azure:paloalto/localRulestack:LocalRulestack example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/mygroup1/providers/PaloAltoNetworks.Cloudngfw/localRulestacks/myLocalRulestack
* ```
*/
public class LocalRulestack internal constructor(
override val javaResource: com.pulumi.azure.paloalto.LocalRulestack,
) : KotlinCustomResource(javaResource, LocalRulestackMapper) {
/**
* The setting to use for Anti-Spyware. Possible values include `BestPractice`, and `Custom`.
*/
public val antiSpywareProfile: Output?
get() = javaResource.antiSpywareProfile().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The setting to use for Anti-Virus. Possible values include `BestPractice`, and `Custom`.
*/
public val antiVirusProfile: Output?
get() = javaResource.antiVirusProfile().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The description for this Local Rulestack.
*/
public val description: Output?
get() = javaResource.description().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* TThe setting to use for DNS Subscription. Possible values include `BestPractice`, and `Custom`.
*/
public val dnsSubscription: Output?
get() = javaResource.dnsSubscription().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The setting to use for the File Blocking Profile. Possible values include `BestPractice`, and `Custom`.
*/
public val fileBlockingProfile: Output?
get() = javaResource.fileBlockingProfile().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Azure Region where the Palo Alto Networks Rulestack should exist. Changing this forces a new Palo Alto Networks Rulestack to be created.
*/
public val location: Output
get() = javaResource.location().applyValue({ args0 -> args0 })
/**
* The name which should be used for this Palo Alto Networks Rulestack. Changing this forces a new Palo Alto Networks Rulestack to be created.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
/**
* The name of the Resource Group where the Palo Alto Networks Rulestack should exist. Changing this forces a new Palo Alto Networks Rulestack to be created.
*/
public val resourceGroupName: Output
get() = javaResource.resourceGroupName().applyValue({ args0 -> args0 })
/**
* The setting to use for the URL Filtering Profile. Possible values include `BestPractice`, and `Custom`.
*/
public val urlFilteringProfile: Output?
get() = javaResource.urlFilteringProfile().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The setting to use for the Vulnerability Profile. Possible values include `BestPractice`, and `Custom`.
*/
public val vulnerabilityProfile: Output?
get() = javaResource.vulnerabilityProfile().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
}
public object LocalRulestackMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.azure.paloalto.LocalRulestack::class == javaResource::class
override fun map(javaResource: Resource): LocalRulestack = LocalRulestack(
javaResource as
com.pulumi.azure.paloalto.LocalRulestack,
)
}
/**
* @see [LocalRulestack].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [LocalRulestack].
*/
public suspend fun localRulestack(
name: String,
block: suspend LocalRulestackResourceBuilder.() -> Unit,
): LocalRulestack {
val builder = LocalRulestackResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [LocalRulestack].
* @param name The _unique_ name of the resulting resource.
*/
public fun localRulestack(name: String): LocalRulestack {
val builder = LocalRulestackResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy