Correct way to setup the environment when developing custom ansible modules that use 3rd party python libraries
问题 I have developed a custom ansible module that has a dependency on a 3rd party library PyYAML. However running the playbook yields ansible_module_my_module.py, line 5, in <module> import yaml ImportError: No module named yaml I see PyYAML in the ansible requirements.txt (https://github.com/ansible/ansible/blob/stable-2.8/requirements.txt) so I know its installed/used on the host machine. I'm wondering if there is a recommended way to install it on the remote machine? I can add a step in the