AGENTS-102 - Gracefully handle SIGTERM signals

We need to handle `SIGTERM` signals and allow work to complete.

I don't think we need more tests than the signal test - we don't change much about the worker. Feel free to disagree, though :)