def update_client(self, client_iqn, image_list): client = GWClient(self.logger, client_iqn, image_list, '') client.define_client() # sets up tpg lun list # grab the client's metadata from the config (needed by setup_luns) client.metadata = self.config.config['clients'][client_iqn] client.setup_luns() if client.error: self._set_error(client.error_msg)
def update_client(self, client_iqn, image_list): client = GWClient(self.logger, client_iqn, image_list, '', '', '', '', self.target_iqn) client.manage('reconfigure') # grab the client's metadata from the config (needed by setup_luns) target_config = self.config.config['targets'][self.target_iqn] client.metadata = target_config['clients'][client_iqn] client.setup_luns(self.config.config['disks']) if client.error: self._set_error(client.error_msg)
def update_client(self, client_iqn, image_list): client = GWClient(self.logger, client_iqn, image_list, '') client.define_client() # set up clients ACL # grab the metadata from the current definition client.metadata = self.config.config['clients'][client_iqn] client.setup_luns() if client.error: self._set_error(client.error_msg) return else: self.logger.info("Updating config object for " "client '{}'".format(client_iqn)) client.metadata['group_name'] = self.group_name self.config.update_item("clients", client_iqn, client.metadata)