resolvable icon indicating copy to clipboard operation
resolvable copied to clipboard

Added by Schinti95: IP Address lookup when using docker networks.

Open fjmk opened this issue 8 years ago • 0 comments

As of Docker 1.10, the docker daemon implements an embedded DNS server which provides built-in service discovery for any container created with a valid name or net-alias or aliased by link.

I am using:

  • Docker version 1.11.2, build b9f10c9
  • docker-compose version 1.7.1, build 0a9ab35,

with a Version 2 yaml file. Composer adds a [dir]_default network by default.

I get errors when using gliderlabs/resolvable:master:

resolvable_1  | 2016/06/19 04:52:56 Starting resolvable 0.2 ...
resolvable_1  | 2016/06/19 04:52:56 got local address: 172.18.0.2
resolvable_1  | 2016/06/19 04:52:56 updating resolv.conf: /tmp/resolv.conf
resolvable_1  | 2016/06/19 04:52:56 error adding container d60615318259: unknown network mode%!(EXTRA string=drupal7_default)
resolvable_1  | 2016/06/19 04:52:56 error adding container d60615318259: unknown network mode%!(EXTRA string=drupal7_default)
resolvable_1  | 2016/06/19 04:52:56 error adding container 9f4c649a0fcf: unknown network mode%!(EXTRA string=drupal7_default)

After building Schinti95's repo, the errors are gone:

resolvable_1  | 2016/06/19 05:05:21 Starting resolvable 0.2 ...
resolvable_1  | 2016/06/19 05:05:21 got local address: 172.18.0.2
resolvable_1  | 2016/06/19 05:05:21 updating resolv.conf: /tmp/resolv.conf
resolvable_1  | 2016/06/19 05:05:21 Found Container with IP:  172.18.0.2 from Network:  drupal7_default
resolvable_1  | 2016/06/19 05:05:21 Found Container with IP:  172.18.0.3 from Network:  drupal7_default

Looks good to me.

fjmk avatar Jun 19 '16 05:06 fjmk