Does apt_key use proxy environment vars?

I’m using a role in my playbook that uses the apt_key module:

`

The target host sits behind a proxy, and I have the usual proxy environment variables already set. This is enough to get various apt, apt_repository and other external-resource-calling tasks to work without a problem. However apt_key fails:

msg: Failed to download key at http://www.rabbitmq.com/rabbitmq-signing-key-public.asc: Request failed:

If I explicitly set the environment proxy variables on the task then the problem is resolved (as below). Why do I explicitly have to set the environment for apt_key and not other modules? Is this intended?

`

I’m using Ubuntu 14.04 with ansible 1.8.4

I looked at the code and it is the following:

os.environ.get('https_proxy')

never mind, checked all the codepaths and the module itself does not
support proxies

Thanks for checking that out for me.

My workaround was to update to 1.9 so I could use the environment keyword at the play level.