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

make cani netbox package and vendor #191

Merged
merged 5 commits into from
Mar 20, 2024
Merged

make cani netbox package and vendor #191

merged 5 commits into from
Mar 20, 2024

Conversation

jacobsalmela
Copy link
Collaborator

Summary and Scope

  • adds a netbox package, which has two schema files*
  • adds a function to create a new netbox client (compatible with device-type-library)
  • adds make targets for generating the types*

*netbox's device-type-library has defines a schema, but it does not necessarily match the netbox API (see netbox-community/go-netbox#168 (comment)). Because of this, I am adding this netbox package so we can track the differences and make adjustments in CANI. Also, go-jsonschema can generate nice .go files, but they needed a little massaging to plug in nice with CANI's types and not have unfriendly names. If there is something better to save me from writing all that code, I'd like to know, but this was the best I found at present.

Risks and Mitigations

Low. Not being used in main currently but making this PR more digest-able, as well as those that follow.

Signed-off-by: Jacob Salmela <jacob.salmela@hpe.com>
… schema (needs human munging at present)

Signed-off-by: Jacob Salmela <jacob.salmela@hpe.com>
Signed-off-by: Jacob Salmela <jacob.salmela@hpe.com>
Signed-off-by: Jacob Salmela <jacob.salmela@hpe.com>
@jacobsalmela jacobsalmela self-assigned this Mar 19, 2024
@jacobsalmela jacobsalmela marked this pull request as ready for review March 19, 2024 20:18
Signed-off-by: Jacob Salmela <jacob.salmela@hpe.com>
@jacobsalmela jacobsalmela merged commit 3452be4 into main Mar 20, 2024
5 checks passed
@jacobsalmela jacobsalmela deleted the known-aquaman branch March 20, 2024 11:44
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

Successfully merging this pull request may close these issues.

2 participants