Pass grafana password in rally task args
Change-Id: I76997afd61733174231265686f12ad78430d8bf1
Related-bug: https://mirantis.jira.com/browse/PROD-24295
diff --git a/src/com/mirantis/mcp/Validate.groovy b/src/com/mirantis/mcp/Validate.groovy
index 102ec2b..a1641b9 100644
--- a/src/com/mirantis/mcp/Validate.groovy
+++ b/src/com/mirantis/mcp/Validate.groovy
@@ -443,8 +443,12 @@
'rally deployment create --fromenv --name=existing; ' +
'rally deployment config; '
if (platform['stacklight_enabled'] == true) {
+ def _pillar_grafana = salt.getPillar(master, 'I@grafana:client', 'grafana:client:server')
+ def grafana = _pillar_grafana['return'][0].values()[0]
cmd_rally_stacklight = bundle_up_scenarios(sl_scenarios, skip_list, "scenarios_${platform.type}_stacklight.yaml")
- cmd_rally_stacklight += "rally $rally_extra_args task start scenarios_${platform.type}_stacklight.yaml " +
+ cmd_rally_stacklight += "sed -i 's/grafana_password: .*/grafana_password: ${grafana.password}/' " +
+ "test_config/job-params-stacklight.yaml; " +
+ "rally $rally_extra_args task start scenarios_${platform.type}_stacklight.yaml " +
"--task-args-file test_config/job-params-stacklight.yaml; "
}
} else if (platform['type'] == 'k8s') {