Update run as worker to pass SIGTERM correctly to subprocess

I've tested this manually and it does what we would expect.

The reason we weren't gracefully shutting down before is that bash
won't forward SIGTERMs to processes that are running in the foreground.
"termination"