Allow for configuration of which environment variable to search for #12
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I found myself with the need to run two load balancers pointing to the same ECS cluster, but servicing different services through separate reverse proxies (internal vs. external). While another way to get around this would be to create more than one cluster we found it more efficient to utilize the resources of one cluster ... What that meant was we needed a way to tell the reverse proxy which containers to pay attention to, without them both proxying the same containers. I've created a fork of
ecs-nginx-proxy
as well which uses my version ofecs-gen
and pushed to docker hub here in case you wanted to test it out.This PR gives the ability to specify (via the command line or by environment variable) which environment variable to search container definitions for to use as the hostname. It defaults to
virtual_host
(the current behaviour).While this doesn't quite address the question in #10 - it does allow the use of a differently named environment variable.