Screened credentials printing in openstack env
Added "set +x" / "set -x" commands to the generated openstack
environment file to prevent password to be logged when the file is
sourced during job execution.
Change-Id: Id8622019a648619a5ea6c814fc06e430316af2f3
diff --git a/src/com/mirantis/mk/openstack.groovy b/src/com/mirantis/mk/openstack.groovy
index ec840d8..d12c004 100644
--- a/src/com/mirantis/mk/openstack.groovy
+++ b/src/com/mirantis/mk/openstack.groovy
@@ -59,11 +59,13 @@
def common = new com.mirantis.mk.common()
rcFile = "${env.WORKSPACE}/keystonerc"
creds = common.getPasswordCredentials(credentialsId)
- rc = """export OS_USERNAME=${creds.username}
+ rc = """set +x
+export OS_USERNAME=${creds.username}
export OS_PASSWORD=${creds.password.toString()}
export OS_TENANT_NAME=${project}
export OS_AUTH_URL=${url}
export OS_AUTH_STRATEGY=keystone
+set -x
"""
writeFile file: rcFile, text: rc
return rcFile