summaryrefslogtreecommitdiff
blob: 7eb706d0b0f7b2881158aefc8792d3f57b9df2f4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/sbin/runscript
# Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
# Distributed under the terms of the GNU General Public License, v2 or later
# $Header: /var/cvsroot/gentoo-x86/app-admin/quickswitch/files/net.eth0-switchto.rc6,v 1.2 2003/02/14 22:22:33 vapier Exp $

checkconfig() {
	if [ ! -e /etc/quickswitch/switch.conf ]; then
		eerror "You need a /etc/quickswitch/switch.conf file to run quickswitch"
		eerror "A sample file is located in /etc/quickswitch/switch.conf.sample"
		return 1
	fi
}

start() {
	checkconfig || return 1
	ebegin "Switching network config"
	/usr/bin/switchto -s > /dev/null 2>&1
	end $?
}

end() {
	echo > /dev/null 2>&1
}