CI runs on Ubuntu 16.04 machines, which use iptables (legacy), but
Debian buster uses nftables. Because of this, DNS resolution does not
work if the daemon configures iptables.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit bb0472bd23806327a1ff1ea87343a6a0cadc21e9)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
| ... | ... |
@@ -281,6 +281,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ |
| 281 | 281 |
zip \ |
| 282 | 282 |
&& rm -rf /var/lib/apt/lists/* |
| 283 | 283 |
|
| 284 |
+# Switch to use iptables instead of nftables (to match the host machine) |
|
| 285 |
+RUN update-alternatives --set iptables /usr/sbin/iptables-legacy || true \ |
|
| 286 |
+ && update-alternatives --set ip6tables /usr/sbin/ip6tables-legacy || true \ |
|
| 287 |
+ && update-alternatives --set arptables /usr/sbin/arptables-legacy || true |
|
| 288 |
+ |
|
| 284 | 289 |
RUN pip3 install yamllint==1.16.0 |
| 285 | 290 |
|
| 286 | 291 |
COPY --from=dockercli /build/ /usr/local/cli |