Stop the server on SIGINT

When running a foreground task, wait for SIGINT to be signaled before stopping the server