Shuts down a server gracefully upon the first specified signal received