changed cli to pull from db