Page MenuHomeVyOS Platform

Extend override-default script to allow embedded defaultValue settings
Closed, ResolvedPublicFEATURE REQUEST

Description

Existing examples of XML fragments overriding the defaultValue element are of the level leafNode, for example:
https://github.com/vyos/vyos-1x/blob/current/interface-definitions/interfaces-tunnel.xml.in#L209-L212

#include <include/interface/parameters-ttl.xml.i>
<leafNode name="ttl">
  <defaultValue>64</defaultValue>
</leafNode>

It is useful to generalize this to allow embedded settings:

#include <include/accel-ppp/radius-additions.xml.i>
 <node name="radius">
   <children>
     <leafNode name="timeout">
       <defaultValue>30</defaultValue>
     </leafNode>
     <leafNode name="acct-timeout">
       <defaultValue>30</defaultValue>
     </leafNode>
   </children>
 </node>

This simply requires cleaning up the empty paths left by the override and merging of defaultValue elements.

Details

Difficulty level
Normal (likely a few hours)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Improvement (missing useful functionality)