def init_server(self): """ Inicializa el servidor ejecutado por este cliente. """ self._server = TagFSServer(self._address, self._data_dir, self._capacity, self._ntp_server) self._server_thread = threading.Thread(target=self._server.start) self._server_thread.start()
def main(argv): """ Función principal del script. @type argv: C{list} @param argv: Lista de argumentos del programa. @rtype: C{int} @return: Retorna 0 si no ocurrió ningún error durante la ejecución del programa y 1 en el caso contrario. """ options, args = _parse_args(argv) server = TagFSServer(options.address, options.data_dir, options.capacity, options.ntp_server) server.start() return EXIT_SUCCESS