Fedora init script improvement suggested by alex@alex.org.uk
This commit is contained in:
parent
e9e6fbf924
commit
300e4008f0
1 changed files with 7 additions and 2 deletions
|
@ -22,6 +22,9 @@
|
||||||
BIRD4="yes"
|
BIRD4="yes"
|
||||||
BIRD6="yes"
|
BIRD6="yes"
|
||||||
|
|
||||||
|
BIRD4ARGS=
|
||||||
|
BIRD6ARGS=
|
||||||
|
|
||||||
[ -f /etc/bird.conf ] || BIRD4="no"
|
[ -f /etc/bird.conf ] || BIRD4="no"
|
||||||
[ -f /usr/sbin/bird ] || BIRD4="no"
|
[ -f /usr/sbin/bird ] || BIRD4="no"
|
||||||
[ "${NETWORKING}" = "yes" ] || BIRD4="no"
|
[ "${NETWORKING}" = "yes" ] || BIRD4="no"
|
||||||
|
@ -30,6 +33,8 @@ BIRD6="yes"
|
||||||
[ -f /usr/sbin/bird6 ] || BIRD6="no"
|
[ -f /usr/sbin/bird6 ] || BIRD6="no"
|
||||||
[ "${NETWORKING_IPV6}" = "yes" ] || BIRD6="no"
|
[ "${NETWORKING_IPV6}" = "yes" ] || BIRD6="no"
|
||||||
|
|
||||||
|
[ -e /etc/sysconfig/bird ] && . /etc/sysconfig/bird
|
||||||
|
|
||||||
RETVAL=0
|
RETVAL=0
|
||||||
|
|
||||||
# See how we were called.
|
# See how we were called.
|
||||||
|
@ -38,7 +43,7 @@ case "$1" in
|
||||||
if [ "$BIRD4" = "yes" ]
|
if [ "$BIRD4" = "yes" ]
|
||||||
then
|
then
|
||||||
echo -n "Starting BIRD for IPv4: "
|
echo -n "Starting BIRD for IPv4: "
|
||||||
daemon bird
|
daemon bird ${BIRD4ARGS}
|
||||||
RETVAL=$?
|
RETVAL=$?
|
||||||
echo
|
echo
|
||||||
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/bird
|
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/bird
|
||||||
|
@ -46,7 +51,7 @@ case "$1" in
|
||||||
if [ "$BIRD6" = "yes" ]
|
if [ "$BIRD6" = "yes" ]
|
||||||
then
|
then
|
||||||
echo -n "Starting BIRD for IPv6: "
|
echo -n "Starting BIRD for IPv6: "
|
||||||
daemon bird6
|
daemon bird6 ${BIRD6ARGS}
|
||||||
RETVAL=$?
|
RETVAL=$?
|
||||||
echo
|
echo
|
||||||
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/bird6
|
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/bird6
|
||||||
|
|
Loading…
Reference in a new issue