add datacenter location awareness with pseudo-driver (cmd and file) #4

Merged
Solvik merged 10 commits from feature/datacenter into master 2019-08-04 20:09:29 +02:00
Showing only changes of commit 87939d3e35 - Show all commits

View file

@ -39,4 +39,6 @@ class Datacenter():
raise ImportError("Driver {} doesn't exists".format(self.driver))
def get(self):
if not hasattr(self.driver, 'get'):
raise Exception("Your driver {} doesn't have a get() function, please fix it".format(self.driver))
return getattr(self.driver, 'get')(self.driver_value, DATACENTER_LOCATION_REGEX)