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

Implement DS Get /ipam/prefix/available-prefixes #489

Merged
merged 2 commits into from
Oct 24, 2023

Conversation

theochita
Copy link
Contributor

This DS Feature makes users able to get available prefix's in a parent prefix.

@fbreckle
Copy link
Collaborator

Why is this required if https://github.com/e-breuninger/terraform-provider-netbox/blob/master/netbox/resource_netbox_available_prefix.go exists?
I.e. if you want to get the next available prefix, then lifecycle it with terraform, why would you not just use the netbox_available_prefix resource?

@theochita
Copy link
Contributor Author

Why is this required if https://github.com/e-breuninger/terraform-provider-netbox/blob/master/netbox/resource_netbox_available_prefix.go exists? I.e. if you want to get the next available prefix, then lifecycle it with terraform, why would you not just use the netbox_available_prefix resource?

Its for anyone who wants to know the available prefixes before hand for whatever reason.

In my own use case i need to know the available prefixes for multiple parent prefixes, then find one that fits my cidr and select only one that i want to create.

To my knowledge there's no way to do it in a not hacky way without this DS.

@fbreckle fbreckle merged commit b1742b1 into e-breuninger:master Oct 24, 2023
10 checks passed
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