summaryrefslogtreecommitdiff
path: root/lib/ansible/playbook
diff options
context:
space:
mode:
authorMichael DeHaan <michael@ansibleworks.com>2013-10-19 14:01:20 -0400
committerMichael DeHaan <michael@ansibleworks.com>2013-10-19 14:01:20 -0400
commit4125b05bf3228c17d03a0490a2b5ec460e79f30d (patch)
treeb840d259fa0901fd28d04022510f3e511d5d3e73 /lib/ansible/playbook
parent64bbeb9d24ccdcb9a468b186ed5e70f5bc925bd4 (diff)
downloadansible-4125b05bf3228c17d03a0490a2b5ec460e79f30d.tar.gz
Allow a defaults file to solely define a role. Some typo fixes.
Diffstat (limited to 'lib/ansible/playbook')
-rw-r--r--lib/ansible/playbook/play.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/ansible/playbook/play.py b/lib/ansible/playbook/play.py
index 04d84002db..dc4421756c 100644
--- a/lib/ansible/playbook/play.py
+++ b/lib/ansible/playbook/play.py
@@ -268,7 +268,7 @@ class Play(object):
new_default_vars = utils.parse_yaml_from_file(filename)
if new_default_vars:
if type(new_default_vars) != dict:
- raise errors.AnsibleError("%s must be stored as dictonary/hash: %s" % (filename, type(new_default_vars)))
+ raise errors.AnsibleError("%s must be stored as dictionary/hash: %s" % (filename, type(new_default_vars)))
default_vars = utils.combine_vars(default_vars, new_default_vars)
@@ -326,8 +326,8 @@ class Play(object):
library = utils.path_dwim(self.basedir, os.path.join(role_path, 'library'))
missing = lambda f: not os.path.isfile(f)
- if missing(task) and missing(handler) and missing(vars_file) and missing(meta_file) and missing(library):
- raise errors.AnsibleError("found role at %s, but cannot find %s or %s or %s or %s or %s" % (role_path, task, handler, vars_file, meta_file, library))
+ if missing(task) and missing(handler) and missing(vars_file) and missing(defaults_file) and missing(meta_file) and missing(library):
+ raise errors.AnsibleError("found role at %s, but cannot find %s or %s or %s or %s or %s or %s" % (role_path, task, handler, vars_file, defaults_file, meta_file, library))
if isinstance(role, dict):
role_name = role['role']