community.general/lib/ansible
Serge van Ginderachter 173586b871 Ensure plugin_loader.all() only loads one instance
by ensuring all basedirs, plugin paths and extra
paths are handled as absolute paths and are checked
to not add any doubles.

This fixes the corner case where e.g. the user has
an additional plugin path configured to a dir
relative to his playbooks or inventory location,
which also matches the  _plugin subdir relative to
one of the basedirs in the play.

For most plugins this doesn't show as an obvious issue
except for callback_plugins, which might fire more
than once. Other plugins (inventory and template
plugins) might unnecessarily be ran twice.

e.g. ansible.cfg has
callback_plugins   = ./plays/callback_plugins
and plays/ contains a playbook file:
.
├── ansible.cfg
├── inventory
└── plays
    ├── callback_plugins
    │   └── timestamp.py
    └── site.yml

modified:   lib/ansible/utils/plugins.py
2013-08-12 22:17:53 +02:00
..
callback_plugins Renamed on_no_hosts_matched/on_no_hosts_remaining to correct names in noop callback, added methods to callback plugin examples. 2013-06-09 12:19:07 -04:00
inventory fix inventory.basedir is not absolute path when hostfile is startswith "./" 2013-08-11 10:50:47 +08:00
playbook implemented 'inventory_file' variable. Closes GH-3789. 2013-08-10 13:04:56 +02:00
runner Merge branch 'rsynctake2' into devel 2013-08-11 16:22:36 -04:00
utils Ensure plugin_loader.all() only loads one instance 2013-08-12 22:17:53 +02:00
__init__.py Version bump and assorted things to start new development version. 2013-06-10 15:34:52 -04:00
callbacks.py These fields are booleans. 2013-08-10 18:16:01 -04:00
color.py These fields are booleans. 2013-08-10 18:16:01 -04:00
constants.py These fields are booleans. 2013-08-10 18:16:01 -04:00
errors.py Introduce exception AnsibleFilterError and use it in Jinja filters. Ignore this exception when trying to find the name of a task for display (callback) purpose. 2013-07-07 19:18:32 +02:00
module_common.py Merge pull request #3706 from lorin/sudo_user_breakage 2013-08-01 17:15:26 -07:00