Ejemplo n.º 1
0
 def __init__(self):
     self.home = ".aliyuncli"
     self.update = "update"
     self.tag = "/"
     if platform.system() == "Windows":
         self.tag = "\\"
     self.aliyuncliUpdatePath = self._findHomePath()+self.tag+self.home+self.tag
     self.globalConfigure = aliyunCliConfiugre.configure()
Ejemplo n.º 2
0
 def __init__(self):
     self._version = version
     self.home = ".aliyuncli"
     self.configure = "configure"
     self.credentials = "credentials"
     self.aliyunConfigurePath = os.path.join(self.findConfigureFilePath(),self.home)
     self.globalConfigure = aliyunCliConfiugre.configure()
     self.parser = aliyunCliParser.aliyunCliParser()
Ejemplo n.º 3
0
 def __init__(self):
     self.home = ".aliyuncli"
     self.update = "update"
     self.tag = "/"
     if platform.system() == "Windows":
         self.tag = "\\"
     self.aliyuncliUpdatePath = self._findHomePath(
     ) + self.tag + self.home + self.tag
     self.globalConfigure = aliyunCliConfiugre.configure()
Ejemplo n.º 4
0
 def checkForServer(self,response,cmd,operation):
     configure = aliyunCliConfiugre.configure()
     requestId = self.getRequestId(response)
     if requestId is None:
         requestId = ""
     ak =  self.getUserKey()
     if ak is None:
         ak = ""
     ua =  self.getUserAgent()
     if ua is None:
         ua = ""
     url = configure.server_url + "?requesId=" + requestId + "&ak=" + ak +"&ua="+ua+"&cmd="+cmd+"&operation="+operation
     try:
         f = urllib2.urlopen(url,data=None,timeout=5)
         s = f.read()
         return s
     except Exception :
         pass
Ejemplo n.º 5
0
 def __init__(self):
     self.configure = aliyunCliConfiugre.configure()
     self.latest_update_time = self._getLatestTimeFromServer()
     self._updateFileHandler = updateFileHandler()
Ejemplo n.º 6
0
 def __init__(self):
     self.configure = aliyunCliConfiugre.configure()
     self.latest_update_time = self._getLatestTimeFromServer()
     self._updateFileHandler = updateFileHandler()