packages/net/pepperspot/files/pepperspot.init
jow 2f313d45f9 [packages] pepperspot: use service wrappers, use network.sh to find ip address
git-svn-id: svn://svn.openwrt.org/openwrt/packages@31946 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-05-28 15:20:46 +00:00

20 lines
315 B
Bash

#!/bin/sh /etc/rc.common
# Copyright (C) 2008-2012 OpenWrt.org
START=50
SERVICE_USE_PID=1
SERVICE_PID_FILE=/var/run/pepper.pid
start() {
. /lib/functions/network.sh
local ipaddr
network_get_ipaddr ipaddr lan && \
service_start /usr/sbin/pepper --dns1="$ipaddr"
}
stop() {
service_stop /usr/sbin/pepper
}