If you want to avoid using certain modules, you can add them to a reject list to prevent Ansible from loading them. To reject plugins, create a yaml configuration file. The default location for this file is /etc/ansible/plugin_filters.yml
. You can select a different path for the reject list using the PLUGIN_FILTERS_CFG setting in the defaults
section of your ansible.cfg. Here is an example reject list:
--- filter_version: '1.0' module_rejectlist: # Deprecated - docker # We only allow pip, not easy_install - easy_install
The file contains two fields:
"1.0"
Note
The stat
module is required for Ansible to run. Do not add this module to your reject list.
© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/user_guide/plugin_filtering_config.html