This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def create_network(): | |
zos = j.sal.zosv2 | |
r = zos.reservation_create() | |
expiration = int(j.data.time.HRDateToEpoch('2021/06/30')) | |
overlay_network_ip_range = overlay_network_pre+"0.0/16" | |
iprange = "automatic" | |
ipv4_gateway='CBDY1Fu4CuxGpdU3zLL9QT5DGaRkxjpuJmzV6V5CBWg4' | |
gwnode = j.clients.explorer.explorer.nodes.get(ipv4_gateway) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_my_reservations(tid): | |
reservations = j.sal.zosv2.reservation_list(tid=130,next_action="DEPLOY") | |
#do some checks | |
return reservations | |
def get_free_ip(reservations,node,networkname): | |
# find netork reservation | |
# find all IPs | |
ips=[] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3BOTDEVEL:3bot:try: ./auto_depl.py | |
Node: 0 12775 BSusuRh6qFzheQFwNPe1S5FA5pdSZVJwVLhpNS6GN4XD ( 64 ) : 172.24.10.0/24 | |
Node: 1 12775 FCxp4JG2kr76dCnc2FzniApdwBak52uaSfbuigknS5Jx ( 64 ) : 172.24.11.0/24 | |
Node: 2 12775 FhfqdPSbEncHPWF74eDyDKjXTUfQjxwon9Hih9pG3Kjs ( 64 ) : 172.24.12.0/24 | |
Node: 3 12775 7fHSAHEvUGtUcYSqLtpGq8ANssPikTyyHC52FddDYF4Y ( 64 ) : 172.24.13.0/24 | |
Node: 4 12775 FjwyHVvfATkVb4Puh4x6jCMS79TVVgSYagAuZTxWrsbj ( 64 ) : 172.24.14.0/24 | |
Node: 5 12775 9211BFV7MFwktD2b8jHE9Ub3fHRtaYQyBBfwT9kEKA7q ( 64 ) : 172.24.15.0/24 | |
Node: 6 12775 HugtVL51BFNLbZbbxnWu2GEe8hV97YVPac19zy5wwNpT ( 32 ) : 172.24.16.0/24 | |
Node: 7 12775 9KAbX21NGbZYupBJ6EeeWx3ZTKDx7ADevr8qtmEa5WkC ( 32 ) : 172.24.17.0/24 | |
Node: 8 12775 9kcLeTuseybGHGWw2YXvdu4kk2jZzyZCaCHV9t6Axqqx ( 32 ) : 172.24.18.0/24 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
overlay_network_name="Net-AP4" | |
overlay_network_pre="172.24." | |
create_network() | |
def create_network(): | |
''' | |
c n | |
''' |