This is a tiny network proxy written in Go that can resolve target address with AWS CloudMap service discovery service.
No Route 53 integration is necessary.
cloudmap-proxy -cache-ttl 60s -conn-timeout 10s -debug aws-servicediscovery:namespace-name:service-name:8080 :8080
cloudmap-proxy [-cache-ttl TTL] [-conn-timeout TTL] [-debug] TARGET_ADDR LISTEN_ADDR
-
-cache-ttlSpecify cache duration. (default: 1m0s) The value must be followed by a duration unit.
-
-conn-timeoutSpecify connection timeout. (default: 10s) The value must be followed by a duration unit.
-
-debugTurn on debug mode
-
TARGET_ADDR
The following formats are accepted:
-
HOST:PORTHOST may be bracketed IPv6 form (
[::1]) -
aws-servicediscovery:namespaceName:serviceNameDo the discovery for service
serviceNamein the namespacenamespaceName. -
aws-servicediscovery-v4:namespaceName:serviceNameDo the discovery for service
serviceNamein the namespacenamespaceName, with the preference for IPv4 . -
aws-servicediscovery-v6:namespaceName:serviceNameDo the discovery for service
serviceNamein the namespacenamespaceName, with the preference for IPv6.
-
-
LISTEN_ADDR
The following formats are accepted:
-
HOST:PORT -
:PORT
-