Show / Hide Table of Contents

Class L7RuleV2

Manages a V2 L7 Rule resource within OpenStack.

Example Usage

using Pulumi;
using OpenStack = Pulumi.OpenStack;

class MyStack : Stack
{
public MyStack()
{
    var network1 = new OpenStack.Networking.Network("network1", new OpenStack.Networking.NetworkArgs
    {
        AdminStateUp = "true",
    });
    var subnet1 = new OpenStack.Networking.Subnet("subnet1", new OpenStack.Networking.SubnetArgs
    {
        Cidr = "192.168.199.0/24",
        IpVersion = 4,
        NetworkId = network1.Id,
    });
    var loadbalancer1 = new OpenStack.LoadBalancer.LoadBalancer("loadbalancer1", new OpenStack.LoadBalancer.LoadBalancerArgs
    {
        VipSubnetId = subnet1.Id,
    });
    var listener1 = new OpenStack.LoadBalancer.Listener("listener1", new OpenStack.LoadBalancer.ListenerArgs
    {
        LoadbalancerId = loadbalancer1.Id,
        Protocol = "HTTP",
        ProtocolPort = 8080,
    });
    var pool1 = new OpenStack.LoadBalancer.Pool("pool1", new OpenStack.LoadBalancer.PoolArgs
    {
        LbMethod = "ROUND_ROBIN",
        LoadbalancerId = loadbalancer1.Id,
        Protocol = "HTTP",
    });
    var l7policy1 = new OpenStack.LoadBalancer.L7PolicyV2("l7policy1", new OpenStack.LoadBalancer.L7PolicyV2Args
    {
        Action = "REDIRECT_TO_URL",
        Description = "test description",
        ListenerId = listener1.Id,
        Position = 1,
        RedirectUrl = "http://www.example.com",
    });
    var l7rule1 = new OpenStack.LoadBalancer.L7RuleV2("l7rule1", new OpenStack.LoadBalancer.L7RuleV2Args
    {
        CompareType = "EQUAL_TO",
        L7policyId = l7policy1.Id,
        Type = "PATH",
        Value = "/api",
    });
}

}
Inheritance
System.Object
Resource
CustomResource
L7RuleV2
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.OpenStack.LoadBalancer
Assembly: Pulumi.OpenStack.dll
Syntax
public class L7RuleV2 : CustomResource

Constructors

View Source

L7RuleV2(String, L7RuleV2Args, CustomResourceOptions)

Create a L7RuleV2 resource with the given unique name, arguments, and options.

Declaration
public L7RuleV2(string name, L7RuleV2Args args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

L7RuleV2Args args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

AdminStateUp

The administrative state of the L7 Rule. A valid value is true (UP) or false (DOWN).

Declaration
public Output<bool?> AdminStateUp { get; }
Property Value
Type Description
Output<System.Nullable<System.Boolean>>
View Source

CompareType

The comparison type for the L7 rule - can either be CONTAINS, STARTS_WITH, ENDS_WITH, EQUAL_TO or REGEX

Declaration
public Output<string> CompareType { get; }
Property Value
Type Description
Output<System.String>
View Source

Invert

When true the logic of the rule is inverted. For example, with invert true, equal to would become not equal to. Default is false.

Declaration
public Output<bool?> Invert { get; }
Property Value
Type Description
Output<System.Nullable<System.Boolean>>
View Source

Key

The key to use for the comparison. For example, the name of the cookie to evaluate. Valid when type is set to COOKIE or HEADER.

Declaration
public Output<string> Key { get; }
Property Value
Type Description
Output<System.String>
View Source

L7policyId

The ID of the L7 Policy to query. Changing this creates a new L7 Rule.

Declaration
public Output<string> L7policyId { get; }
Property Value
Type Description
Output<System.String>
View Source

ListenerId

The ID of the Listener owning this resource.

Declaration
public Output<string> ListenerId { get; }
Property Value
Type Description
Output<System.String>
View Source

Region

The region in which to obtain the V2 Networking client. A Networking client is needed to create an . If omitted, the region argument of the provider is used. Changing this creates a new L7 Rule.

Declaration
public Output<string> Region { get; }
Property Value
Type Description
Output<System.String>
View Source

TenantId

Required for admins. The UUID of the tenant who owns the L7 Rule. Only administrative users can specify a tenant UUID other than their own. Changing this creates a new L7 Rule.

Declaration
public Output<string> TenantId { get; }
Property Value
Type Description
Output<System.String>
View Source

Type

The L7 Rule type - can either be COOKIE, FILE_TYPE, HEADER, HOST_NAME or PATH.

Declaration
public Output<string> Type { get; }
Property Value
Type Description
Output<System.String>
View Source

Value

The value to use for the comparison. For example, the file type to compare.

Declaration
public Output<string> Value { get; }
Property Value
Type Description
Output<System.String>

Methods

View Source

Get(String, Input<String>, L7RuleV2State, CustomResourceOptions)

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

Declaration
public static L7RuleV2 Get(string name, Input<string> id, L7RuleV2State state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

L7RuleV2State state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
L7RuleV2
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.