Cross posted in r/vyos: Reddit - Dive into anything
I am working on tooling that talks with vyos api and need to automatically define some configs that can be used via the api.
It seems to me the correct place to read the definitions would be by cloning GitHub - vyos/vyos-1x: VyOS command definitions, scripts, and utilities and run make interface_definitions and look in build/interface-definitions. Is this correct or is it just an intermediate step and it would be better to look in template-cfg directory after running the make command?
For finding defined config paths, build/interface-definitions is likely easier to parse then the directory structure and shell scripts of template-cfg. Some more detail on what you are trying to do would help me to provide further guidance.
Thanks for the reply. I have been working on improving / adding resources to foltiks terraform provider. My first attempt ended up a bit too manual, so I am now looking into auto generating resources based on the interface definitions.
So I am now just starting by creating some base/core types based on the schemas, and then I was planing on using the build/interface-definitions to auto create the structure used to talk with the api.
Hope that helped to clear it up a bit.
I agree this folder seems to be the simplest so far since I can use golang xml package to read the definitions.