mirror of
https://github.com/motioneye-project/motioneyeos.git
synced 2025-07-27 05:06:39 +00:00
Start networking on boot, and setup a default set of network
interfaces (just loopback for now).
This commit is contained in:
parent
7c9afbdbdc
commit
80e368b2b8
35
sources/target_skeleton/etc/init.d/S40network
Executable file
35
sources/target_skeleton/etc/init.d/S40network
Executable file
@ -0,0 +1,35 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
#
|
||||||
|
# Start the network....
|
||||||
|
#
|
||||||
|
|
||||||
|
start() {
|
||||||
|
echo "Starting network..."
|
||||||
|
/sbin/ifup -a
|
||||||
|
}
|
||||||
|
stop() {
|
||||||
|
echo -n "Stopping network..."
|
||||||
|
/sbin/ifdown -a
|
||||||
|
}
|
||||||
|
restart() {
|
||||||
|
stop
|
||||||
|
start
|
||||||
|
}
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
start)
|
||||||
|
start
|
||||||
|
;;
|
||||||
|
stop)
|
||||||
|
stop
|
||||||
|
;;
|
||||||
|
restart|reload)
|
||||||
|
restart
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo $"Usage: $0 {start|stop|restart}"
|
||||||
|
exit 1
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit $?
|
||||||
|
|
4
sources/target_skeleton/etc/network/interfaces
Normal file
4
sources/target_skeleton/etc/network/interfaces
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
# Configure Loopback
|
||||||
|
auto lo
|
||||||
|
iface lo inet loopback
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user