From 0d3bbe11c08b2570922204b5246740952d830c30 Mon Sep 17 00:00:00 2001 From: Alberto Bertogli Date: Sun, 4 Aug 2019 04:52:18 +0100 Subject: [PATCH] test: In the docker entrypoint, wait for minidns to come up The tests might start running and attempting to do DNS resolutions before minidns has come up, which can cause false positives and flaky tests. This patch makes the entrypoint wait until minidns has come up, to fix the problem. --- test/util/docker_entrypoint.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/util/docker_entrypoint.sh b/test/util/docker_entrypoint.sh index 578d895..822267f 100755 --- a/test/util/docker_entrypoint.sh +++ b/test/util/docker_entrypoint.sh @@ -37,6 +37,9 @@ start-stop-daemon --start --background \ echo "nameserver 127.0.0.1" > /etc/resolv.conf echo "nameserver ::1" >> /etc/resolv.conf +# Wait until the minidns resolver comes up. +wait_until_ready 53 + # Launch arguments, which come from docker CMD, as "chasquid" user. # Running tests as root makes some integration tests more difficult, as for # example Exim has hard-coded protections against running as root.