(self, container_id)
return link_list
From a container_id obtain its name(s)
From a container_id obtain its name(s)
From a container_id obtain its name ( s )
def get_container_name(self, container_id):
        """From a container_id obtain its name(s)"""
        if not os.path.isdir(self.containersdir):
            return []
        link_list = []
        for fname in os.listdir(self.containersdir):
            container = self.containersdir + "/" + fname
            if os.path.islink(container):
                real_container = os.readlink(container)
                if os.path.basename(real_container) == container_id:
                    link_list.append(fname)
        return link_list
def get_container_name ( self , container_id ) : if not os . path . isdir ( self . containersdir ) : return [ ] link_list = [ ] for fname in os . listdir ( self . containersdir ) : container = self . containersdir + "/" + fname if os . path . islink ( container ) : real_container = os . readlink ( container ) if os . path . basename ( real_container ) == container_id : link_list . append ( fname ) return link_list