adding ifmetric that was accidentally left out
Change-Id: I591e2fe976b35b9fca8ab8ef78f76822b96841bf
This commit is contained in:
parent
1f9ab9754c
commit
720de322fa
35
contrib/image-elements/ifmetric/post-install.d/90-ifmetric
Executable file
35
contrib/image-elements/ifmetric/post-install.d/90-ifmetric
Executable file
@ -0,0 +1,35 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -eux
|
||||
|
||||
install-packages ifmetric
|
||||
|
||||
cat <<EOF > /etc/network/interfaces
|
||||
# The loopback network interface
|
||||
auto lo
|
||||
iface lo inet loopback
|
||||
|
||||
source /etc/network/interfaces.d/*
|
||||
EOF
|
||||
|
||||
mkdir -p /etc/network/interfaces.d
|
||||
rm /etc/network/interfaces.d/*
|
||||
|
||||
cat <<EOF > /etc/network/interfaces.d/eth0
|
||||
# The primary network interface
|
||||
allow-hotplug eth0
|
||||
iface eth0 inet dhcp
|
||||
metric 0
|
||||
EOF
|
||||
|
||||
cat <<EOF > /etc/network/interfaces.d/eth1
|
||||
allow-hotplug eth1
|
||||
iface eth1 inet dhcp
|
||||
metric 1
|
||||
EOF
|
||||
|
||||
cat <<EOF > /etc/network/interfaces.d/eth2
|
||||
allow-hotplug eth2
|
||||
iface eth2 inet dhcp
|
||||
metric 2
|
||||
EOF
|
Loading…
Reference in New Issue
Block a user