Skip to content

Commit

Permalink
#126 - Need to add back the SDX commands, which were removed to run t…
Browse files Browse the repository at this point in the history
…ests easier.
  • Loading branch information
Sean Donovan committed Nov 14, 2019
1 parent 0f3651b commit 91adbb4
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions docker/sci_gw_demo/science_gateway.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,30 +192,30 @@ def transfer_file(srcip, srcport, dstip, dstport, filename):
#print("srcdict - %s" % srcdict)
#print("dstdict - %s" % dstdict)

####create_tunnel(srcdict['switch'], dstdict['switch'],
# srcdict['switchport'], dstdict['switchport'],
# srcdict['vlan'], dstdict['vlan'],
# timedelta(0,1))
create_tunnel(srcdict['switch'], dstdict['switch'],
srcdict['switchport'], dstdict['switchport'],
srcdict['vlan'], dstdict['vlan'],
timedelta(0,1))

# Get and display files available on src
rawfiles = get_dir(srcdict['ip'], srcdict['port'])
fileslist = parse_files(rawfiles)
print_files(fileslist)
####delete_tunnel()
delete_tunnel()

# Let user choose file to transfer
filenumber = input("Choose a file: ")
filename = fileslist[int(filenumber)]

# Reestablish path between src and dest
####create_tunnel(srcdict['switch'], dstdict['switch'],
# srcdict['switchport'], dstdict['switchport'],
# srcdict['vlan'], dstdict['vlan'],
# timedelta(1,0)) # 1 day, excessive, but we'll delete it, don't worry
create_tunnel(srcdict['switch'], dstdict['switch'],
srcdict['switchport'], dstdict['switchport'],
srcdict['vlan'], dstdict['vlan'],
timedelta(1,0)) # 1 day, excessive, but we'll delete it, don't worry

# Make transfer call
transfer_file(srcdict['ip'], srcdict['port'],
dstdict['ip'], dstdict['port'], filename)

# Clean up
####delete_tunnel()
delete_tunnel()

0 comments on commit 91adbb4

Please sign in to comment.