MCPcopy Create free account
hub / github.com/SpaceNetLab/StarryNet / sn_stop_emulation

Function sn_stop_emulation

starrynet/sn_orchestrater.py:470–486  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

468
469
470def sn_stop_emulation():
471 os.system("docker service rm constellation-test")
472 with os.popen("docker rm -f $(docker ps -a -q)") as f:
473 f.readlines()
474 with os.popen("docker network ls") as f:
475 all_br_info = f.readlines()
476 del_threads = []
477 for line in all_br_info:
478 if "La" in line or "Le" or "GS" in line:
479 network_name = line.split()[1]
480 del_thread = threading.Thread(target=sn_del_network,
481 args=(network_name, ))
482 del_threads.append(del_thread)
483 for del_thread in del_threads:
484 del_thread.start()
485 for del_thread in del_threads:
486 del_thread.join()
487
488
489def sn_recover(damage_list, container_id_list, sat_loss):

Callers 1

sn_orchestrater.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected