Shut down server gracefully using signal