Sophie

Sophie

distrib > * > 2008.0 > x86_64 > by-pkgid > 4498b81413d3bfb782e6b286934ad6c5 > files > 22

udev-114-7mdv2008.0.src.rpm

#!/bin/sh

[ -z "$INTERFACE" ] && exit 0

[ -r /etc/sysconfig/udev_net ] && . /etc/sysconfig/udev_net
[ -n "$BLACKLIST_ALL" ] && eval "case $INTERFACE in $BLACKLIST_ALL) exit 1;; esac"
[ -n "$BLACKLIST_PERSISTENT" ] && eval "case $INTERFACE in $BLACKLIST_PERSISTENT) exit 1;; esac"

# eagle-usb/firewire create a fake ethX interface
/usr/sbin/ethtool $INTERFACE &>/dev/null || exit 0

# conform to network service (AUTOMATIC_IFCFG)
[ -r /etc/sysconfig/network ] && . /etc/sysconfig/network

CFG=/etc/sysconfig/network-scripts/ifcfg-$INTERFACE

if [ "$AUTOMATIC_IFCFG" != no -a ! -r $CFG ]; then
	debug_mesg creating config file for $INTERFACE
	cat > $CFG <<EOF
DEVICE=$INTERFACE
BOOTPROTO=dhcp
ONBOOT=yes
EOF
fi