Merge "[CVP] Fix tools_repo offline usage" into release/proposed/2019.2.0
diff --git a/src/com/mirantis/mcp/Validate.groovy b/src/com/mirantis/mcp/Validate.groovy
index 00554cc..f71bca6 100644
--- a/src/com/mirantis/mcp/Validate.groovy
+++ b/src/com/mirantis/mcp/Validate.groovy
@@ -640,6 +640,7 @@
tempest_endpoint_type="internalURL", tempest_version="",
conf_script_path="", ext_variables = [], container_name="cvp") {
def salt = new com.mirantis.mk.Salt()
+ def common = new com.mirantis.mk.Common()
if (testing_tools_repo != "" ) {
workdir = ''
if (testing_tools_repo.contains('http://') || testing_tools_repo.contains('https://')) {
@@ -656,7 +657,7 @@
salt.cmdRun(master, target, "docker exec -e " + ext_variables.join(' -e ') + " ${workdir} ${container_name} bash -c ${configure_script}")
}
else {
- common.infoMsg("TOOLS_REPO is empty, no confguration is needed for container")
+ common.infoMsg("TOOLS_REPO is empty, no configuration is needed for this container")
}
}
@@ -809,10 +810,12 @@
* Find vip on nodes
*
* @param target Host with cvp container
+ * @param container_name Name of container
+ * @param script_path Path to cleanup script (inside container)
*/
-def openstack_cleanup(master, target, script_path="/home/rally/cvp-configuration/cleanup.sh") {
+def openstack_cleanup(master, target, container_name="cvp", script_path="/home/rally/cleanup.sh") {
def salt = new com.mirantis.mk.Salt()
- salt.runSaltProcessStep(master, "${target}", 'cmd.run', ["docker exec cvp bash -c ${script_path}"])
+ salt.runSaltProcessStep(master, "${target}", 'cmd.run', ["docker exec ${container_name} bash -c ${script_path}"])
}
diff --git a/src/com/mirantis/mk/Orchestrate.groovy b/src/com/mirantis/mk/Orchestrate.groovy
index d0d0b1e..ebd403e 100644
--- a/src/com/mirantis/mk/Orchestrate.groovy
+++ b/src/com/mirantis/mk/Orchestrate.groovy
@@ -785,8 +785,10 @@
}
// Jenkins
- def jenkins_master_url_pillar = salt.getPillar(master, jenkins_compound, '_param:jenkins_master_url')
- jenkins_master_url = salt.getReturnValues(jenkins_master_url_pillar)
+ def jenkins_master_host = salt.getReturnValues(salt.getPillar(master, jenkins_compound, '_param:jenkins_master_host'))
+ def jenkins_master_port = salt.getReturnValues(salt.getPillar(master, jenkins_compound, '_param:jenkins_master_port'))
+ def jenkins_master_protocol = salt.getReturnValues(salt.getPillar(master, jenkins_compound, '_param:jenkins_master_protocol'))
+ jenkins_master_url = "${jenkins_master_protocol}://${jenkins_master_host}:${jenkins_master_port}"
timeout(wait_timeout) {
common.infoMsg('Waiting for Jenkins to come up..')