20 lines
296 B
Plaintext
20 lines
296 B
Plaintext
|
#!/bin/sh /etc/rc.common
|
||
|
# Copyright (C) 2009 OpenWrt.org
|
||
|
START=50
|
||
|
|
||
|
BIN=opensips
|
||
|
DEFAULT=/etc/default/$BIN
|
||
|
RUN_D=/var/run
|
||
|
PID_F=$RUN_D/$BIN.pid
|
||
|
|
||
|
start() {
|
||
|
[ -f $DEFAULT ] && . $DEFAULT
|
||
|
mkdir -p $RUN_D
|
||
|
$BIN -P $PID_F $OPTIONS >/dev/null 2>&1
|
||
|
}
|
||
|
|
||
|
stop() {
|
||
|
[ -f $PID_F ] && kill $(cat $PID_F)
|
||
|
}
|
||
|
|