Hi,
how to get all the word in " [ interfaces ethernet eth2 address dhcp ]" in template node.def with an
accurate way?
VAR(…/@) , VAR(@/…) and similar expressions does have the same value of fixed position when the command path have diffrent tag nodes
example command:
enet@CBCCPE# set interfaces ethernet eth2 address dhcp
[edit]
enet@CBCCPE# commit
[ interfaces ethernet eth2 address dhcp ] // target
Starting DHCP client on eth2 …
eNetCommit-save: saved.
eNetCommit: committed.
[edit]
enet@CBCCPE#
thanks for reply
maybe my description about is not detail
the command " set interfaces ethernet eth2 address dhcp" is only for example to explain the question
if my excute word in the end section of /opt/vyatta/share/vyatta-cfg/templates/node_L1/node_L1/node_l3/node.def
file content is:
help: some help info
end: code to fill # get the full words in the command (“node_L1”, “Node_L2”, “Node_L3” )
in the terminal in config mode, input “set node_L1 node_L2 node_L3 var_value”, then commit
the vyos system will print content include [node_L1, Node_L2, Node_L3 var_value]
the end section code of x/x/templates//node_L1/node_L1/node_l3/node.def will excute, how to
realization the code in the end: section
thanks again