I have a bare metal server on Hetzner with IP 188.8.131.52 and 8 additional IPs reserved for me.
IPs: 184.108.40.206 to 220.127.116.11
Now I want to create Docker network with type macvlan
docker network create macvlan --subnet=18.104.22.168/29 --gateway=22.214.171.124 -o parent=enp0s31f6 macvlan1
But this command causes an error
no matching subnet for gateway 126.96.36.199
Note when I set for example IP 188.8.131.52 and gateway 184.108.40.206 on a virtual machine on the host, it works correctly! but I can’t set this none matching gateway in Docker network create command.