UNPKG

@pulumi/aws-native

Version:

The Pulumi AWS Cloud Control Provider enables you to build, deploy, and manage [any AWS resource that's supported by the AWS Cloud Control API](https://github.com/pulumi/pulumi-aws-native/blob/master/provider/cmd/pulumi-gen-aws-native/supported-types.txt)

80 lines 3.92 kB
"use strict"; // *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.ListenerRule = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("../utilities"); /** * Specifies a listener rule. The listener must be associated with an Application Load Balancer. Each rule consists of a priority, one or more actions, and one or more conditions. * For more information, see [Quotas for your Application Load Balancers](https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-limits.html) in the *User Guide for Application Load Balancers*. */ class ListenerRule extends pulumi.CustomResource { /** * Get an existing ListenerRule 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 opts Optional settings to control the behavior of the CustomResource. */ static get(name, id, opts) { return new ListenerRule(name, undefined, { ...opts, id: id }); } /** * Returns true if the given object is an instance of ListenerRule. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj) { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === ListenerRule.__pulumiType; } /** * Create a ListenerRule resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name, args, opts) { let resourceInputs = {}; opts = opts || {}; if (!opts.id) { if (args?.actions === undefined && !opts.urn) { throw new Error("Missing required property 'actions'"); } if (args?.conditions === undefined && !opts.urn) { throw new Error("Missing required property 'conditions'"); } if (args?.priority === undefined && !opts.urn) { throw new Error("Missing required property 'priority'"); } resourceInputs["actions"] = args?.actions; resourceInputs["conditions"] = args?.conditions; resourceInputs["listenerArn"] = args?.listenerArn; resourceInputs["priority"] = args?.priority; resourceInputs["transforms"] = args?.transforms; resourceInputs["isDefault"] = undefined /*out*/; resourceInputs["ruleArn"] = undefined /*out*/; } else { resourceInputs["actions"] = undefined /*out*/; resourceInputs["conditions"] = undefined /*out*/; resourceInputs["isDefault"] = undefined /*out*/; resourceInputs["listenerArn"] = undefined /*out*/; resourceInputs["priority"] = undefined /*out*/; resourceInputs["ruleArn"] = undefined /*out*/; resourceInputs["transforms"] = undefined /*out*/; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); const replaceOnChanges = { replaceOnChanges: ["listenerArn"] }; opts = pulumi.mergeOptions(opts, replaceOnChanges); super(ListenerRule.__pulumiType, name, resourceInputs, opts); } } exports.ListenerRule = ListenerRule; /** @internal */ ListenerRule.__pulumiType = 'aws-native:elasticloadbalancingv2:ListenerRule'; //# sourceMappingURL=listenerRule.js.map