-
Notifications
You must be signed in to change notification settings - Fork 93
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
Are there any way to check the availability of a certain CIDR range via using API #166
Comments
Hi @trandangtri, this is an excellent use case! Just to be clear, we're talking about checking if a CIDR is in use withing a specific Space/Block, correct? Whould an API like this make sense: Or perhaps this might fit better under the Tools section: What are your thoughts here? |
Hi @DCMattyG Thanks for your response. Meant, we didn't support this function at this moment yet? |
Hey @trandangtri, there's not workaround within the product today, but perhaps you could do some calculations using something like the netaddr library in Python. Not sure what environment you're using here. I can get this feature added in fairly quickly. I'm finishing up some major updates this week, so I can likely have this done by the end of this month. Did you have a preference on how this API should be presented (from my comment above)? |
I'm on it @trandangtri! I'll begin working on this right away 👍 |
Good afternoon @trandangtri, I wanted to run this by you... Given an input CIDR of something like "10.1.0.0/16", would a response like the following make sense:
You can see here it would show you all overlapping vNET's, and call out the ones that are container within existing Spaces/Blocks if such an association exists. Is this what you are looking for? |
Such wonderful. Although my initialized thought is to check the availability of a certain CIDR range, but in case we are able to dive deeper into the existing ranges like your response example, I would love to have a distinct container info: [
{
"name": "Services-vNET",
"id": "/subscriptions/57ff49dd-d5b5-48cb-b920-c5f0593c7f5b/resourceGroups/RG-SERVICES/providers/Microsoft.Network/virtualNetworks/Services-vNET",
"resource_group": "rg-services",
"subscription_id": "57ff49dd-d5b5-48cb-b920-c5f0593c7f5b",
"tenant_id": "9a885645-7e98-4479-8ae3-4118e0c13594",
"prefixes": [
"10.1.0.0/16"
],
"containers": [
{
"space": "TestSpace",
"block": "TestBlock"
}
]
}
] Then, I don't need to work on string parsing anymore, if I need to retrieve further information. Just my 2 cents |
Hi @trandangtri, I've implemented this new API in the latest code changes from PR #181. Please restart your IPAM App Service to pull down the latest containers for testing. Here's the details from the API Docs page: Please give it a test and let me know if it meets all of your expectations. Thanks so much! |
Good morning @trandangtri, just wanted to check-in with you on this item. Please let me know once you've had a chance to test everything out and have verified that the new API (above) meets your requirements. Much appreciated! |
Hi @DCMattyG That’s fantastic! I will try to manage my time to work on this, and keep you posted Regards |
Hi @trandangtri, I know it's been a while but I wanted to see if you've had a chance to test out this functionality and are satisfied with the implementation. Let me know when you can, thanks so much! |
Good afternoon @trandangtri, I'm circling back one last time before closing out this issue. Have you been able to test everything out, and if so is everything looking good or perhaps is there anything we need to tweak about this solution? Appreciate the feedback! |
Hey there @trandangtri, as this item has been addressed for quite some time now, I'm going to close this issue for the time being. If for any reason you aren't satisfied with the provided fix, please feel free to either re-open this issue or file a new one, and I'll make sure we get everything working as you expected. Thanks for the contribution, and know we're always here if there's anything else you ever need. Thank you! |
Let say I wanna allocate a subnet from within a certain CIDR range, from my administration application, via using API request. I just wanna make sure this CIDR range is available and not overlapped with others.
At this moment, can I do that with API request, to IPAM engine?
The text was updated successfully, but these errors were encountered: