(self)
return(container_dir, container_json)
Get container directory and JSON metadata by id or name
Get container directory and JSON metadata by id or name
Get container directory and JSON metadata by id or name
def get_container_attr(self):
        """Get container directory and JSON metadata by id or name"""
        if Config.conf['location']:
            container_dir = ""
            container_json = []
        else:
            container_dir = self.localrepo.cd_container(self.container_id)
            if not container_dir:
                Msg().err("Error: container id or name not found")
                return(False, False)

            fjson = container_dir + "/container.json"
            container_json = self.localrepo.load_json(fjson)
            if not container_json:
                Msg().err("Error: invalid container json metadata")
                return(False, False)

        return(container_dir, container_json)
def get_container_attr ( self ) : if Config . conf [ 'location' ] : container_dir = "" container_json = [ ] else : container_dir = self . localrepo . cd_container ( self . container_id ) if not container_dir : Msg ( ) . err ( "Error: container id or name not found" ) return ( False , False ) fjson = container_dir + "/container.json" container_json = self . localrepo . load_json ( fjson ) if not container_json : Msg ( ) . err ( "Error: invalid container json metadata" ) return ( False , False ) return ( container_dir , container_json )