From 879ddddf6f587be91b109f785038a0bcd9318436 Mon Sep 17 00:00:00 2001 From: Jeroen Hoekx Date: Mon, 25 Jun 2012 20:57:09 +0200 Subject: [PATCH] Add ./library to module search path. It allows for custom modules in the best practices directory structure. Bundling custom modules along with playbooks in packages is useful. --- lib/ansible/playbook/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/playbook/__init__.py b/lib/ansible/playbook/__init__.py index 460e4f93535..4e9e5dbd3c3 100644 --- a/lib/ansible/playbook/__init__.py +++ b/lib/ansible/playbook/__init__.py @@ -114,6 +114,8 @@ class PlayBook(object): self.basedir = os.path.dirname(playbook) self.playbook = utils.parse_yaml_from_file(playbook) + self.module_path = self.module_path + os.pathsep + os.path.join(self.basedir, "library") + # ***************************************************** def run(self):