Revert hack removal from aa5a2a6 and add feature flip for it

I want to make it backwards compatible by default in case there are
workers not capable of handling it (it may be true for Travis PRO)
Add feature flip for enabling passing global_env in config