1. Packages
  2. Juniper Mist
  3. API Docs
  4. site
  5. Wxrule
Juniper Mist v0.0.27 published on Friday, Sep 27, 2024 by Pulumi

junipermist.site.Wxrule

Explore with Pulumi AI

junipermist logo
Juniper Mist v0.0.27 published on Friday, Sep 27, 2024 by Pulumi

    This resource manages the Site WxRules (WLAN policies). A WxLAN policy is a set of rules and settings that can be applied to devices in a network to determine how they are treated. it provides support for access policies, network segmentation, role-based policies, micro-segmentation, and least privilege. WxLAN policies are used to allow or deny specific users from accessing specific resources in a wireless network.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as junipermist from "@pulumi/juniper-mist";
    
    const wxruleOne = new junipermist.site.Wxrule("wxrule_one", {
        siteId: terraformTest.id,
        srcWxtags: [wxtagOne.id],
        enabled: true,
        action: "allow",
        dstDenyWxtags: [wxtagTwo.id],
        order: 1,
    });
    
    import pulumi
    import pulumi_juniper_mist as junipermist
    
    wxrule_one = junipermist.site.Wxrule("wxrule_one",
        site_id=terraform_test["id"],
        src_wxtags=[wxtag_one["id"]],
        enabled=True,
        action="allow",
        dst_deny_wxtags=[wxtag_two["id"]],
        order=1)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-junipermist/sdk/go/junipermist/site"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := site.NewWxrule(ctx, "wxrule_one", &site.WxruleArgs{
    			SiteId: pulumi.Any(terraformTest.Id),
    			SrcWxtags: pulumi.StringArray{
    				wxtagOne.Id,
    			},
    			Enabled: pulumi.Bool(true),
    			Action:  pulumi.String("allow"),
    			DstDenyWxtags: pulumi.StringArray{
    				wxtagTwo.Id,
    			},
    			Order: pulumi.Int(1),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using JuniperMist = Pulumi.JuniperMist;
    
    return await Deployment.RunAsync(() => 
    {
        var wxruleOne = new JuniperMist.Site.Wxrule("wxrule_one", new()
        {
            SiteId = terraformTest.Id,
            SrcWxtags = new[]
            {
                wxtagOne.Id,
            },
            Enabled = true,
            Action = "allow",
            DstDenyWxtags = new[]
            {
                wxtagTwo.Id,
            },
            Order = 1,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.junipermist.site.Wxrule;
    import com.pulumi.junipermist.site.WxruleArgs;
    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 wxruleOne = new Wxrule("wxruleOne", WxruleArgs.builder()
                .siteId(terraformTest.id())
                .srcWxtags(wxtagOne.id())
                .enabled(true)
                .action("allow")
                .dstDenyWxtags(wxtagTwo.id())
                .order(1)
                .build());
    
        }
    }
    
    resources:
      wxruleOne:
        type: junipermist:site:Wxrule
        name: wxrule_one
        properties:
          siteId: ${terraformTest.id}
          srcWxtags:
            - ${wxtagOne.id}
          enabled: true
          action: allow
          dstDenyWxtags:
            - ${wxtagTwo.id}
          order: 1
    

    Create Wxrule Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Wxrule(name: string, args: WxruleArgs, opts?: CustomResourceOptions);
    @overload
    def Wxrule(resource_name: str,
               args: WxruleArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Wxrule(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               action: Optional[str] = None,
               order: Optional[int] = None,
               site_id: Optional[str] = None,
               apply_tags: Optional[Sequence[str]] = None,
               blocked_apps: Optional[Sequence[str]] = None,
               dst_allow_wxtags: Optional[Sequence[str]] = None,
               dst_deny_wxtags: Optional[Sequence[str]] = None,
               dst_wxtags: Optional[Sequence[str]] = None,
               enabled: Optional[bool] = None,
               src_wxtags: Optional[Sequence[str]] = None)
    func NewWxrule(ctx *Context, name string, args WxruleArgs, opts ...ResourceOption) (*Wxrule, error)
    public Wxrule(string name, WxruleArgs args, CustomResourceOptions? opts = null)
    public Wxrule(String name, WxruleArgs args)
    public Wxrule(String name, WxruleArgs args, CustomResourceOptions options)
    
    type: junipermist:site:Wxrule
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args WxruleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args WxruleArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args WxruleArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WxruleArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WxruleArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var junipermistWxruleResource = new JuniperMist.Site.Wxrule("junipermistWxruleResource", new()
    {
        Action = "string",
        Order = 0,
        SiteId = "string",
        ApplyTags = new[]
        {
            "string",
        },
        BlockedApps = new[]
        {
            "string",
        },
        DstAllowWxtags = new[]
        {
            "string",
        },
        DstDenyWxtags = new[]
        {
            "string",
        },
        DstWxtags = new[]
        {
            "string",
        },
        Enabled = false,
        SrcWxtags = new[]
        {
            "string",
        },
    });
    
    example, err := site.NewWxrule(ctx, "junipermistWxruleResource", &site.WxruleArgs{
    	Action: pulumi.String("string"),
    	Order:  pulumi.Int(0),
    	SiteId: pulumi.String("string"),
    	ApplyTags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	BlockedApps: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	DstAllowWxtags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	DstDenyWxtags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	DstWxtags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Enabled: pulumi.Bool(false),
    	SrcWxtags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var junipermistWxruleResource = new Wxrule("junipermistWxruleResource", WxruleArgs.builder()
        .action("string")
        .order(0)
        .siteId("string")
        .applyTags("string")
        .blockedApps("string")
        .dstAllowWxtags("string")
        .dstDenyWxtags("string")
        .dstWxtags("string")
        .enabled(false)
        .srcWxtags("string")
        .build());
    
    junipermist_wxrule_resource = junipermist.site.Wxrule("junipermistWxruleResource",
        action="string",
        order=0,
        site_id="string",
        apply_tags=["string"],
        blocked_apps=["string"],
        dst_allow_wxtags=["string"],
        dst_deny_wxtags=["string"],
        dst_wxtags=["string"],
        enabled=False,
        src_wxtags=["string"])
    
    const junipermistWxruleResource = new junipermist.site.Wxrule("junipermistWxruleResource", {
        action: "string",
        order: 0,
        siteId: "string",
        applyTags: ["string"],
        blockedApps: ["string"],
        dstAllowWxtags: ["string"],
        dstDenyWxtags: ["string"],
        dstWxtags: ["string"],
        enabled: false,
        srcWxtags: ["string"],
    });
    
    type: junipermist:site:Wxrule
    properties:
        action: string
        applyTags:
            - string
        blockedApps:
            - string
        dstAllowWxtags:
            - string
        dstDenyWxtags:
            - string
        dstWxtags:
            - string
        enabled: false
        order: 0
        siteId: string
        srcWxtags:
            - string
    

    Wxrule Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Wxrule resource accepts the following input properties:

    Action string
    type of action, allow / block. enum: allow, block
    Order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    SiteId string
    ApplyTags List<string>
    BlockedApps List<string>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    DstAllowWxtags List<string>
    List of WxTag UUID to indicate these tags are allowed access
    DstDenyWxtags List<string>
    List of WxTag UUID to indicate these tags are blocked access
    DstWxtags List<string>
    List of WxTag UUID
    Enabled bool
    SrcWxtags List<string>
    List of WxTag UUID to determine if this rule would match
    Action string
    type of action, allow / block. enum: allow, block
    Order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    SiteId string
    ApplyTags []string
    BlockedApps []string
    blocked apps (always blocking, ignoring action), the key of Get Application List
    DstAllowWxtags []string
    List of WxTag UUID to indicate these tags are allowed access
    DstDenyWxtags []string
    List of WxTag UUID to indicate these tags are blocked access
    DstWxtags []string
    List of WxTag UUID
    Enabled bool
    SrcWxtags []string
    List of WxTag UUID to determine if this rule would match
    action String
    type of action, allow / block. enum: allow, block
    order Integer
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId String
    applyTags List<String>
    blockedApps List<String>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags List<String>
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags List<String>
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags List<String>
    List of WxTag UUID
    enabled Boolean
    srcWxtags List<String>
    List of WxTag UUID to determine if this rule would match
    action string
    type of action, allow / block. enum: allow, block
    order number
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId string
    applyTags string[]
    blockedApps string[]
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags string[]
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags string[]
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags string[]
    List of WxTag UUID
    enabled boolean
    srcWxtags string[]
    List of WxTag UUID to determine if this rule would match
    action str
    type of action, allow / block. enum: allow, block
    order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    site_id str
    apply_tags Sequence[str]
    blocked_apps Sequence[str]
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dst_allow_wxtags Sequence[str]
    List of WxTag UUID to indicate these tags are allowed access
    dst_deny_wxtags Sequence[str]
    List of WxTag UUID to indicate these tags are blocked access
    dst_wxtags Sequence[str]
    List of WxTag UUID
    enabled bool
    src_wxtags Sequence[str]
    List of WxTag UUID to determine if this rule would match
    action String
    type of action, allow / block. enum: allow, block
    order Number
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId String
    applyTags List<String>
    blockedApps List<String>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags List<String>
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags List<String>
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags List<String>
    List of WxTag UUID
    enabled Boolean
    srcWxtags List<String>
    List of WxTag UUID to determine if this rule would match

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Wxrule resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Wxrule Resource

    Get an existing Wxrule resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: WxruleState, opts?: CustomResourceOptions): Wxrule
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            action: Optional[str] = None,
            apply_tags: Optional[Sequence[str]] = None,
            blocked_apps: Optional[Sequence[str]] = None,
            dst_allow_wxtags: Optional[Sequence[str]] = None,
            dst_deny_wxtags: Optional[Sequence[str]] = None,
            dst_wxtags: Optional[Sequence[str]] = None,
            enabled: Optional[bool] = None,
            order: Optional[int] = None,
            site_id: Optional[str] = None,
            src_wxtags: Optional[Sequence[str]] = None) -> Wxrule
    func GetWxrule(ctx *Context, name string, id IDInput, state *WxruleState, opts ...ResourceOption) (*Wxrule, error)
    public static Wxrule Get(string name, Input<string> id, WxruleState? state, CustomResourceOptions? opts = null)
    public static Wxrule get(String name, Output<String> id, WxruleState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Action string
    type of action, allow / block. enum: allow, block
    ApplyTags List<string>
    BlockedApps List<string>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    DstAllowWxtags List<string>
    List of WxTag UUID to indicate these tags are allowed access
    DstDenyWxtags List<string>
    List of WxTag UUID to indicate these tags are blocked access
    DstWxtags List<string>
    List of WxTag UUID
    Enabled bool
    Order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    SiteId string
    SrcWxtags List<string>
    List of WxTag UUID to determine if this rule would match
    Action string
    type of action, allow / block. enum: allow, block
    ApplyTags []string
    BlockedApps []string
    blocked apps (always blocking, ignoring action), the key of Get Application List
    DstAllowWxtags []string
    List of WxTag UUID to indicate these tags are allowed access
    DstDenyWxtags []string
    List of WxTag UUID to indicate these tags are blocked access
    DstWxtags []string
    List of WxTag UUID
    Enabled bool
    Order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    SiteId string
    SrcWxtags []string
    List of WxTag UUID to determine if this rule would match
    action String
    type of action, allow / block. enum: allow, block
    applyTags List<String>
    blockedApps List<String>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags List<String>
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags List<String>
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags List<String>
    List of WxTag UUID
    enabled Boolean
    order Integer
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId String
    srcWxtags List<String>
    List of WxTag UUID to determine if this rule would match
    action string
    type of action, allow / block. enum: allow, block
    applyTags string[]
    blockedApps string[]
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags string[]
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags string[]
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags string[]
    List of WxTag UUID
    enabled boolean
    order number
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId string
    srcWxtags string[]
    List of WxTag UUID to determine if this rule would match
    action str
    type of action, allow / block. enum: allow, block
    apply_tags Sequence[str]
    blocked_apps Sequence[str]
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dst_allow_wxtags Sequence[str]
    List of WxTag UUID to indicate these tags are allowed access
    dst_deny_wxtags Sequence[str]
    List of WxTag UUID to indicate these tags are blocked access
    dst_wxtags Sequence[str]
    List of WxTag UUID
    enabled bool
    order int
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    site_id str
    src_wxtags Sequence[str]
    List of WxTag UUID to determine if this rule would match
    action String
    type of action, allow / block. enum: allow, block
    applyTags List<String>
    blockedApps List<String>
    blocked apps (always blocking, ignoring action), the key of Get Application List
    dstAllowWxtags List<String>
    List of WxTag UUID to indicate these tags are allowed access
    dstDenyWxtags List<String>
    List of WxTag UUID to indicate these tags are blocked access
    dstWxtags List<String>
    List of WxTag UUID
    enabled Boolean
    order Number
    the order how rules would be looked up, > 0 and bigger order got matched first, -1 means LAST, uniqueness not checked
    siteId String
    srcWxtags List<String>
    List of WxTag UUID to determine if this rule would match

    Import

    Using pulumi import, import mist_site_wxrule with:

    Site WxRule can be imported by specifying the site_id and the wxrule_id

    $ pulumi import junipermist:site/wxrule:Wxrule wxrule_one 17b46405-3a6d-4715-8bb4-6bb6d06f316a.d3c42998-9012-4859-9743-6b9bee475309
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    junipermist pulumi/pulumi-junipermist
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the mist Terraform Provider.
    junipermist logo
    Juniper Mist v0.0.27 published on Friday, Sep 27, 2024 by Pulumi