add -l flag to start a listening server