Allow use of onos docker for existing tests
- Allow Cluster to pull/build onos docker
- Connect clidriver to cli runnning in docker
- Some changes for debugability in components
- To use, set the useDocker and diffCliHosts tags in the cluster
component to True, then define parameters in the params file
- Update all SR Stratum tests to use the tost docker image
- NOTE: Since the tost-onos image doesn't have openflow installe, we are
currently only using docker for the bmv2 and tofino switches
Change-Id: If900b0bdbf9a41b8885c692ccba18a3b1bc580cc
diff --git a/TestON/tests/dependencies/utils.py b/TestON/tests/dependencies/utils.py
index 6537afc..3cf849a 100644
--- a/TestON/tests/dependencies/utils.py
+++ b/TestON/tests/dependencies/utils.py
@@ -74,10 +74,20 @@
scpResult = main.TRUE
copyResult = main.TRUE
for ctrl in main.Cluster.runningNodes:
- scpResult = scpResult and main.ONOSbench.scp( ctrl,
- "/opt/onos/log/karaf.log",
- "/tmp/karaf.log",
- direction="from" )
+ if ctrl.inDocker:
+ scpResult = scpResult and ctrl.server.dockerCp( ctrl.name,
+ "/opt/onos/log/karaf.log",
+ "/tmp/karaf.log",
+ direction="from" )
+ scpResult = scpResult and main.ONOSbench.scp( ctrl.server,
+ "/tmp/karaf.log",
+ "/tmp/karaf.log",
+ direction="from" )
+ else:
+ scpResult = scpResult and main.ONOSbench.scp( ctrl,
+ "/opt/onos/log/karaf.log",
+ "/tmp/karaf.log",
+ direction="from" )
copyResult = copyResult and main.ONOSbench.cpLogsToDir( "/tmp/karaf.log", main.logdir,
copyFileName=( copyFileName + "_karaf.log." +
ctrl.name + "_" ) if before else