1. Packages
  2. Ibm Provider
  3. API Docs
  4. getIsLbListenerPolicyRules
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.getIsLbListenerPolicyRules

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Provides a read-only data source for LoadBalancerListenerPolicyRuleCollection. For more information, about load balancer listener policy and rules, see layer 7 load balancing policies and rules.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const example = ibm.getIsLbListenerPolicyRules({
        listener: ibm_is_lb_listener.example.listener_id,
        lb: ibm_is_lb.example.id,
        policy: ibm_is_lb_listener_policy.example.policy_id,
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    example = ibm.get_is_lb_listener_policy_rules(listener=ibm_is_lb_listener["example"]["listener_id"],
        lb=ibm_is_lb["example"]["id"],
        policy=ibm_is_lb_listener_policy["example"]["policy_id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.GetIsLbListenerPolicyRules(ctx, &ibm.GetIsLbListenerPolicyRulesArgs{
    			Listener: ibm_is_lb_listener.Example.Listener_id,
    			Lb:       ibm_is_lb.Example.Id,
    			Policy:   ibm_is_lb_listener_policy.Example.Policy_id,
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Ibm.GetIsLbListenerPolicyRules.Invoke(new()
        {
            Listener = ibm_is_lb_listener.Example.Listener_id,
            Lb = ibm_is_lb.Example.Id,
            Policy = ibm_is_lb_listener_policy.Example.Policy_id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IbmFunctions;
    import com.pulumi.ibm.inputs.GetIsLbListenerPolicyRulesArgs;
    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) {
            final var example = IbmFunctions.getIsLbListenerPolicyRules(GetIsLbListenerPolicyRulesArgs.builder()
                .listener(ibm_is_lb_listener.example().listener_id())
                .lb(ibm_is_lb.example().id())
                .policy(ibm_is_lb_listener_policy.example().policy_id())
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ibm:getIsLbListenerPolicyRules
          arguments:
            listener: ${ibm_is_lb_listener.example.listener_id}
            lb: ${ibm_is_lb.example.id}
            policy: ${ibm_is_lb_listener_policy.example.policy_id}
    

    Using getIsLbListenerPolicyRules

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getIsLbListenerPolicyRules(args: GetIsLbListenerPolicyRulesArgs, opts?: InvokeOptions): Promise<GetIsLbListenerPolicyRulesResult>
    function getIsLbListenerPolicyRulesOutput(args: GetIsLbListenerPolicyRulesOutputArgs, opts?: InvokeOptions): Output<GetIsLbListenerPolicyRulesResult>
    def get_is_lb_listener_policy_rules(id: Optional[str] = None,
                                        lb: Optional[str] = None,
                                        listener: Optional[str] = None,
                                        policy: Optional[str] = None,
                                        opts: Optional[InvokeOptions] = None) -> GetIsLbListenerPolicyRulesResult
    def get_is_lb_listener_policy_rules_output(id: Optional[pulumi.Input[str]] = None,
                                        lb: Optional[pulumi.Input[str]] = None,
                                        listener: Optional[pulumi.Input[str]] = None,
                                        policy: Optional[pulumi.Input[str]] = None,
                                        opts: Optional[InvokeOptions] = None) -> Output[GetIsLbListenerPolicyRulesResult]
    func GetIsLbListenerPolicyRules(ctx *Context, args *GetIsLbListenerPolicyRulesArgs, opts ...InvokeOption) (*GetIsLbListenerPolicyRulesResult, error)
    func GetIsLbListenerPolicyRulesOutput(ctx *Context, args *GetIsLbListenerPolicyRulesOutputArgs, opts ...InvokeOption) GetIsLbListenerPolicyRulesResultOutput

    > Note: This function is named GetIsLbListenerPolicyRules in the Go SDK.

    public static class GetIsLbListenerPolicyRules 
    {
        public static Task<GetIsLbListenerPolicyRulesResult> InvokeAsync(GetIsLbListenerPolicyRulesArgs args, InvokeOptions? opts = null)
        public static Output<GetIsLbListenerPolicyRulesResult> Invoke(GetIsLbListenerPolicyRulesInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetIsLbListenerPolicyRulesResult> getIsLbListenerPolicyRules(GetIsLbListenerPolicyRulesArgs args, InvokeOptions options)
    public static Output<GetIsLbListenerPolicyRulesResult> getIsLbListenerPolicyRules(GetIsLbListenerPolicyRulesArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getIsLbListenerPolicyRules:getIsLbListenerPolicyRules
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Lb string
    The load balancer identifier.
    Listener string
    The listener identifier.
    Policy string
    The policy identifier.
    Id string
    (String) The rule's unique identifier.
    Lb string
    The load balancer identifier.
    Listener string
    The listener identifier.
    Policy string
    The policy identifier.
    Id string
    (String) The rule's unique identifier.
    lb String
    The load balancer identifier.
    listener String
    The listener identifier.
    policy String
    The policy identifier.
    id String
    (String) The rule's unique identifier.
    lb string
    The load balancer identifier.
    listener string
    The listener identifier.
    policy string
    The policy identifier.
    id string
    (String) The rule's unique identifier.
    lb str
    The load balancer identifier.
    listener str
    The listener identifier.
    policy str
    The policy identifier.
    id str
    (String) The rule's unique identifier.
    lb String
    The load balancer identifier.
    listener String
    The listener identifier.
    policy String
    The policy identifier.
    id String
    (String) The rule's unique identifier.

    getIsLbListenerPolicyRules Result

    The following output properties are available:

    Id string
    (String) The rule's unique identifier.
    Lb string
    Listener string
    Policy string
    Rules List<GetIsLbListenerPolicyRulesRule>
    (List) Collection of rules. Nested scheme for rules:
    Id string
    (String) The rule's unique identifier.
    Lb string
    Listener string
    Policy string
    Rules []GetIsLbListenerPolicyRulesRule
    (List) Collection of rules. Nested scheme for rules:
    id String
    (String) The rule's unique identifier.
    lb String
    listener String
    policy String
    rules List<GetIsLbListenerPolicyRulesRule>
    (List) Collection of rules. Nested scheme for rules:
    id string
    (String) The rule's unique identifier.
    lb string
    listener string
    policy string
    rules GetIsLbListenerPolicyRulesRule[]
    (List) Collection of rules. Nested scheme for rules:
    id str
    (String) The rule's unique identifier.
    lb str
    listener str
    policy str
    rules Sequence[GetIsLbListenerPolicyRulesRule]
    (List) Collection of rules. Nested scheme for rules:
    id String
    (String) The rule's unique identifier.
    lb String
    listener String
    policy String
    rules List<Property Map>
    (List) Collection of rules. Nested scheme for rules:

    Supporting Types

    GetIsLbListenerPolicyRulesRule

    Condition string
    (String) The condition of the rule.
    CreatedAt string
    (String) The date and time that this rule was created.
    Field string
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    Href string
    (String) The rule's canonical URL.
    Id string
    (String) The rule's unique identifier.
    ProvisioningStatus string
    (String) The provisioning status of this rule.
    Type string
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    Value string
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.
    Condition string
    (String) The condition of the rule.
    CreatedAt string
    (String) The date and time that this rule was created.
    Field string
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    Href string
    (String) The rule's canonical URL.
    Id string
    (String) The rule's unique identifier.
    ProvisioningStatus string
    (String) The provisioning status of this rule.
    Type string
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    Value string
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.
    condition String
    (String) The condition of the rule.
    createdAt String
    (String) The date and time that this rule was created.
    field String
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    href String
    (String) The rule's canonical URL.
    id String
    (String) The rule's unique identifier.
    provisioningStatus String
    (String) The provisioning status of this rule.
    type String
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    value String
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.
    condition string
    (String) The condition of the rule.
    createdAt string
    (String) The date and time that this rule was created.
    field string
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    href string
    (String) The rule's canonical URL.
    id string
    (String) The rule's unique identifier.
    provisioningStatus string
    (String) The provisioning status of this rule.
    type string
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    value string
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.
    condition str
    (String) The condition of the rule.
    created_at str
    (String) The date and time that this rule was created.
    field str
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    href str
    (String) The rule's canonical URL.
    id str
    (String) The rule's unique identifier.
    provisioning_status str
    (String) The provisioning status of this rule.
    type str
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    value str
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.
    condition String
    (String) The condition of the rule.
    createdAt String
    (String) The date and time that this rule was created.
    field String
    (Optional, String) The field. This is applicable to header, query, and body rule types.If the rule type is header, this property is required.If the rule type is query, this is optional. If specified and the rule condition is notmatches_regex, the value must be percent-encoded.If the rule type is body, this is optional.
    href String
    (String) The rule's canonical URL.
    id String
    (String) The rule's unique identifier.
    provisioningStatus String
    (String) The provisioning status of this rule.
    type String
    (String) The type of the rule.Body rules are applied to form-encoded request bodies using the UTF-8 character set.
    value String
    (String) Value to be matched for rule condition.If the rule type is query and the rule condition is not matches_regex, the value must be percent-encoded.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud