Add env vars to worker to combat DirtyExit

I've read this was a solution in a few different stack overflows...