[__bird_radv] add --default-lifetime parameter
This commit is contained in:
parent
f101ea4afa
commit
f01f110463
3 changed files with 13 additions and 0 deletions
|
@ -34,6 +34,11 @@ route-preference
|
|||
This option specifies the default value of advertised route preference for
|
||||
specific routes. Default: medium.
|
||||
|
||||
default-lifetime
|
||||
This option specifies the time (in seconds) how long (since the receipt of RA)
|
||||
hosts may use the router as a default router. 0 means do not use as a default
|
||||
router. Default: 3.
|
||||
|
||||
OPTIONAL MULTIPLE PARAMETERS
|
||||
----------------------------
|
||||
route
|
||||
|
|
|
@ -73,6 +73,12 @@ then
|
|||
ROUTE_PREFERENCE="route preference $(cat "${__object:?}/parameter/route-preference");"
|
||||
fi
|
||||
|
||||
DEFAULT_LIFETIME=
|
||||
if [ -f "${__object:?}/parameter/default-lifetime" ];
|
||||
then
|
||||
DEFAULT_LIFETIME="default lifetime $(cat "${__object:?}/parameter/default-lifetime");"
|
||||
fi
|
||||
|
||||
__file "${confdir:?}/radv-${__object_id:?}.conf" \
|
||||
--mode 0640 --owner root --group bird \
|
||||
--source - << EOF
|
||||
|
@ -91,6 +97,7 @@ protocol radv ${__object_id:?} {
|
|||
|
||||
interface "$(cat "${__object:?}/parameter/interface")" {
|
||||
$MTU
|
||||
$DEFAULT_LIFETIME
|
||||
$DEFAULT_PREFERENCE
|
||||
$ROUTE_PREFERENCE
|
||||
};
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
mtu
|
||||
default-preference
|
||||
route-preference
|
||||
default-lifetime
|
||||
|
|
Loading…
Reference in a new issue