def delete(self, req): cmd = jsonobject.loads(req[http.REQUEST_BODY]) path = self._normalize_install_path(cmd.installPath) lichbd.lichbd_rm(path) rsp = AgentResponse() self._set_capacity_to_response(rsp) return jsonobject.dumps(rsp)
def delete(self, req): cmd = jsonobject.loads(req[http.REQUEST_BODY]) path = self._normalize_install_path(cmd.installPath) lichbd.lichbd_rm(path) rsp = AgentResponse() self._set_capacity_to_response(rsp) return jsonobject.dumps(rsp)
def delete(self, req): cmd = jsonobject.loads(req[http.REQUEST_BODY]) pool, image_name = self._parse_install_path(cmd.installPath) lichbd_file = os.path.join(pool, image_name) lichbd.lichbd_rm(lichbd_file) lichbd.lichbd_rm(lichbd_file, "iscsi") rsp = AgentResponse() self._set_capacity_to_response(rsp) return jsonobject.dumps(rsp)
def delete(self, req): cmd = jsonobject.loads(req[http.REQUEST_BODY]) pool, image_name = self._parse_install_path(cmd.installPath) protocol = lichbd.get_protocol() lichbd_file = os.path.join(pool, image_name) lichbd.lichbd_rm(lichbd_file) if protocol == 'lichbd': lichbd.lichbd_rm(lichbd_file, "iscsi") rsp = AgentResponse() self._set_capacity_to_response(rsp) return jsonobject.dumps(rsp)
def _1(): if lichbd.lichbd_file_exist(tmp_lichbd_file): lichbd.lichbd_rm(tmp_lichbd_file) lichbd.lichbd_rm(lichbd_file)
def _1(): if lichbd.lichbd_file_exist(tmp_lichbd_file): lichbd.lichbd_rm(tmp_lichbd_file) lichbd.lichbd_rm(lichbd_file)