Refactor the way the runner is passed to the CLI