Releases: criteo/ipam-client
Releases · criteo/ipam-client
v0.6.6
What's Changed
- Add a GH Actions integration by @pierrecdn in #40
New Contributors
- @pierrecdn made their first contribution in #40
Full Changelog: v0.6.5...v0.6.6
v0.6.5
Add get_subnet method
get_subnet method (#38) * Add add_subnet in the AbstractIPAM class * Since it's implemented in the PHPIPAM class and already tested * It should probably be present in the abstract class Change-Id: Ia9dc1f9364cd6f3f955865238e5b8092ef48345a * Add get_subnet method * There was not method to retrieve a subnet from the ip_network information (network_address + prefixlen) * Only from a description or with the list of IPs. The later method returns nothing if the subnet exists with no IP allocated. We can't guess if the subnet is empty or absent Change-Id: I6c05d572135da326088a3c9634bdcd56cc505405 * Pin mysql-connector-python to keep Python 2.7 compat * mysql-connector-python 8.0.24 breaks the compatibility with Python 2.7 * This is unfortunate but we still need to keep it Change-Id: I01945503264299819cf569b5377e5a364483d4ea Co-authored-by: Arnaud Chong <[email protected]>
add_next_ip: add allow_duplicates parameter
When asking to allocate an IP address, if allow_duplicates is False,
try first to lookup for an IP address matching description in target
subnet, and return it instead of allocating a duplicate IP. This allows
a client to atomically add an IP even if it asks multiple allocations.
v0.6.2
v0.6.1: make ip state compatible with newer PHPIPAM versions (#35)
* `state` field in ipaddresses table is default to 2 (instead of 1) in newer versions
Add mac-address support
Use mac field (#34) * Use mac field * Add the possibility to specify a mac when adding an IP address, this field is optional * Expose mac address when returning the IP addresses * Be able to find an IP based on the mac address
Improve get_subnet_with_ips performance
Use an ad-hoc SQL query to speed up subnet retrieval.
ipam-client improvements
ipam-client improvements (#32) * ipam-client: add vlan id in get_subnet_* methods Standardize vlan id fetching in all methods * ipam-client: add get_subnet_with_ips method This allows to fetch a whole subnet with all allocated ip addresses. * use a buffered cursor for mysql This prevents "unread result" issues * handle /0 subnets DB will return an empty string, translate it to 0