Use generated RSA key while accessing nodes via SSH

Generate RSA key pair (optionally it could be provided by
operator via environment variable) and use it for SSH
authentication instead of password.

Also it's possible to provide the key from a local file now.

Change-Id: I5fea4d55337f294cd7829392b91b2cca7b85ead5
Reviewed-on: https://review.gerrithub.io/367254
Reviewed-by: Victor Ryzhenkin <vryzhenkin@mirantis.com>
Reviewed-by: Dennis Dmitriev <dis.xcom@gmail.com>
Tested-by: Dennis Dmitriev <dis.xcom@gmail.com>
diff --git a/tcp_tests/helpers/env_config.py b/tcp_tests/helpers/env_config.py
index 48749c9..0331ac9 100644
--- a/tcp_tests/helpers/env_config.py
+++ b/tcp_tests/helpers/env_config.py
@@ -304,7 +304,7 @@
                 )
             )
 
-    def load_template(self, filename):
+    def load_template(self, filename, options=None):
         """Method for reading file with devops config
 
         :param filename: string
@@ -317,13 +317,13 @@
             )
 
             #self.config = templates.yaml_template_load(filename)
-            self.config = yaml_template_load(filename)
+            self.config = yaml_template_load(filename, options)
         else:
             LOG.error("Template filename is not set, loading config " +
                       "from template aborted.")
 
 
-def yaml_template_load(config_file):
+def yaml_template_load(config_file, options=None):
     """Temporary moved from fuel_devops to use jinja2"""
     dirname = os.path.dirname(config_file)
 
@@ -336,7 +336,7 @@
             raise error.DevopsError(
                 "Cannot load the environment template {0} : include file {1} "
                 "doesn't exist.".format(dirname, file_name))
-        inputfile = utils.render_template(file_name)
+        inputfile = utils.render_template(file_name, options)
         return yaml.load(inputfile, TemplateLoader)
 
     def yaml_get_env_variable(loader, node):
@@ -377,5 +377,5 @@
     TemplateLoader.add_constructor(
         yaml.resolver.BaseResolver.DEFAULT_MAPPING_TAG, construct_mapping)
 
-    f = utils.render_template(config_file)
+    f = utils.render_template(config_file, options)
     return yaml.load(f, TemplateLoader)