Esempio n. 1
0
 def __init__(self,
              host='10.1.115.41:8080',
              username='******',
              password='******',
              domain=None):
     self.host = host
     self.username = username
     self.password = password
     self.domain = domain
     self.cs_key_api = CloudStackSessionAPI(host=self.host,
                                            username=self.username,
                                            password=self.password,
                                            domain=self.domain)
Esempio n. 2
0
class CloudAPI(object):
	
	def __init__(self, host='10.1.115.41:8080', username='******', password='******', domain=None):
		self.host = host
		self.username = username
		self.password = password
		self.domain = domain
		self.cs_key_api = CloudStackSessionAPI(host = self.host, username = self.username, password = self.password, domain = self.domain)

	def execute(self, command, params=None):
		if(params == None):
			params = dict()
		params['command'] = command
		outputJSON = self.cs_key_api.request(params)
		return outputJSON
Esempio n. 3
0
class CloudAPI(object):
    def __init__(self,
                 host='10.1.115.41:8080',
                 username='******',
                 password='******',
                 domain=None):
        self.host = host
        self.username = username
        self.password = password
        self.domain = domain
        self.cs_key_api = CloudStackSessionAPI(host=self.host,
                                               username=self.username,
                                               password=self.password,
                                               domain=self.domain)

    def execute(self, command, params=None):
        if (params == None):
            params = dict()
        params['command'] = command
        outputJSON = self.cs_key_api.request(params)
        return outputJSON
Esempio n. 4
0
	def __init__(self, host='10.1.115.41:8080', username='******', password='******', domain=None):
		self.host = host
		self.username = username
		self.password = password
		self.domain = domain
		self.cs_key_api = CloudStackSessionAPI(host = self.host, username = self.username, password = self.password, domain = self.domain)