Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Location of metadata.yaml and implications thereof #148

Open
NathanDotTo opened this issue Dec 19, 2023 · 1 comment
Open

Location of metadata.yaml and implications thereof #148

NathanDotTo opened this issue Dec 19, 2023 · 1 comment

Comments

@NathanDotTo
Copy link
Contributor

Hi, I am working through how to run the code in this repo. I am given to understand that the starting point is in sdwan_config_builder. In that directory, the README says:

By default sdwan_config_build looks for a 'metadata.yaml' file in the directory where it is run.

The only metadata.yaml file that is in the repo is in the config dir, alongside a config.example.yaml.

The minimal_env.sh has:

export CONFIG_BUILDER_METADATA="../config/metadata.yaml"

This implies, then, that the overall starting point must be to run the minimal_env.sh from the bin directory first. I think that step should be documented in the top level README then.

The metadata.yaml refers to:

top_level_config: "../config/config.yaml"

Whereas we have a config.example.yaml in the repo. I think, then, that the config.example.yaml should be copied to a config.yaml and suitably edited.

If this is correct so far, then I can add suitable documentation updates and submit a PR.

Thanks

Nathan

@ljakab
Copy link
Member

ljakab commented Dec 19, 2023

Probably the best "documentation" on how to run the code of this repo as an end user could be the CircleCI pipeline definition (which I run daily in my personal CircleCI account, and is usually working end-to-end): .circleci/config.yml. The caveat being that CircleCI has a UI to define environment variables, which in the case of a CLI run is done by editing bin/minimal_env.sh.

So yes, roughly one defines the expected outcome in the config/config.yaml file, then switches to the bin directory, sources an edited/adapted minimal_env.sh file, and then runs bin/config_build.sh (the sdwan_config_builder code is included in the container image). After that, Ansible playbooks can be run normally.

Thanks for looking at this, good user facing documentation is very important, looking forward to a PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants