Scan server: Closing server via console will gracefully end running scan

.. and execute post-scan commands