Source environment file on connection

Hi,

I’m working with a environment that requires a $ source /path/environment file every time Ansible connects so it can find Python etc, how would I go about doing that?

Thanks,
Richard

I would log in to a representative machine, do the source command and then examine what environment variables have been set, and then configure environment for any commands that need it.
See http://docs.ansible.com/ansible/latest/playbooks_environment.html

Jon