When setting up macvlan for docker meaning each container can get an external IP on our local network. Also need to make sure those containers can communicate with each other
Temporary
We want to achieve the following in macvlan, however this is only a temporary solution as config will disappear after a reboot.
|
|
Permanent
Need to create a file which on startup will create a macvlan bridge
/etc/networkd-dispatcher/routable.d/10-macvlan-interfaces.sh
|
|
Now we got an interface, will need to create mapping for the docker containers we want to map
/etc/netplan/macvlan.yaml
|
|
Docker
Now we can create a macvlan network
|
|
example lunching a docker container
|
|