Added callback so api server can start on test port