fixes 168. openstack cloud-config error 13/1013/2
authortierno <alfonso.tiernosepulveda@telefonica.com>
Wed, 25 Jan 2017 13:27:20 +0000 (14:27 +0100)
committertierno <alfonso.tiernosepulveda@telefonica.com>
Wed, 25 Jan 2017 13:29:15 +0000 (14:29 +0100)
Change-Id: I8879218073c29088f08106bc280656a380275aef
Signed-off-by: tierno <alfonso.tiernosepulveda@telefonica.com>
vimconn_openstack.py

index eaeae92..61d4b43 100644 (file)
@@ -761,7 +761,7 @@ class vimconnector(vimconn.vimconnector):
                         userdata_dict["ssh-authorized-keys"] = cloud_config["key-pairs"]
                         userdata_dict["users"] = [{"default": None, "ssh-authorized-keys": cloud_config["key-pairs"] }]
                     if cloud_config.get("users"):
-                        if "users" not in cloud_config:
+                        if "users" not in userdata_dict:
                             userdata_dict["users"] = [ "default" ]
                         for user in cloud_config["users"]:
                             user_info = {