Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

a guest Apr 3rd, 2020 168 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. def update_perm_dcgw(router):
  2.   hydra = instantiate_hydra()
  3.   router_name = hydra.api_post("ci/search" , data={"hostname" : router}) ########################
  4.   router_id = router_name[0]["id"]
  5.   ci_lifs = hydra.api_get("ci/" + str(router_id) , params={"expand" : "logical_interfaces.ips"})
  6.   for lif in ci_lifs[0]["logical_interfaces"]:
  7.     if lif["ips"]:
  8.       for network in lif["ips"]:
  9.         test = hydra.api_post("relation/network/consumer", data={"team_id" : 1865, "network_id" : network["network_id"]})
  10.  
  11.  
  12.  
  13.  
  14. logging.getLogger().setLevel(logging.ERROR)
  15. update_perm_dcgw("serointrt12101")
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top