Updated Branches:
  refs/heads/trunk 63a5b8de9 -> 2fdad6bf4

Updated argument names in the ex_import_keypair and 
ex_import_keypair_from_string methods to be consistent with other drivers.

Signed-off-by: Tomaz Muraus <[email protected]>


Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/ef9e26a3
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/ef9e26a3
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/ef9e26a3

Branch: refs/heads/trunk
Commit: ef9e26a309595675fa7341519eb060a170c80e16
Parents: aadbd4c
Author: schaubl <[email protected]>
Authored: Wed Sep 25 20:43:03 2013 +0200
Committer: Tomaz Muraus <[email protected]>
Committed: Wed Sep 25 21:10:21 2013 +0200

----------------------------------------------------------------------
 libcloud/compute/drivers/openstack.py | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/ef9e26a3/libcloud/compute/drivers/openstack.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/openstack.py 
b/libcloud/compute/drivers/openstack.py
index 875094d..fa86fc2 100644
--- a/libcloud/compute/drivers/openstack.py
+++ b/libcloud/compute/drivers/openstack.py
@@ -1708,36 +1708,36 @@ class OpenStack_1_1_NodeDriver(OpenStackNodeDriver):
             data={'keypair': {'name': name}}
         ).object['keypair'])
 
-    def ex_import_keypair(self, name, public_key_file):
+    def ex_import_keypair(self, name, keyfile):
         """
         Import a KeyPair from a file
 
         @param name: Name of the new KeyPair
         @type  name: C{str}
 
-        @param public_key_file: Path to the public key file (in OpenSSH format)
-        @type  public_key_file: C{str}
+        @param keyfile: Path to the public key file (in OpenSSH format)
+        @type  keyfile: C{str}
 
         @rtype: L{OpenStackKeyPair}
         """
-        public_key = open(os.path.expanduser(public_key_file), 'r').read()
+        public_key = open(os.path.expanduser(keyfile), 'r').read()
         return self.ex_import_keypair_from_string(name, public_key)
 
-    def ex_import_keypair_from_string(self, name, public_key):
+    def ex_import_keypair_from_string(self, name, key_material):
         """
         Import a KeyPair from a string
 
         @param name: Name of the new KeyPair
         @type  name: C{str}
 
-        @param public_key: Public key (in OpenSSH format)
-        @type  public_key: C{str}
+        @param key_material: Public key (in OpenSSH format)
+        @type  key_material: C{str}
 
         @rtype: L{OpenStackKeyPair}
         """
         return self._to_keypair(self.connection.request(
             '/os-keypairs', method='POST',
-            data={'keypair': {'name': name, 'public_key': public_key}}
+            data={'keypair': {'name': name, 'public_key': key_material}}
         ).object['keypair'])
 
     def ex_delete_keypair(self, keypair):

Reply via email to