A wrapper around etcd, with some discovery-related additions that calls etcd with the right advertising related URLs.
As described in this Google Groups thread, when running etcd in the context of Kubernetes, there's no straighforward way to discover what IP should be used for the -advertise-client-urls etcd parameter.
Without a correct -advertise-client-urls etcd parameter, code that uses the etcd client API (such as etcdctl) will not work. (curl, on the other hand, will still work)
Instead of invoking etcd via:
$ etcd -listen-client-urls http://0.0.0.0:2379 -advertise-client-urls http://10.1.50.34:2379
You would instead run:
$ etcdisco -listen-client-urls http://0.0.0.0:2379 -advertise-client-urls http://{{.LOCAL_IP}}:2379
This would have the effect of:
{{.LOCAL_IP}} with the discovered ip address| Variable | Description |
|---|---|
| LOCAL_IP | It iterates over all interfaces and returns the IP address of the first non-loopback IP address |
Content type
Image
Digest
sha256:87764ac96…
Size
11.1 MB
Last updated
over 10 years ago
docker pull tleyden5iwx/etcd-discovery