Explicitly handle SIGINT and SIGTERM