- Update to lateste git HEAD 48b7ab1b35adf1f3f09f883ef14ea0a3fba1e468 Added: dracut_v37_to_HEAD.patch Modified: 0013-Correct-paths-for-openSUSE.patch Modified: mdraid-setup.patch Modified: replace_dhclient_with_wickedd_dhcp_supplicants.patch Deleted: 0018-fstab-do-not-mount-and-fsck-from-fstab-if-using-syst.patch Deleted: 0019-dracut-initqueue-service-runs-before-remote-fs-pre.t.patch - Fix lvm and other possible not working thing due to new parameter: hostonly-cmdline which has to be active by default bnc#874000 bnc#874905 bnc#874363 Added: mkinird_differ_host_and_cmdline_only_properly.patch - Make write-ifcfg-suse.sh more update robust Avoid rebasing of diff with every update touching this file by adding write-ifcfg-suse.sh as source file and copy/link in .spec file. Modified: change_write_ifcfg_to_suse.patch OBS-URL: https://build.opensuse.org/request/show/232233 OBS-URL: https://build.opensuse.org/package/show/Base:System/dracut?expand=0&rev=138
55 lines
2.1 KiB
Diff
55 lines
2.1 KiB
Diff
From dc3ce2b641e458c0030476ebdd0bb86783dd98e4 Mon Sep 17 00:00:00 2001
|
|
From: Pawel Wieczorkiewicz <pwieczorkiewicz@suse.de>
|
|
Date: Tue, 8 Apr 2014 08:48:27 +0200
|
|
Subject: [PATCH] 45ifcfg: use distro-specific scripts
|
|
|
|
Detect the system flavor and write the ifcfg files accordingly.
|
|
|
|
Signed-off-by: Hannes Reinecke <hare@suse.de>
|
|
Modified-by: Thomas Rennigner <trenn@suse.de>
|
|
- Do not move ifcfg to -suse and -redhat files to avoid re-diffing after
|
|
each upgrade. Handle this in the spec file and a separate
|
|
write-ifcfg-suse.sh source file
|
|
---
|
|
modules.d/40network/ifup.sh | 1 +
|
|
modules.d/45ifcfg/module-setup.sh | 8 +-
|
|
modules.d/45ifcfg/write-ifcfg-redhat.sh | 271 ++++++++++++++++++++++++++++++++
|
|
modules.d/45ifcfg/write-ifcfg-suse.sh | 183 +++++++++++++++++++++
|
|
modules.d/45ifcfg/write-ifcfg.sh | 271 --------------------------------
|
|
5 files changed, 462 insertions(+), 272 deletions(-)
|
|
create mode 100755 modules.d/45ifcfg/write-ifcfg-redhat.sh
|
|
create mode 100755 modules.d/45ifcfg/write-ifcfg-suse.sh
|
|
delete mode 100755 modules.d/45ifcfg/write-ifcfg.sh
|
|
|
|
diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
|
|
index 25ce094..65f5f4c 100755
|
|
--- a/modules.d/40network/ifup.sh
|
|
+++ b/modules.d/40network/ifup.sh
|
|
@@ -186,6 +186,7 @@ do_dhcp() {
|
|
$dhclient --test $netif > /tmp/leaseinfo.${netif}.dhcp.ipv${1:1:1}
|
|
dhcp_apply $1 || return $?
|
|
|
|
+ echo $netif > /tmp/net.${netif}.did-setup
|
|
echo $netif > /tmp/setup_net_${netif}.ok
|
|
return 0
|
|
}
|
|
diff --git a/modules.d/45ifcfg/module-setup.sh b/modules.d/45ifcfg/module-setup.sh
|
|
index c407f45..164a580 100755
|
|
--- a/modules.d/45ifcfg/module-setup.sh
|
|
+++ b/modules.d/45ifcfg/module-setup.sh
|
|
@@ -4,7 +4,13 @@
|
|
|
|
# called by dracut
|
|
check() {
|
|
- [[ -d /etc/sysconfig/network-scripts ]] && return 0
|
|
+ local link=$(readlink $moddir/write-ifcfg.sh)
|
|
+ [[ "$link" = "write-ifcfg-suse.sh" ]] && \
|
|
+ [[ -d /etc/sysconfig/network ]] && \
|
|
+ return 0
|
|
+ [[ "$link" = "write-ifcfg-redhat.sh" ]] && \
|
|
+ [[ -d /etc/sysconfig/network-scripts ]] && \
|
|
+ return 0
|
|
return 255
|
|
}
|
|
|