Skip to content

Commit

Permalink
Merged in no-cli (pull request #2)
Browse files Browse the repository at this point in the history
Adds no-cli param

Approved-by: Pier Luigi Ventre <pier.luigi.ventre@uniroma2.it>
Approved-by: Francesco Lombardo <franclombardo@gmail.com>
  • Loading branch information
Pier Luigi Ventre committed Oct 31, 2017
2 parents 7468138 + a123865 commit 2ad87b1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions mininet_deployer.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,10 @@ def topo(topology):

my_info = net.start()
store_overall_info(my_info)
if tf_version == 1:
if not no_cli:
CLI(net)
net.stop()


def store_overall_info(my_info):

stro = json.dumps(my_info)
Expand All @@ -270,6 +269,7 @@ def parse_cmd_line():
parser.add_argument('--nodeinfo', dest='nodeInfo', action='store', default= DEFAULT_OVERALL_INFO_FILE, help='file that stores the node info to be processed by node.js')
parser.add_argument('--version', dest='version', action='store', default=1, help='topology format version')
parser.add_argument('--stop-all', dest='clean_all',action='store_true', help='Clean all mininet environment')
parser.add_argument('--no-cli', dest='no_cli',action='store_true', help='Do not show Mininet CLI')

args = parser.parse_args()

Expand All @@ -284,8 +284,10 @@ def parse_cmd_line():

global overall_info_file
global tf_version
global no_cli
tf_version = args.version
overall_info_file = args.nodeInfo
no_cli = args.no_cli
return (topo_data)

if __name__ == '__main__':
Expand Down

0 comments on commit 2ad87b1

Please sign in to comment.