handle SIGTERM ourselves so we can cleanup pid