docker-compose: Align hosts with hostname 87/68487/1 stable/hunter
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 16 Sep 2019 15:18:17 +0000 (17:18 +0200)
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Mon, 16 Sep 2019 15:57:14 +0000 (17:57 +0200)
commit90cd9b2c1ddefffa6a02addbc24718fd2e9bf3d7
tree5101a1a83ae69b7bc78bc177ad7f1652e0555be2
parent09ec1e9cc02268c45d5cfd5a289b53a52d9c6e94
docker-compose: Align hosts with hostname

When using Docker CE 19.x, `hostname -d` fails to properly resolve
the domainname due to changes in the way Docker sets it inside the
container.

Work around this issue by aligning the contents of `/etc/hostname`
with `/etc/hosts`, so `hostname -d` can properly determine the
domain name. This also requires calling `hostname -b` via cfg01
entrypoint.sh.

Change-Id: I697b5d9882e3d6641712a00bca10012800ee1898
Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
mcp/scripts/.gitignore
mcp/scripts/docker-compose/files/entrypoint.sh
mcp/scripts/docker-compose/files/hosts.j2 [moved from mcp/scripts/docker-compose/files/hosts with 74% similarity]