Skip to main content

AwsEcsAlbServiceModuleSchema

AwsEcsAlbServiceModuleSchema is the input schema for the AwsEcsAlbServiceModule module: one Application Load Balancer, the subnets it sits in, the ports it listens on, and which requests reach which execution.

@group

Modules/Service/AwsEcsAlbService

@see

AwsEcsAlbServiceModule to learn more about the AwsEcsAlbServiceModule module.

Index

Properties

albName

albName: string

The load balancer's name, unique in its region, at most 32 characters.

listeners

listeners: Pick<{ awsAccountId: string; awsRegionId: string; DefaultActions: ({ action: AlbListenerActionFixedResponseActionSchema; actionType: fixed-response } | { action: AlbListenerActionForwardConfigSchema; actionType: forward } | { action: AlbListenerActionRedirectActionSchema; actionType: redirect })[]; Port: number; Protocol: HTTP; rules: { actions: ({ action: AlbListenerActionFixedResponseActionSchema; actionType: fixed-response } | { action: AlbListenerActionForwardConfigSchema; actionType: forward } | { action: AlbListenerActionRedirectActionSchema; actionType: redirect })[]; conditions: ({ condition: AlbListenerRuleHostHeaderConditionSchema; conditionType: host-header } | { condition: AlbListenerRuleHttpHeaderConditionSchema; conditionType: http-header } | { condition: AlbListenerRuleHttpRequestMethodConditionSchema; conditionType: http-request-method } | { condition: AlbListenerRulePathPatternConditionSchema; conditionType: path-pattern } | { condition: AlbListenerRuleQueryStringConditionSchema; conditionType: query-string } | { condition: AlbListenerRuleSourceIpConditionSchema; conditionType: source-ip })[]; Priority: number }[] }, DefaultActions | Port | rules>[]

The ports the load balancer listens on, each over plain HTTP, and what it does with a request:

  • Port - the port it listens on, e.g. 80.
  • rules - rules matched in priority order, each with conditions on the request (host-header, http-header, http-request-method, path-pattern, query-string or source-ip) and the action taken when they match. May be empty.
  • DefaultActions - exactly one action, taken when no rule matches.

An action is forward to target groups, redirect to another URL, or fixed-response with a body of its own.

region

region: Region

The region the load balancer is in, from AwsMultiAzRegionModule.

subnets

subnets: Subnet[]

The public subnets the load balancer sits in, from AwsSimpleSubnetModule: at least two, in different availability zones.

optionaltargets

The target groups a listener's forward action sends requests to. See AwsEcsAlbServiceModuleTargetGroupSchema.