Now that routes for IP over ATM may look much more complex than before,

use the atmconfig(8) utility instead of route(8) to install those routes.
For this we need a new rc.conf variable natm_static_routes that works
just like static_routes except that the referenced routes use the syntax
of atmconfig(8).

Okay'ed by:	mtm
This commit is contained in:
Hartmut Brandt 2003-08-14 15:27:32 +00:00
parent 946e86b7e1
commit 8b296e19bd
3 changed files with 22 additions and 0 deletions

View File

@ -219,6 +219,7 @@ nis_yppasswdd_flags="" # Flags to rpc.yppasswdd (if enabled).
### Network routing options: ###
defaultrouter="NO" # Set to default gateway (or NO).
static_routes="" # Set to static route list (or leave empty).
natm_static_routes="" # Set to static route list for NATM (or leave empty).
gateway_enable="NO" # Set to YES if this host will be a gateway.
router_enable="NO" # Set to YES to enable a routing daemon.
router="/sbin/routed" # Name of routing daemon to use if enabled.

View File

@ -48,6 +48,14 @@ static_start()
route add ${route_args}
done
fi
# Now ATM static routes
#
if [ -n "${natm_static_routes}" ]; then
for i in ${natm_static_routes}; do
eval route_args=\$route_${i}
atmconfig natm add ${route_args}
done
fi
}
options_start()

View File

@ -1551,6 +1551,19 @@ variable is assumed to exist
whose contents will later be passed to a
.Dq Nm route Cm add Fl inet6
operation.
.It Va natm_static_routes
.Pq Vt str
The
.Xr natmip 4
equivalent of
.Va static_routes .
If not empty then for each whitespace separated
.Ar element
in the value, a
.Va route_ Ns Aq Ar element
variable is assumed to exist whose contents will later be passed to a
.Dq Nm atmconfig Cm natm Cm add
operation.
.It Va gateway_enable
.Pq Vt bool
If set to