Matt Goodall
8babac4856
Allow "=" in k-v values.
13 years ago
Michael DeHaan
d4cc8dc242
Fix hosts being in multiple groups, and duplicate host references in the same inventory file.
13 years ago
Jeroen Hoekx
3768095645
If /usr/share/dict/words does not exist, use cracklib-small to test large output.
13 years ago
Michael DeHaan
84995367a5
Do not run unit tests against the EVENTS code because it is subject to change and that does not mean anything is broken.
...
If we want to test playbooks, it's best to test the result of a playbook to make sure it does the correct thing. Also
remove playbook2/3 yml which were not used.
13 years ago
Michael DeHaan
81b9240979
Merge pull request #363 from jhoekx/template-only-if
...
Fix correct variable expansion in includes only_if.
13 years ago
Jeroen Hoekx
b1da61ae92
Fix correct variable expansion in includes only_if.
...
There's not need to run the complete include through the templating engine.
Several variables were not included before the conditional was evaluated.
13 years ago
Jeroen Hoekx
b8573ab7d1
Support list indexing in varReplace.
13 years ago
Jeroen Hoekx
c362a2e581
Fixup unicode varReplace templating.
...
The original patches should have conflicted?
53bde0bf51
vs efde61e537
13 years ago
Michael DeHaan
abb391f3fd
Merge pull request #362 from jhoekx/uppercase-vars
...
Allow camelCase variables in varReplace.
13 years ago
John Kleint
64673cc932
Add test for large output; fix indentation.
13 years ago
Jeroen Hoekx
0b5b44858e
Allow camelCase variables in varreplace.
13 years ago
Jeroen Hoekx
a7599954a3
Make no_engine the default templating action.
13 years ago
Jeroen Hoekx
53bde0bf51
Support nested variables in varReplace.
13 years ago
Jeroen Hoekx
1d28212f86
Inventory: undefined group -> ungrouped.
...
Also change test name collision.
13 years ago
Jeroen Hoekx
3b40158961
Inventory: support list of vars in host.
13 years ago
Michael DeHaan
a7b9bf958d
Add tests for new advanced inventory features (groups of groups, group variables) in the default INI format file.
13 years ago
Michael DeHaan
46c661b3e3
Further work on making the YAML inventory parser use the new inventory objects.
13 years ago
Michael DeHaan
3fb2d38514
Reinstate external inventory script support this time using the new more OO-ey inventory system.
...
Next up: YAML format.
13 years ago
Michael DeHaan
4011d15faa
Refactored inventory to make it object oriented, need to make YAML format and executable script
...
format compatible with this still, and add some tests for INI-style groups of groups
and variables.
13 years ago
Jeroen Hoekx
03541baba7
Define 'inventory_hostname' variable for hosts.
13 years ago
Jeroen Hoekx
029fe1273c
Modify /usr/bin/ansible and playbooks to use the new async API.
13 years ago
Jeroen Hoekx
b87710a1df
Introduce group_names in template variables.
...
This is a list of all the groups a host is in.
13 years ago
Michael DeHaan
b9982fc17b
Reinstate --extra-vars, which can do things in playbooks like:
...
ansible-playbook release-my-app.yml --extra-vars="version=123"
And make $version available in the playbook without re-editing the file
13 years ago
Jeroen Hoekx
cc579a8aa2
Fix tests for facter and the ansible_facts API.
13 years ago
Jeroen Hoekx
2dc9a563ef
Allow modules to return facts.
...
If the module result contains "ansible_facts", that will be added to the setup
cache.
13 years ago
Michael DeHaan
c0c691089d
Fix bug in src. Should not code this early :)
13 years ago
Jeroen Hoekx
903e4f6eae
Support dicts in inventory vars.
13 years ago
Michael DeHaan
30d06dbcea
Don't force down ansible facts back to setup, the setup module won't like parsing them on input and that
...
data is already there.
13 years ago
Michael DeHaan
da0209dbc4
The fetch module really should preserve the whole directory structure being fetched to allow subsequent calls,
...
particularly in playbook, to recreate the host tree structure. Making it thus.
13 years ago
Jeroen Hoekx
6f09b41eb5
Don't test modules that aren't present.
...
Also account for path difference in sleep in different distributions.
13 years ago
Michael DeHaan
3f26a1c7f6
verbose option is not being used, so remove it. debug variable still exists.
13 years ago
Michael DeHaan
9ce27be878
Remove extra_vars tests
13 years ago
Jeroen Hoekx
8c3206c99f
Return a copy of the host variables.
13 years ago
Jeroen Hoekx
961ccdb2f4
List hosts in no group in the ungrouped group.
13 years ago
Jeroen Hoekx
3a24aa9a70
Add YAML inventory format.
...
See test/yaml_hosts for an example.
Hosts can be part of multiple groups.
Groups can also have variables, inherited by the hosts.
There is no variable scope, last variable seen wins.
13 years ago
Jeroen Hoekx
54f4526160
Export SSH port number as host variable.
13 years ago
Jeroen Hoekx
f04041b37d
Ignore port numbers in simple inventory format
13 years ago
Jeroen Hoekx
746f1b92ae
Reimplement the class method on Runner.
13 years ago
Jeroen Hoekx
195e6d617b
Add tests for Inventory class.
13 years ago
Michael DeHaan
08c593bee1
Warn if no hosts matched
13 years ago
Michael DeHaan
b9e3b053f9
Simplify playbook tests so things are not timing dependent in the poll section, which is leading to tests
...
not being consistent between runs, even though there wasn't an error. Now we'll just check the final change
counts, which should be just as solid and lead to less churn in the events file.
13 years ago
Michael DeHaan
e103bdda93
Rename test class to match what it is testing
13 years ago
Michael DeHaan
245aa9bf8e
Some tweaks to the fetch module. 'err' return was for stderr, so that should be empty string.
...
Some minor code shortening. Added a test to TestRunner.
13 years ago
Michael DeHaan
51e4faf7aa
Update test file -- we probably should not include the poll as the number of polls is changing between test
...
runs (that's ok, it's not intended to be realtime accurate)
13 years ago
Michael DeHaan
1d75a29ec9
Allow variables coming in from the playbook and the API to be expressed as dictionaries throughout their full life cycle
...
such that nested data can be made available in templates and playbooks.
13 years ago
Michael DeHaan
eed4a2b717
Update tests to use 127.0.0.2 to bypass the smart "use local connection" code, and also to reflect
...
that commands now trigger change events.
13 years ago
Michael DeHaan
2a2b5ed73c
Polling timing change results in need to change events file for tests.
13 years ago
Michael DeHaan
4792021f47
Fix syntax error in user patch
13 years ago
Michael DeHaan
2511992659
Surface module debug (-D) to /usr/bin/ansible also
13 years ago
Michael DeHaan
96a22b582b
Disable ohai test as it's hanging for whatever reason, but doesn't do this in real life.
...
Run tests in verbose mode.
13 years ago