MT#10059 allow freeform interface definitions in init.d script

Squashed commit of the following:

commit 0f98bd7304c484740b7d3416bd8843205e1b589f
Author: Richard Fuchs <rfuchs@sipwise.com>
Date:   Tue Dec 16 13:37:06 2014 -0500

    fix init script

commit 90dc259399aad0de86fcfd2c76b03b4e1cad2157
Author: Richard Fuchs <rfuchs@sipwise.com>
Date:   Tue Dec 16 12:17:42 2014 -0500

    MT#10059 allow freeform interface definitions in init.d script
pull/53/head
Richard Fuchs 11 years ago
parent 407722599b
commit 7e72bfc90f

@ -2,10 +2,9 @@ RUN_RTPENGINE=no
LISTEN_TCP=25060
LISTEN_UDP=12222
LISTEN_NG=22222
# ADDRESS=...
# ADV_ADDRESS=...
# ADDRESS_IPV6=...
# ADV_ADDRESS_IPV6=...
# INTERFACES="123.234.345.456"
# INTERFACES="internal/12.23.34.45 external/23.34.45.54"
# INTERFACES="12.23.34.45!23.34.45.56"
TIMEOUT=60
SILENT_TIMEOUT=3600
PIDFILE=/var/run/ngcp-rtpengine-daemon.pid

@ -43,6 +43,11 @@ set -e
OPTIONS=""
if [ ! -z "$INTERFACES" ]; then
for interface in $INTERFACES; do
OPTIONS="$OPTIONS --interface=$interface"
done
fi
[ -z "$ADDRESS" ] || OPTIONS="$OPTIONS --interface=$ADDRESS"
[ -z "$ADV_ADDRESS" ] || OPTIONS="$OPTIONS!$ADV_ADDRESS"
[ -z "$ADDRESS_IPV6" ] || OPTIONS="$OPTIONS --interface=$ADDRESS_IPV6"

Loading…
Cancel
Save