From 1065ba807cc6aa5e48e5ed0bd48739118440eb70 Mon Sep 17 00:00:00 2001 From: Devin Carlen Date: Thu, 29 Jul 2010 17:18:39 -0700 Subject: [PATCH] Added project param to admin client zip download --- nova/adminclient.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/nova/adminclient.py b/nova/adminclient.py index fceeac27..25d5e71c 100644 --- a/nova/adminclient.py +++ b/nova/adminclient.py @@ -292,9 +292,13 @@ class NovaAdminClient(object): 'Operation': operation} return self.apiconn.get_status('ModifyProjectMember', params) - def get_zip(self, username): - """ returns the content of a zip file containing novarc and access credentials. """ - return self.apiconn.get_object('GenerateX509ForUser', {'Name': username}, UserInfo).file + def get_zip(self, user, project): + """ + Returns the content of a zip file containing novarc and access credentials. + """ + params = {'Name': user, 'Project': project} + zip = self.apiconn.get_object('GenerateX509ForUser', params, UserInfo) + return zip.file def get_hosts(self): return self.apiconn.get_list('DescribeHosts', {}, [('item', HostInfo)])