ssm-services/init.d/network

21 lines
381 B
Plaintext
Raw Normal View History

2013-09-28 23:32:39 +00:00
#!/usr/bin/env watchman
service_type='oneshot'
2014-02-25 00:45:13 +00:00
service_command='ip'
service_args='link set lo up'
2013-09-28 23:32:39 +00:00
start() {
watchman.msg "Activating the loopback interface (lo)..."
2014-02-25 00:45:13 +00:00
watchman.start
2013-09-28 23:32:39 +00:00
}
stop() {
watchman.status || {
watchman.err "$service_name is already disabled"
return 1
}
watchman.msg "Deactivating the loopback interface (lo)..."
ip link set lo down
watchman.stop
}