about summary refs log tree commit diff stats
path: root/core/conf/rc.d/net
diff options
context:
space:
mode:
authorSilvino Silva <silvino@bk.ru>2021-02-12 03:59:34 +0000
committerSilvino Silva <silvino@bk.ru>2021-02-12 03:59:34 +0000
commita3628fc49db4d88ff3e4067268650710d1da3f6f (patch)
tree8fdac6dfc8cabb9f85a2db3a3bd628cfe44438cd /core/conf/rc.d/net
parent0a6b0fc9769daf0932cb207c3285baa31547b489 (diff)
downloaddoc-a3628fc49db4d88ff3e4067268650710d1da3f6f.tar.gz
initial openbsd support
Diffstat (limited to 'core/conf/rc.d/net')
-rwxr-xr-xcore/conf/rc.d/net54
1 files changed, 0 insertions, 54 deletions
diff --git a/core/conf/rc.d/net b/core/conf/rc.d/net
deleted file mode 100755
index a4c566a..0000000
--- a/core/conf/rc.d/net
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/sh
-#
-# /etc/rc.d/net: start/stop network interface
-#
-
-# Connection type: "DHCP" or "static"
-TYPE="DHCP"
-
-# For "static" connections, specify your settings here:
-# To see your available devices run "ip link".
-DEV=ens3
-ADDR=192.168.1.100
-MASK=24
-GW=192.168.1.1
-
-# Optional settings:
-DHCPOPTS="-t 10"
-
-/sbin/ifconfig dummy down > /dev/null 2>&1
-/sbin/ifconfig dummy0 down > /dev/null 2>&1
-/sbin/ifconfig ifb0 down > /dev/null 2>&1
-/sbin/ifconfig ifb1 down > /dev/null 2>&1
-/sbin/ifconfig bond0 down > /dev/null 2>&1
-
-case $1 in
-	start)
-		if [ "${TYPE}" = "DHCP" ]; then
-			/sbin/dhcpcd ${DHCPOPTS}
-		else
-			/sbin/ip addr add ${ADDR}/${MASK} dev ${DEV} broadcast +
-			/sbin/ip link set ${DEV} up
-			/sbin/ip route add default via ${GW}
-		fi
-		;;
-	stop)
-		if [ "${TYPE}" = "DHCP" ]; then
-			/sbin/dhcpcd -x
-		else
-			/sbin/ip route del default
-			/sbin/ip link set ${DEV} down
-			/sbin/ip addr del ${ADDR}/${MASK} dev ${DEV}
-		fi
-		;;
-	restart)
-		$0 stop
-		$0 start
-		;;
-	*)
-		echo "Usage: $0 [start|stop|restart]"
-		;;
-esac
-
-# End of file
-