pyaoscx.dhcp module¶
-
pyaoscx.dhcp.
add_dhcp_relays
(port_name, vrf_name, ipv4_helper_addresses, **kwargs)¶ Perform a POST call to add IPv4 DHCP helper(s) for an L3 interface. If there are already IPv4 helpers, the new helpers are added in addition to the already existing helpers.
Parameters: - port_name – Alphanumeric name of the Port
- vrf_name – Alphanumeric name of the VRF
- ipv4_helper_addresses – List of IPv4 addresses to add as DHCP helpers
- kwargs – keyword s: requests.session object with loaded cookie jar keyword url: URL in main() function
Returns: True if successful, False otherwise
-
pyaoscx.dhcp.
delete_dhcp_relays
(port_name, vrf_name='default', **kwargs)¶ Perform a DELETE call to delete all the IPv4 DHCP helper(s) for an L3 interface.
Parameters: - port_name – Alphanumeric name of the Port
- vrf_name – Alphanumeric name of the VRF
- kwargs – keyword s: requests.session object with loaded cookie jar keyword url: URL in main() function
Returns: True if successful, False otherwise
-
pyaoscx.dhcp.
get_all_dhcp_relays
(**kwargs)¶ Perform a GET call to get a list (or dictionary) of all entries in DHCP Relays table
Parameters: kwargs – keyword s: requests.session object with loaded cookie jar keyword url: URL in main() function Returns: List/dict of all DHCP helpers in the table
-
pyaoscx.dhcp.
get_dhcp_relay
(vrf_name, port_name, **kwargs)¶ Perform a GET call to get DHCP data for an interface
Parameters: - vrf_name – Alphanumeric name of VRF
- port_name – L3 interface’s Port table entry name
- kwargs – keyword s: requests.session object with loaded cookie jar keyword url: URL in main() function
Returns: Dictionary containing DHCP Relay data for interface