Home | History | Annotate | Line # | Download | only in rc.d
routed revision 1.9.10.1
      1       1.1    lukem #!/bin/sh
      2       1.1    lukem #
      3  1.9.10.1   bouyer # $NetBSD: routed,v 1.9.10.1 2007/04/28 18:02:58 bouyer Exp $
      4       1.1    lukem #
      5       1.1    lukem 
      6       1.1    lukem # PROVIDE: routed
      7  1.9.10.1   bouyer # REQUIRE: network
      8  1.9.10.1   bouyer # BEFORE:  NETWORKING
      9       1.1    lukem 
     10       1.8  mycroft $_rc_subr_loaded . /etc/rc.subr
     11       1.1    lukem 
     12       1.1    lukem name="routed"
     13       1.5    lukem rcvar=$name
     14       1.3    enami command="/sbin/${name}"
     15       1.1    lukem start_precmd="routed_precmd"
     16       1.1    lukem 
     17       1.1    lukem routed_precmd()
     18       1.1    lukem {
     19       1.1    lukem 	if checkyesno gated && checkyesno routed; then
     20       1.1    lukem 		warn "gated and routed both requested to be run: only running gated."
     21       1.1    lukem 		return 1
     22       1.1    lukem 	fi
     23       1.1    lukem }
     24       1.1    lukem 
     25       1.4    lukem load_rc_config $name
     26       1.9    lukem load_rc_config_var gated gated
     27       1.1    lukem run_rc_command "$1"
     28