NetworkListenerProps

class aws_cdk.aws_elasticloadbalancingv2.NetworkListenerProps(*, port, certificates=None, default_action=None, default_target_groups=None, protocol=None, ssl_policy=None, load_balancer)

Bases: aws_cdk.aws_elasticloadbalancingv2.BaseNetworkListenerProps

__init__(*, port, certificates=None, default_action=None, default_target_groups=None, protocol=None, ssl_policy=None, load_balancer)

Properties for a Network Listener attached to a Load Balancer.

Parameters
  • port (Union[int, float]) – The port on which the listener listens for requests.

  • certificates (Optional[List[IListenerCertificate]]) – Certificate list of ACM cert ARNs. Default: - No certificates.

  • default_action (Optional[NetworkListenerAction]) – Default action to take for requests to this listener. This allows full control of the default Action of the load balancer, including weighted forwarding. See the NetworkListenerAction class for all options. Cannot be specified together with defaultTargetGroups. Default: - None.

  • default_target_groups (Optional[List[INetworkTargetGroup]]) – Default target groups to load balance to. All target groups will be load balanced to with equal weight and without stickiness. For a more complex configuration than that, use either defaultAction or addAction(). Cannot be specified together with defaultAction. Default: - None.

  • protocol (Optional[Protocol]) – Protocol for listener, expects TCP or TLS. Default: - TLS if certificates are provided. TCP otherwise.

  • ssl_policy (Optional[SslPolicy]) – SSL Policy. Default: - Current predefined security policy.

  • load_balancer (INetworkLoadBalancer) – The load balancer to attach this listener to.

Return type

None

Attributes

certificates

Certificate list of ACM cert ARNs.

default :default: - No certificates.

Return type

Optional[List[IListenerCertificate]]

default_action

Default action to take for requests to this listener.

This allows full control of the default Action of the load balancer, including weighted forwarding. See the NetworkListenerAction class for all options.

Cannot be specified together with defaultTargetGroups.

default :default: - None.

Return type

Optional[NetworkListenerAction]

default_target_groups

Default target groups to load balance to.

All target groups will be load balanced to with equal weight and without stickiness. For a more complex configuration than that, use either defaultAction or addAction().

Cannot be specified together with defaultAction.

default :default: - None.

Return type

Optional[List[INetworkTargetGroup]]

load_balancer

The load balancer to attach this listener to.

Return type

INetworkLoadBalancer

port

The port on which the listener listens for requests.

Return type

Union[int, float]

protocol

Protocol for listener, expects TCP or TLS.

default :default: - TLS if certificates are provided. TCP otherwise.

Return type

Optional[Protocol]

ssl_policy

SSL Policy.

default :default: - Current predefined security policy.

Return type

Optional[SslPolicy]