# Network adapter configuration
#
# The address format is "scheme,socket,instance,hwaddr".
#
# Note: the "network address" here is NOT the same as the IP address.
# See the Networking HOWTO.  In short, the network address is the IP
# address masked by the netmask.
#
case "$ADDRESS" in
*,*,*,*)
    INFO="Sample private network setup"
    # Transceiver selection, for some cards -- see 'man ifport'
    IF_PORT=""
    # Use BOOTP (via /sbin/bootpc, or /sbin/pump)? [y/n]
    BOOTP="n"
    # Use DHCP (via /sbin/dhcpcd, /sbin/dhclient, or /sbin/pump)? [y/n]
    DHCP="n"
    # If you need to explicitly specify a hostname for DHCP requests
    DHCP_HOSTNAME=""
    # Host's IP address, netmask, network address, broadcast address
    IPADDR=""
    NETMASK="255.255.255.0"
    NETWORK="10.0.1.0"
    BROADCAST="10.0.1.255"
    # Gateway address for static routing
    GATEWAY="10.0.1.1"
    # Things to add to /etc/resolv.conf for this interface
    DOMAIN=""
    SEARCH=""
    DNS_1=""
    DNS_2=""
    DNS_3=""
    # NFS mounts, should be listed in /etc/fstab
    MOUNTS=""
    # If you need to override the interface's MTU...
    MTU=""
    # For IPX interfaces, the frame type and network number
    IPX_FRAME=""
    IPX_NETNUM=""
    # Extra stuff to do after setting up the interface
    start_fn () { return; }
    # Extra stuff to do before shutting down the interface
    stop_fn () { return; }
    # Card eject policy options
    NO_CHECK=n
    NO_FUSER=n
    ;;
esac

# This is used to hook into ALT Linux's network configuration tools.
# You can delete it if that isn't desired.  We look for network
# options in /etc/sysconfig/network-scripts if it appears that the
# interface can't be set up using settings given higher up in this
# file.

is_true $PUMP || is_true $BOOTP || is_true $DHCP ||
[ -x /proc/sys/kernel/hotplug ] || \
if [ -z "$IPADDR" -a -f /etc/sysconfig/network-scripts/ifcfg-$2 ] ; then
    INFO="Red Hat netconf setup"
    start_fn () {
	. /etc/sysconfig/network-scripts/ifcfg-$1
	log /sbin/ifup $1
    }
    stop_fn () {
	log /sbin/ifdown $1
    }
fi
