4e4a88a387
This element will install the network modules for dracut and regenerate the initramfs. The network support would allow us to configure the network of the image via kernel cmdline instead of injecting files into the image. Change-Id: I829405127e77aec80b99ac8dd2032cb0c6d81063
21 lines
636 B
Diff
21 lines
636 B
Diff
--- usr/lib/dracut/hooks/pre-pivot/85-write-ifcfg.sh 2013-05-30 14:01:37.492519066 +0000
|
|
+++ /85-write-ifcfg.sh 2013-05-30 14:03:09.832519065 +0000
|
|
@@ -4,6 +4,9 @@
|
|
|
|
# NFS root might have reached here before /tmp/net.ifaces was written
|
|
udevadm settle --timeout=30
|
|
+
|
|
+command -v ip_to_var >/dev/null || . /lib/net-lib.sh
|
|
+
|
|
# Don't write anything if we don't know our bootdev
|
|
[ -f /tmp/net.ifaces ] || return 1
|
|
|
|
@@ -98,6 +101,7 @@
|
|
fi
|
|
cat /sys/class/net/$netif/address > /tmp/net.$netif.hwaddr
|
|
{
|
|
+ ip_to_var $ip
|
|
echo "# Generated by dracut initrd"
|
|
echo "DEVICE=$netif"
|
|
echo "ONBOOT=yes"
|