ea3f4dd459
ensure 4 spaces indentation is used everywhere. Change-Id: Ieb48faacb4c96b7b358771d70c17f2f22d0354f4
20 lines
755 B
Bash
Executable File
20 lines
755 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -eu
|
|
set -o pipefail
|
|
|
|
# If the patch doesn't apply just do nothing. This patch fixes a small
|
|
# issue in the script that writes the network configuration files from
|
|
# the cmdline to the disk on FC18/FC19.
|
|
#
|
|
#for dracut-network 029 we need a different patch:
|
|
# http://git.kernel.org/cgit/boot/dracut/dracut.git/commit/?id=613ed5cd764d54cac082a1e7b7e8d1f1fed29d35
|
|
IFCFG_FILE="/usr/lib/dracut/modules.d/45ifcfg/write-ifcfg.sh"
|
|
NETGEN_FILE="/usr/lib/dracut/modules.d/40network/net-genrules.sh"
|
|
|
|
if patch --dry-run $NETGEN_FILE < $(dirname $0)/../dracut-029-netgen.patch > /dev/null; then
|
|
patch $NETGEN_FILE < $(dirname $0)/../dracut-029-netgen.patch || true
|
|
else
|
|
patch $IFCFG_FILE < $(dirname $0)/../dracut-write-ifcfg.patch || true
|
|
fi
|