Skip to main content

Endpoint Group

Submodule for provisioning Global Accelerator Endpoint Groups.

This submodule takes in a variable config that is essentially fully compliant with the aws_globalaccelerator_endpoint_group resource, except that listener_arn is specified separately and that the config object supports a dynamic lookup of endpoint_id inside the endpoint_configuration list:

module "endpoint_group" {
source = "cloudposse/global-accelerator/aws//modules/endpoint-group"
# Cloud Posse recommends pinning every module to a specific version
# version = "x.x.x"

context = module.this.context

listener_arn = "arn:aws:globalaccelerator::111111111111:accelerator/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/listener/xxxxxxxx"
config = {
endpoint_region = "us-east-1"
endpoint_configuration = [
{
endpoint_lb_name = "my-load-balancer"
}
]
}
}

For more information, see Inputs.

Requirements

No requirements.

Providers

NameVersion
awsn/a

Modules

NameSourceVersion
thiscloudposse/label/null0.24.1

Resources

NameType
aws_globalaccelerator_endpoint_group.defaultresource
aws_lb.lbdata source

Inputs

NameDescriptionTypeDefaultRequired
additional_tag_mapAdditional tags for appending to tags_as_list_of_maps. Not added to tags.map(string){}no
attributesAdditional attributes (e.g. 1)list(string)[]no
configEndpoint Group configuration.

This object needs to be fully compliant with the aws_globalaccelerator_endpoint_group resource, except for the following differences:

* listener_arn, which is specified separately, is omitted.
* The values for endpoint_configuration and port_override within each object in endpoint_groups should be lists.
* Inside the endpoint_configuration block, endpoint_lb_name can be supplied in place of endpoint_id as long as it is a valid unique name for an existing ALB or NLB.

For more information, see: aws_globalaccelerator_endpoint_group.
anyn/ayes
contextSingle object for setting entire context at once.
See description of individual variables for details.
Leave string and numeric variables as null to use default value.
Individual variable settings (non-null) override settings in context object,
except for attributes, tags, and additional_tag_map, which are merged.
any
{
"additional_tag_map": {},
"attributes": [],
"delimiter": null,
"enabled": true,
"environment": null,
"id_length_limit": null,
"label_key_case": null,
"label_order": [],
"label_value_case": null,
"name": null,
"namespace": null,
"regex_replace_chars": null,
"stage": null,
"tags": {}
}
no
delimiterDelimiter to be used between namespace, environment, stage, name and attributes.
Defaults to - (hyphen). Set to "" to use no delimiter at all.
stringnullno
enabledSet to false to prevent the module from creating any resourcesboolnullno
environmentEnvironment, e.g. 'uw2', 'us-west-2', OR 'prod', 'staging', 'dev', 'UAT'stringnullno
id_length_limitLimit id to this many characters (minimum 6).
Set to 0 for unlimited length.
Set to null for default, which is 0.
Does not affect id_full.
numbernullno
label_key_caseThe letter case of label keys (tag names) (i.e. name, namespace, environment, stage, attributes) to use in tags.
Possible values: lower, title, upper.
Default value: title.
stringnullno
label_orderThe naming order of the id output and Name tag.
Defaults to ["namespace", "environment", "stage", "name", "attributes"].
You can omit any of the 5 elements, but at least one must be present.
list(string)nullno
label_value_caseThe letter case of output label values (also used in tags and id).
Possible values: lower, title, upper and none (no transformation).
Default value: lower.
stringnullno
listener_arnThe ARN of the Global Accelerator Listener which this Endpoint Group will be associated with.stringn/ayes
nameSolution name, e.g. 'app' or 'jenkins'stringnullno
namespaceNamespace, which could be your organization name or abbreviation, e.g. 'eg' or 'cp'stringnullno
regex_replace_charsRegex to replace chars with empty string in namespace, environment, stage and name.
If not set, "/[^a-zA-Z0-9-]/" is used to remove all characters other than hyphens, letters and digits.
stringnullno
stageStage, e.g. 'prod', 'staging', 'dev', OR 'source', 'build', 'test', 'deploy', 'release'stringnullno
tagsAdditional tags (e.g. map('BusinessUnit','XYZ')map(string){}no

Outputs

NameDescription
idn/a