Docker CE 19.03.12 on Ubuntu Server 20.04.1 - curl on macvlan network not working

Hi all

I am struggling with a new install of Docker CE 19.03.12 on Ubuntu Server 20.04.1 - everything has initially been working fine, until I tried to start a container that uses curl to download a file as part of it’s initialization.

The file download always fails - yet I can download it successfully from the Docker host, and from any other machine on the network - thus I think it’s something to do with the Docker install itself and not the firewall or network.

It almost feels like an MTU issue, but I’ve tried adding:

{
  "mtu": 1454
}

to /etc/docker/daemon.json and restarting, but to not avail.

Sometimes from within the container, curl can download a few percent of the file, before it hangs and subsequently times out. Sometimes it fails to download it at all (i.e. the download doesn’t even begin).

The container is being brought up using a docker-compose file, and is using a MACVLAN network. It previously worked on an earlier incarnation of Docker CE on Ubuntu Server 16.04, so this problem seems to relate to the later version of Docker CE and/or Ubuntu.

Any ideas on how to fix this or debug it further?

Many thanks

James