0

is it possible to load a dynamic networking config file? I have multiple VMs and i want to configure all at once and not every single VM. Every VM has a eth0 interface and i want to configure a fix ip per VM.

hostname is alex.local

/etc/network/interfaces:

source /etc/network/interfaces.d/$HOSTNAME.cfg

/etc/network/interfaces.d/alex.local.cfg:

auto eth0
iface eth0 inet static
    address 192.168.0.10
    netmask 255.255.255.0
    gateway 192.168.0.1
    dns-nameservers 8.8.8.8

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.